Skip to main content

Upload an image

Upload an image for a pet.

POST https://petstore3.swagger.io/api/v3/pet/{petId}/uploadImage

Examples

cURL
POST "https://petstore3.swagger.io/api/v3/pet/210/uploadImage" \
-H "accept: application/json" \
-H "Content-Type: multipart/form-data" \
-H "api_key: <YOUR_API_KEY>" \
--form "file=@/path/to/your/file"

Responses

CodeDescription
200Successful operation
defaultUnexpected error
Response example

200: Successful operation

Response
{
"code": 200,
"type": "unknown",
"message": "additional data"
}

Parameters

Path parameters
NameTypeDescription
petIdintegerID of pet to update
Form data parameters
NameTypeDescription
additionalMetadatastringExtra data to pass to server.
filefileFile to upload.