Mark Shipped
Last updated: 04-Jan-2022
Rate this article:
Overview
The mark_shipped call is used to attempt to mark an order as shipped and will attempt to reauthorize sale if specified in call. This call will send the SHIP_STATUS_CHANGED INS message.
URL: https://www.2checkout.com/api/sales/mark_shipped
HTTP Method: POST
Input Parameters
| Parameter | Description |
|---|---|
| sale_id | The order number/sale ID to mark shipped. Optional when invoice_id is present. |
| invoice_id | ID of the invoice to add tracking information to. Required on sales with more than one invoice. |
| tracking_number | The tracking number issued by the shipper. Required. |
| cc_customer | Specify whether the customer should be automatically notified. Use “1” for true. Defaults to false. Optional. |
| reauthorize | Reauthorize payment if payment authorization has expired. Defaults to false. Optional. |
| comment | Any text except for “<” and “>” up to 255 chars in length. Optional. |
Data Returned
| Parameter | Description |
|---|---|
| response_code | Tells the user whether or not the operation was successful. |
| response_message |
Tells the user why the operation was or was not successful. |
Example API Call
curl -X POST https://www.2checkout.com/api/sales/mark_shipped \ -H 'Accept: application/json' -u 'username:password' \ -d 'tracking_number=123' -d 'cc_customer=1' -d 'sale_id=1234567890'Example Successful Response
{ "response_code" : "OK", "response_message" : "Sale marked shipped." }Common Error Codes
| Code | Description |
|---|---|
| PARAMETER_MISSING | Required parameter missing: |
| PARAMETER_INVALID | Invalid value for parameter: |
| RECORD_NOT_FOUND | Unable to find record. |
| FORBIDDEN | Access denied to sale. |
Method Specific Error Codes
| Code | Description |
|---|---|
| NOTHING_TO_DO | Item not shippable. |
| TOO_LATE | Payment is already pending or deposited and cannot be reauthorized. |
| TOO_SOON | Please wait until the next day before trying to reauthorize again. |
| FAILED | Failed to reauthorize payment. |
| INTERNAL_ERROR | Failed to marked shipped but reauthorization succeeded. |
| INTERNAL_ERROR | Failed to marked shipped. |
Rate this article: