question

ashkan-saeedi-mazdeh avatar image
ashkan-saeedi-mazdeh asked

How can I give read access to title entity's files to clients or even better onauthenticated callers

Hi
I want to use title files instead of old title data because my files are about 1MB and bigger than title data limits.
How can I give read access to title entity's files to everyone including anonymous users or at least logged in clients.

The API access syntax was very confusing and did not have enough examples.

data
10 |1200

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

1 Answer

·
Sarah Zhang avatar image
Sarah Zhang answered

For clarification, we can only allow the title players to read the files of current title. The players must log in to the title before they call the API GetFiles. To let the title players can read the specific title entity files, you can navigate to [Game Manager]->[Title settings]->[API Features] to find the [Entity Global Title Policy] and modify it as something like this. Please replace the placeholders with your real title publisher Id, entity file name, and title Id. You can find the detailed title publisher Id and the title Id on the [API Features] page. You can also refer to this thread - How do I allow specific player account to upload title entity files? - Playfab Community for more information.

   {
        "Action": "Read",
        "Effect": "Allow",
        "Resource": "pfrn:data--title![YourTitlePublisherId]/Profile/Files/[TheFileName]",
        "Principal": {
            "ChildOf": {
                "EntityType": "title",
                "EntityId": "[YourTitleId]"
            }
        },
        "Comment": "Allow all title members to read all title files"
    }

10 |1200

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Write an Answer

Hint: Notify or tag a user in this post by typing @username.

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.