POST
/pet/{petId}/uploadImageUpload a pet image
Uploads an image for a pet in the store. Identify the pet with petId and send the image as an octet-stream request body; you can include additionalMetadata as a query parameter.
- IdempotentThe SDK sends
Idempotency-Key, so a retried request is only applied once.
petIdintegerrequired
The integer identifier of the pet to update with the image.
additionalMetadatastringoptional
Optional additional information to associate with the uploaded image.
200Returns an upload result object containing a code, type, and message.
codeintegeroptional
typestringoptional
messagestringoptional
400Returned when no file is uploaded.
404Returned when the pet does not exist.
defaultReturned when an unexpected error occurs.
Error handling
A 400 is returned when no file is uploaded, and a 404 is returned when the pet is not found. The petId path parameter must identify the pet to receive the image.