Delete a pet
On this page
DELETE /pets/{petId} Deprecated
Production: https://petstore.example.com/v1Sandbox: https://sandbox.petstore.example.com/v1Live demo on docvia.dev; accepts any token: /api/petstore/v1
Use Update a pet with status: archived instead; deleted pets cannot be restored.
curl https://petstore.example.com/v1/pets/1042 \
--request DELETE \
--header 'Authorization: Bearer <token>' DELETE /api/petstore/v1/pets/1042
/api/petstore/v1
Kept in memory for this visit and used on every page of this API; never saved.
Path
Authorization
bearerAuth JWT bearer token in the Authorization header
A token from the dashboard's API keys page.
Path parameters
petId integer<int64> required
The pet's id.
>= 1
Responses
The pet was deleted.
No resource with that id.
Response application/json
code string required
message string required
Example
{
"code": "not_found",
"message": "No pet with id 1042."
}