question

contact-18 avatar image
contact-18 asked

Playfab Economy v2 Create Draft Item -> NotAuthorized

Hey, I'm using Unreal and I want to automate my item creation. Whenever I use 'Create Draft Item,' I always get the following error message. What am I doing wrong?

Unreal Blueprint: https://blueprintue.com/render/ghgd6daf/

 LogPlayFab: Request: {
     "Item":
     {
         "StartDate": "2022-09-07T00:00:00.000Z",
         "ContentType": "Weapon",
         "Type": "catalogItem",
         "CreatorEntity":
         {
             "Id": "[id]",
             "Type": "title"
         },
         "Title":
         {
             "NEUTRAL": "Blah"
         }
     },
     "Publish": false
 }
 LogPlayFab: Response : {"code":401,"status":"Unauthorized","error":"NotAuthorized","errorCode":1089,"errorMessage":"Calling Entity does not have permissions to the Item Type."}
Player Inventory
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

·
Gosen Gao avatar image
Gosen Gao answered

To create catalog item using Catalog - Create Draft Item - REST API (PlayFab Economy) | Microsoft Learn, you need a title level entity token, which can be obtained by Authentication - Get Entity Token - REST API (PlayFab Authentication) | Microsoft Learn(Set the Developer Secret Key correctly, and leave the request of GetEntityToken empty).

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.