Project

General

Profile

Order


Get Orders

This method retrieves a list of orders you received or placed.

Request

Method URI
GET /orders

* Parameters

Parameter Name Value Optional Description
direction String Y The direction of the order to get. Acceptable values are:
- "out": Gets placed orders.
- "in": Gets received orders. (default)
status String Y The status of the order to include or exclude.
- If you don't specify this value, this method retrieves orders in any status.
- You can pass a comma-separated string to specify multiple status to include/exclude.
- You can add a minus(-) sign to specify a status to exclude
filed Boolean Y Indicates whether the result retries filed or un-filed orders. Acceptable values are:
- "true"
- "false": (default)

* Request body

Do not supply a request body with this method.
 

Response

If successful, this method returns a list of the the summary of an order resource as "data" in the response body.
Each entry in the list includes followings:
- order_id
- date_ordered
- seller_name
- store_name
- buyer_name
- total_count
- unique_count
- status
- payment.method
- payment.status
- payment.date_paid
- payment.currency_code
- cost.subtotal
- cost.grandtotal
- cost.currency_code
To retrieve additional properties, see the Get Order.

Example

  • GET /orders
    • Retrieves a list of received orders
  • GET /orders?direction=out
    • Retrieves a list of placed orders
  • GET /orders?status=pending,completed
    • Retrieves PENDING or COMPLETED received orders
  • GET /orders?status=-purged
    • Retrieves a list of received orders not in PURGED status
  • GET /orders?filed=true&status=completed
    • Retrieves a list of received and filed orders in COMPETED status

Get Order

This method retrieves the details of a specific order.

Request

Method URI
GET /orders/{order_id}

* Parameters

Parameter Name Value Optional Description
order_id Integer N The ID of the order to get

* Request body

Do not supply a request body with this method.
 

Response

If successful, this method returns an order resource as "data" in the response body.

Example

  • GET /orders/1234
    • Retrieves order # 1234

Get Order Items

This method retrieves a list of items for the specified order.

Request

Method URI
GET /orders/{order_id}/items

* Parameters

Parameter Name Value Optional Description
order_id Integer N The ID of the order

* Request body

Do not supply a request body with this method.
 

Response

If successful, this method returns a list of items batch list as "data" in the response body. An inner list indicates that items included in one batch of the order (order item batch).

Example

  • GET /orders/1234/items
    • Retrieves a list of items for order #1234

Get Order Messages

This method retrieves a list of messages for the specified order that the user receives as a seller.

Request

Method URI
GET /orders/{order_id}/messages

* Parameters

Parameter Name Value Optional Description
order_id Integer N The ID of the order

* Request body

Do not supply a request body with this method.
 

Response

If successful, this method returns a list of order message resource as "data" in the response body.

Example

  • GET /orders/1234/messages
    • Retrieves a list of messages for order #1234

Get Order Feedback

This method retrieves a list of feedback for the specified order.

Request

Method URI
GET /orders/{order_id}/feedback

* Parameters

Parameter Name Value Optional Description
order_id Integer N The ID of the order

* Request body

Do not supply a request body with this method.
 

Response

If successful, this method returns a list of feedback resource as "data" in the response body.

Example

  • GET /orders/1234/feedback
    • Retrieves a list of feedback for order #1234

Update Order

This method updates properties of a specific order.

Request

Method URI
PUT /orders/{order_id}

* Parameters

Parameter Name Value Optional Description
order_id Integer N The ID of the order to update

* Request body

In the request body, supply an order resource. The order resource object can include:
  • cost.credit
  • cost.insurance
  • cost.etc1
  • cost.etc2
  • cost.shipping
  • shipping.date_shipped
  • shipping.tracking_no
  • shipping.tracking_link
  • shipping.method_id
  • remarks
  • is_filed

Any attempt to update other fields that are not listed above would be ignored.
Cost fields will only be updated if the order is in unpaid status. Otherwise they will be ignored.
If sales tax are to be collected by BL, every change made to the costs will recalculate the sales tax.

{
    "shipping": {
        "date_shipped": "Timestamp",
        "tracking_no": "String",
        "tracking_link": "String",
        "method_id": "Integer" 
    },
    "cost": {
        "shipping": "String",
        "insurance": "String",
        "credit": "String",
        "etc1": "String",
        "etc2": "String" 
    },
    "is_filed" : "Boolean",
    "remarks" : "String" 
}

 

Response

If successful, this method returns an order resource as data in the response body.

Example

  • PUT /orders/1234
    • Updates order #1234

Update Order Status

This method updates the status of a specific order.

Request

Method URI
PUT /orders/{order_id}/status

* Parameters

Parameter Name Value Optional Description
order_id Integer N The ID of the order to update status

* Request body

In the request body, supply a patch object with the following structure:

Property Name Value Description Notes
field String The field name of the resource to be updated Must be "status"
value String The new status value Available status
{
    "field" : "status",
    "value" : "PENDING" 
}

 

Response

If successful, this method returns an empty "data".

Example

  • PUT /orders/1234/status
    • Updates status of order #1234

Update Payment Status

This method updates the payment status of a specific order.

Request

Method URI
PUT /orders/{order_id}/payment_status

* Parameters

Parameter Name Value Optional Description
order_id Integer N The ID of the order to update payment status

* Request body

In the request body, supply a patch object with the following structure:

Property Name Value Description Notes
field String The field name of the resource to be updated Must be "payment_status"
value String The new status value Available status
{
    "field" : "payment_status",
    "value" : "Received" 
}

 

Response

If successful, this method returns an empty "data".

Example

  • PUT /orders/1234/payment_status
    • Updates payment status of order #1234

Send Drive Thru

Send "Thank You, Drive Thru!" e-mail to a buyer

Request

Method URI
POST /orders/{order_id}/drive_thru

* Parameters

Parameter Name Value Optional Description
order_id Integer N The ID of the order to update payment status
mail_me Boolean Y Indicates that whether you want to cc yourself or not

* Request body

Do not supply a request body with this method
 

Response

If successful, this method returns an empty "data".

Example

  • POST /orders/1234/drive_thru?mail_me=true
    • Send "Thank You, Drive Thru!" e-mail for order 1234 to a buyer and yourself

Add picture from clipboard (Maximum size: 24.4 MB)