For AI agents: a documentation index is available at the root level at /llms.txt and /llms-full.txt. Append /llms.txt to any URL for a page-level index, or .md for the markdown version of any page.
HomeGuidesAPI Reference
HomeGuidesAPI Reference
  • Online API
    • API Environments
    • Direct Payment Flow
    • REST
    • HTTPS
    • Request Headers
    • Dates
    • Pagination
    • Authentication
    • Idempotent Requests
    • Timeouts
    • API Simulator
    • JavaScript afterpay.js
      • POSTCapture Payment
      • PUTUpdate Shipping Courier
      • GETGet Payment By Order ID
      • GETGet Payment By Token
      • GETList Payments
      • POSTCreate Refund
    • Errors
LogoLogo
Online APIPayments

Update Shipping Courier

PUT
https://global-api-sandbox.afterpay.com/v1/payments/:orderId/courier
PUT
/v1/payments/:orderId/courier
$curl -X PUT https://global-api-sandbox.afterpay.com/v1/payments/orderId/courier \
> -H "User-Agent: User-Agent" \
> -H "Content-Type: application/json" \
> -u "<username>:<password>" \
> -d '{}'
This endpoint updates an order with shipping courier information. The Clearpay team may utilise this information when providing support. ## Successful Response (200) Returns a [Payment object](/v-1/payment-object) in response. ## Connection Timeouts | Timeout | Time (Seconds) | | :------ | :------------- | | Open | 10 | | Read | 20 | ## Errors In addition to the [PUT/POST Errors](/v-1/put-post-errors) applicable to all PUT endpoints, the following errors are specific to Update Shipping Courier: | HTTP Status Code | errorCode | Description | | :-- | :-- | :-- | | **422** <br />Unprocessable Entity | `invalid_object` | A value for `shippedAt` was provided, but not a valid [ISO 8601](http://www.iso.org/iso/home/standards/iso8601.htm) date. Or, a value for `priority` was provided, but wasn't one of "STANDARD" or "EXPRESS". | | **412** <br />Precondition Failed | `precondition_failed` | No Clearpay Order was found matching the `orderId` provided. |
Was this page helpful?
Previous

Get Payment By Order ID

Next
Built with

This endpoint updates an order with shipping courier information. The Clearpay team may utilise this information when providing support.

Successful Response (200)

Returns a Payment object in response.

Connection Timeouts

TimeoutTime (Seconds)
Open10
Read20

Errors

In addition to the PUT/POST Errors applicable to all PUT endpoints, the following errors are specific to Update Shipping Courier:

HTTP Status CodeerrorCodeDescription
422
Unprocessable Entity
invalid_objectA value for shippedAt was provided, but not a valid ISO 8601 date. Or, a value for priority was provided, but wasn’t one of “STANDARD” or “EXPRESS”.
412
Precondition Failed
precondition_failedNo Clearpay Order was found matching the orderId provided.

Authentication

AuthorizationBasic

Basic authentication of the form Basic <base64(username:password)>.

Path parameters

orderIdstringRequired
The unique Clearpay Order ID to update.

Headers

User-AgentstringRequired
AcceptstringOptionalDefaults to application/json

Request

This endpoint expects an object.
shippedAtstringOptional

The date and time when the order was shipped, in ISO 8601 format.

namestringOptional
The name of the shipping courier.
trackingstringOptional
The shipping tracking number provided by the courier.
prioritystringOptional
The shipping priority. If provided, must be either "STANDARD" or "EXPRESS".