下单购买宠物
POST
/store/order
请求参数
Header 参数
X-Client-Version
string
客户端本版本号
默认值:
1.0.0
示例代码
Shell
JavaScript
Java
Swift
Go
PHP
Python
HTTP
C
C#
Objective-C
Ruby
OCaml
Dart
R
请求示例请求示例
Shell
JavaScript
Java
Swift
curl --location --request POST '/store/order' \
--header 'X-Client-Version;' \
--header 'Content-Type: text/plain' \
--data-raw ''
返回响应
🟢200成功
application/json
Body
id
integer <int64>
可选
petId
integer <int64>
可选
quantity
integer <int32>
可选
shipDate
string <date-time>
可选
status
enum<string>
可选
枚举值:
placedapproveddelivered
complete
boolean
可选
默认值:
false
user
object (User)
可选
id
integer
用户ID
gender
string
性别
username
string
用户
email
string
邮箱
phone
string
手机号
status
enum<string>
账号状态
枚举值:
normaldisabled
createdAt
string
创建时间
age
integer
年龄
birthday
string
生日
registerIp
string
注册IP
isVip
boolean
是否VIP会员
avatar
string
头像
city
string
城市
img
string
必需
示例
{
"id": 0,
"petId": 0,
"quantity": 0,
"shipDate": "2019-08-24T14:15:22Z",
"status": "placed",
"complete": false,
"user": {
"id": 0,
"gender": "string",
"username": "string",
"email": "string",
"phone": "string",
"status": "normal",
"createdAt": "string",
"age": 0,
"birthday": "string",
"registerIp": "string",
"isVip": true,
"avatar": "string",
"city": "string",
"img": "string"
}
}
🟠400下单出错