create_pet
Creates a new pet in the store. Duplicates are allowed
Method
- JSON-RPC method name:
create_pet - JSON-RPC version:
2.0
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
| newPet | object | no | Pet to add to the store. |
Parameter schema
{
"newPet": {
"description": "Pet to add to the store.",
"required": false,
"schema": {
"type": "object",
"required": [
"name"
],
"properties": {
"name": {
"type": "string"
},
"tag": {
"type": "string"
}
}
}
}
}
Result
- Name:
pet - Description: the newly created pet
- Type:
allOf
Result schema
{
"allOf": [
{
"type": "object",
"required": [
"name"
],
"properties": {
"name": {
"type": "string"
},
"tag": {
"type": "string"
}
}
},
{
"required": [
"id"
],
"properties": {
"id": {
"type": "integer"
}
}
}
]
}
Positional parameters
Parameter order:
newPet
Errors
This method may return JSON-RPC standard errors (e.g. -32600, -32601, -32602, -32603) as well as application-specific errors.
TODO: Document method-specific error codes and conditions.