Skip to main content
POST
Attach customs documents to a shipment
This API is enabled per merchant account by Global-e. If it is not enabled for your account, the request returns 403 Forbidden with no response body.
Typical integration sequence. These APIs may be used together when an export declaration or bonded reporting is required, but they are independent endpoints — none is a prerequisite for another.
  1. Get shipping documents — obtain the label and tracking number
  2. Submit bonded information — report bonded vs free-circulation status per product (when bonded reporting is required)
  3. Get shipment information — retrieve product, pricing and declaration header data (when you need the data Global-e holds)
  4. Create the export document — your side, not a Global-e API
  5. Upload shipment documents — upload the document and its reference to Global-e (when a document must be attached)
  6. Dispatch orders — End of Day
Only steps 1 and 6 are universal. Steps 2 to 5 depend on the shipment type, the destination and your configuration. Where they apply, complete steps 2 and 5 before End of Day / Dispatch orders.
An export declaration is required only when the shipment leaves the EU customs territory and either contains bonded goods or contains free-circulation goods with a total value of €1,000 or more. When no declaration is required, steps 3 to 5 do not apply.
A successful response means Global-e has stored the document against the shipment. Global-e forwards the document and its reference to the carrier asynchronously afterwards, so a success response is not a confirmation that the carrier has accepted it.

Body

application/json
TrackingNumber
string
required

Tracking number of the shipment, as returned by GetShippingDocuments. Identifies the shipment the documents are attached to, and must belong to your merchant account.

Example:

"JD014600004882753258"

Documents
ShipmentDocument · object[]
required

The documents to attach to this shipment. At least one document must be provided; an empty list is rejected with A617. The current supported document type is EAD, and one EAD is attached per call. The list is an array so that further document types can be added later without changing the shape of the request.

Minimum array length: 1

Response

The document was validated and stored against the shipment. Storage only — Global-e forwards the document and its reference to the carrier asynchronously afterwards, so this response is not a confirmation that the carrier has accepted it.

Success
boolean

Indicates that the document was stored against the shipment. Returned only with HTTP 200, and always true. Failures are returned as an error response instead.

Example:

true