受注削除
DELETE
/orders/{order_id}
const url = 'https://api.smaregi.dev/TARGET-CONTRACT-ID/ec-oms/orders/example';const options = {method: 'DELETE', headers: {Authorization: 'Bearer <token>'}};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request DELETE \ --url https://api.smaregi.dev/TARGET-CONTRACT-ID/ec-oms/orders/example \ --header 'Authorization: Bearer <token>'受注を削除します。
同梱されている受注は削除できません。
Authorizations
Section titled “Authorizations”Parameters
Section titled “Parameters”Path Parameters
Section titled “Path Parameters”order_id
required
string
受注ID
Responses
Section titled “Responses”削除成功
- 指定された項目が不正な場合
- 指定された受注がすでに削除されている場合
Media typeapplication/json
object
type
required
string
title
required
string
detail
One of:
string
Array<string>
status
integer
Examples
{ "type": "about:blank", "title": "BadRequest", "detail": [ "指定された項目が不正です: invalidKey" ], "status": 400}{ "type": "about:blank", "title": "BadRequest", "detail": "すでに削除されています", "status": 400}指定された受注IDが存在しない場合
Media typeapplication/json
object
type
required
string
title
required
string
detail
One of:
string
Array<string>
status
integer
Examples
Example指定された受注IDが存在しない場合
{ "type": "about:blank", "title": "NotFound", "detail": "指定されたIDのリソースが見つかりません", "status": 404}- 指定された受注が同梱されている場合
Media typeapplication/json
object
type
required
string
title
required
string
detail
One of:
string
Array<string>
status
integer
Examples
Example指定された受注が同梱されている場合
{ "type": "about:blank", "title": "Conflict", "detail": "同梱されているため削除できません", "status": 409}