Pets
Manage pets in the store inventory
The Pets API allows you to create, read, update, and delete pets in the store inventory.
Available Operations
| Method | Endpoint | Description |
|---|---|---|
| GET | /pet/{petId} |
Get a pet by ID |
| POST | /pet |
Add a new pet |
| PUT | /pet |
Update an existing pet |
| DELETE | /pet/{petId} |
Delete a pet |
| GET | /pet/findByStatus |
Find pets by status |
| GET | /pet/findByTags |
Find pets by tags |
| POST | /pet/{petId}/uploadImage |
Upload a pet image |
Pet Object
JSON
{
"id": 10,
"name": "Buddy",
"category": {
"id": 1,
"name": "Dogs"
},
"photoUrls": [
"https://example.com/buddy.jpg"
],
"tags": [
{"id": 1, "name": "friendly"}
],
"status": "available"
}
Update an existing pet.
Add Pet
Usage Notes When creating a new pet, the id field is optional. If omitted, the system will automatically generate a unique identifier. Status Values The status field accepts one of the following values: Status Description available Pet is available for purchase p...