ID で注文書を検索する
ID に基づいて購入注文書を検索します。
GET https://petstore3.swagger.io/api/v3/store/order/{orderId}
例
- API Key
- OAuth 2.0
cURL
GET "https://petstore3.swagger.io/api/v3/store/order/1" \
-H "accept: application/json" \
-H "api_key: <YOUR_API_KEY>"
cURL
GET "https://petstore3.swagger.io/api/v3/store/order/1" \
-H "accept: application/json" \
-H "Authorization: Bearer <YOUR_OAUTH_TOKEN>"
レスポンス
| コード | 説明 |
|---|---|
| 200 | 操作成功 |
| 400 | 指定された ID が無効です |
| 404 | 注文が見つかりません |
| default | 予期せぬエラー |
レスポンス例
200: 操作成功
Response
{
"id": 1,
"petId": 0,
"quantity": 0,
"shipDate": "2025-08-11T15:13:06.939Z",
"status": "placed",
"complete": false
}
パラメータ
パスパラメータ
| 名前 | タイプ | 説明 |
|---|---|---|
orderId | 整数 | 取得する注文書の ID |