Content - Get Content Upload Url
Retrieves the pre-signed URL for uploading a content file. A subsequent HTTP PUT to the returned URL uploads the content. Also, please be aware that the Content service is specifically PlayFab's CDN offering, for which standard CDN rates apply.
POST https://titleId.playfabapi.com/Admin/GetContentUploadUrl
Request Header
Name | Required | Type | Description |
---|---|---|---|
X-SecretKey | True |
string |
This API requires a title secret key, available to title admins, from PlayFab Game Manager. |
Request Body
Name | Required | Type | Description |
---|---|---|---|
Key | True |
string |
Key of the content item to upload, usually formatted as a path, e.g. images/a.png |
ContentType |
string |
A standard MIME type describing the format of the contents. The same MIME type has to be set in the header when uploading the content. If not specified, the MIME type is 'binary/octet-stream' by default. |
Responses
Name | Type | Description |
---|---|---|
200 OK | ||
400 Bad Request |
This is the outer wrapper for all responses with errors |
Security
X-SecretKey
This API requires a title secret key, available to title admins, from PlayFab Game Manager.
Type:
apiKey
In:
header
Definitions
Name | Description |
---|---|
Api |
The basic wrapper around every failed API response |
Get |
|
Get |
ApiErrorWrapper
The basic wrapper around every failed API response
Name | Type | Description |
---|---|---|
code |
integer |
Numerical HTTP code |
error |
string |
Playfab error code |
errorCode |
integer |
Numerical PlayFab error code |
errorDetails |
object |
Detailed description of individual issues with the request object |
errorMessage |
string |
Description for the PlayFab errorCode |
status |
string |
String HTTP code |
GetContentUploadUrlRequest
Name | Type | Description |
---|---|---|
ContentType |
string |
A standard MIME type describing the format of the contents. The same MIME type has to be set in the header when uploading the content. If not specified, the MIME type is 'binary/octet-stream' by default. |
Key |
string |
Key of the content item to upload, usually formatted as a path, e.g. images/a.png |
GetContentUploadUrlResult
Name | Type | Description |
---|---|---|
URL |
string |
URL for uploading content via HTTP PUT method. The URL requires the 'x-ms-blob-type' header to have the value 'BlockBlob'. The URL will expire in approximately one hour. |
Error Codes
Name | Code |
---|---|
BillingInformationRequired | 1266 |
ContentQuotaExceeded | 1137 |
NotAuthorized | 1089 |