License: MIT
| Description | URL |
|---|---|
| http://petstore.swagger.io/v1 | http://petstore.swagger.io/v1 |
List all pets
Input parameters
| Parameter | In | Type | Default | Nullable | Description |
|---|---|---|---|---|---|
ApiKeyAuth |
header | string | N/A | No | API key |
BasicAuth |
header | string | N/A | No | Basic authentication |
limit |
query | integer | No | How many items to return at one time (max 100) |
Responses
=== "200 OK"
=== "application/json"
```json
[
{
"id": 26,
"name": "string",
"tag": "string",
"category": "One"
}
]
```
<span class="small-note">⚠️</span> <em class="small-note warning">This example has been generated automatically from the schema and it is not accurate. Refer to the schema for more information.</em>
??? hint "Schema of the response body"
```json
{
"type": "array",
"items": {
"$ref": "#/components/schemas/Pet"
}
}
```
**Response headers**
| Name | Description | Schema |
| --- | --- | --- |
| `x-next` | A link to the next page of responses |<span class="string-type">string</span> |
=== "Other responses"
=== "application/json"
```json
{
"code": 26,
"message": "string"
}
```
<span class="small-note">⚠️</span> <em class="small-note warning">This example has been generated automatically from the schema and it is not accurate. Refer to the schema for more information.</em>
??? hint "Schema of the response body"
```json
{
"type": "object",
"required": [
"code",
"message"
],
"properties": {
"code": {
"type": "integer",
"format": "int32"
},
"message": {
"type": "string"
}
}
}
```
Create a pet
Input parameters
| Parameter | In | Type | Default | Nullable | Description |
|---|---|---|---|---|---|
ApiKeyAuth |
header | string | N/A | No | API key |
BasicAuth |
header | string | N/A | No | Basic authentication |
Responses
=== "201 Created" === "Other responses"
=== "application/json"
```json
{
"code": 26,
"message": "string"
}
```
<span class="small-note">⚠️</span> <em class="small-note warning">This example has been generated automatically from the schema and it is not accurate. Refer to the schema for more information.</em>
??? hint "Schema of the response body"
```json
{
"type": "object",
"required": [
"code",
"message"
],
"properties": {
"code": {
"type": "integer",
"format": "int32"
},
"message": {
"type": "string"
}
}
}
```
Info for a specific pet
Input parameters
| Parameter | In | Type | Default | Nullable | Description |
|---|---|---|---|---|---|
ApiKeyAuth |
header | string | N/A | No | API key |
BasicAuth |
header | string | N/A | No | Basic authentication |
petId |
path | string | No | The id of the pet to retrieve |
Responses
=== "200 OK"
=== "application/json"
```json
{
"id": 26,
"name": "string",
"tag": "string",
"category": "One"
}
```
<span class="small-note">⚠️</span> <em class="small-note warning">This example has been generated automatically from the schema and it is not accurate. Refer to the schema for more information.</em>
??? hint "Schema of the response body"
```json
{
"type": "object",
"required": [
"id",
"name"
],
"properties": {
"id": {
"type": "integer",
"format": "int64"
},
"name": {
"type": "string"
},
"tag": {
"type": "string"
},
"category": {
"type": "string",
"enum": [
"One",
"Two",
"Three"
]
}
}
}
```
=== "Other responses"
=== "application/json"
```json
{
"code": 26,
"message": "string"
}
```
<span class="small-note">⚠️</span> <em class="small-note warning">This example has been generated automatically from the schema and it is not accurate. Refer to the schema for more information.</em>
??? hint "Schema of the response body"
```json
{
"type": "object",
"required": [
"code",
"message"
],
"properties": {
"code": {
"type": "integer",
"format": "int32"
},
"message": {
"type": "string"
}
}
}
```
Input parameters
| Parameter | In | Type | Default | Nullable | Description |
|---|---|---|---|---|---|
ApiKeyAuth |
header | string | N/A | No | API key |
BasicAuth |
header | string | N/A | No | Basic authentication |
Request body
=== "application/json"
??? hint "Schema of the request body"
```json
{
"oneOf": [
{
"$ref": "#/components/schemas/Cat"
},
{
"$ref": "#/components/schemas/Dog"
}
]
}
```
Responses
=== "200 OK"
| Name | Type | Description |
|---|---|---|
age |
integer | |
hunts |
boolean |
| Name | Type | Description |
|---|---|---|
bark |
boolean | |
breed |
string |
| Name | Type | Description |
|---|---|---|
code |
integer(int32) | |
message |
string |
| Name | Type | Description |
|---|---|---|
category |
string | |
id |
integer(int64) | |
name |
string | |
tag |
string |
Type: Array<Pet>
Type: Array<integer(int64)>
<tr>
<td>BasicAuth</td>
<td>http</td>
<td>basic</td>
<td></td>
</tr>
<tr>
<td>ApiKeyAuth</td>
<td>apiKey</td>
<td></td>
<td></td>
</tr>
</tbody>
| Name | Type | Scheme | Description |
|---|