Version: 1.0.0
Base URL: https://petstore.example.com
GET /pets
Lists all pets in the store.
| Name | Type | Required | Description |
|---|---|---|---|
| limit | integer | No | Maximum number of pets to return |
[
{
"id": "pet-001",
"name": "Buddy",
"tag": "dog"
}
]
curl -X GET https://petstore.example.com/pets?limit=10
POST /pets
Creates a new pet record.
| Field | Type | Required | Description |
|---|---|---|---|
| id | string | Yes | Unique pet identifier |
| name | string | Yes | Pet name |
| tag | string | No | Optional tag/label |
{
"id": "pet-001",
"name": "Buddy",
"tag": "dog"
}
curl -X POST https://petstore.example.com/pets \
-H "Content-Type: application/json" \
-d '{"id": "pet-001", "name": "Buddy", "tag": "dog"}'
GET /pets/{petId}
Retrieves a specific pet by its ID.
| Name | Type | Required | Description |
|---|---|---|---|
| petId | string | Yes | The ID of the pet to retrieve |
{
"id": "pet-001",
"name": "Buddy",
"tag": "dog"
}
curl -X GET https://petstore.example.com/pets/pet-001
| Field | Type | Required | Description |
|---|---|---|---|
| id | string | Yes | Unique identifier |
| name | string | Yes | Pet name |
| tag | string | No | Optional category tag |