Register media upload
Changed onRegister your intent to upload media.
The response includes all of the information needed to upload the media to Pinterest.
To upload the media, make an HTTP POST request (using curl, for example) to upload_url using the Content-Type header value. Send the media file's contents as the request's file parameter and also include all of the parameters from upload_parameters.
Learn more about video Pin creation.
Request
- Base URLhttps://api.pinterest.com/v5
- AuthOAuth 2Authorization codehttps://www.pinterest.com/oauth/Token URLhttps://api.pinterest.com/v5/oauth/tokenScopespins:read, pins:write
- TypeScriptA function with typed inputs. Its response is checked against the schema.
Request body
Response
The request has succeeded.
Example response
{
"media_id": "12345",
"upload_parameters": {
"Content-Type": "multipart/form-data",
"key": "uploads/11/aa/22/3:video:203014033110991560:5212123920968240771",
"policy": "eyJleHBpcmF0aW9uIjoiMj..==",
"x-amz-algorithm": "AWS4-HMAC-SHA256",
"x-amz-credential": "ASIA6QZJ64OPIKV7FRVX/20220127/us-east-1/s3/aws4_request",
"x-amz-date": "20220127T185143Z",
"x-amz-security-token": "IQoJb3JpZ2luX2VjEJr...==",
"x-amz-signature": "fcd6309a6aaee213348666a72abed8b44552a43acb6b340e8e1b288d21a5fe92"
},
"upload_url": "https://pinterest-media-upload.s3-accelerate.amazonaws.com/"
}Changes
- breaking
the
request property type changed fromstringto no type - info
the request required property
became not write-only - info
removed
subschema #1from the response bodyallOflist for the response status - info
added the non-success response with the status
- info
added the non-success response with the status
- info
added the non-success response with the status
- info
added the non-success response with the status
- info
added the non-success response with the status
- info
added the optional property
to the response with the status - info
added the optional property
to the response with the status - info
added the required property
to the response with the status - info
added the required property
to the response with the status - info
added the success response with the status
- breaking
- breaking
the response's body type changed from no type to
objectfor status
- breaking