Orders

Request Order Invoice Creation

Changed on

Triggers SHOPLINE to create an invoice for an order through the merchant's configured invoice provider. An optional runtime-only invoice remark can be included.<br> 透過商家設定的發票服務商觸發 SHOPLINE 為訂單開立發票,並可選填僅供本次開票使用的發票備註。

post/orders/{orderId}/request_invoice_creation

Request

  • Base URL
    https://open.shopline.io/v1
  • URL
    https://open.shopline.io/v1/orders/{orderId}/request_invoice_creation
  • Auth
    HTTP bearer

Path parameters

orderIdstring required

Order ID<br>訂單 ID

Request body

invoice_remarkstring nullable

Optional invoice remark used only during invoice creation. Only Chinese characters, English letters, digits, and spaces are accepted.<br> 僅於本次開票使用的選填備註,只接受中英數和空白。

Example request

{
  "invoice_remark": "受託代銷"
}

Response

Invoice created

errorobject nullable required
trace_idstring required

Example response

{
  "data": {
    "invoice_tax_type": "1",
    "invoice_number": "FT07050346",
    "invoice_date": "2021-07-08",
    "updated_at": "2021-07-16T09:49:54.615Z",
    "created_at": "2021-07-16T09:49:54.615Z",
    "cancelled_at": "2021-07-16T09:49:54.615Z"
  },
  "trace_id": "69cde185da1af363157bc1b3711a28c5"
}

Changes