Shipments

Create a Shipment

Create a shipment for an invoice belonging to one of your sub-merchants.

post/shipments

Request

Request body

merchant_invoice_idstring required

ID of the invoice this shipment belongs to. The invoice must belong to one of your sub-merchants.

fulfillment_method'shipping_provider' | 'self_delivery' | 'customer_pickup' | 'services_only'

Method of fulfillment for the shipment. Determines what additional fields are required:

  • shipping_provider: Requires shipment_tracking_number and shipment_courier. File is not allowed.
  • self_delivery, customer_pickup, services_only: Require a file. Tracking number and courier are optional.
shipment_tracking_numberstring

Tracking number (required when fulfillment_method is shipping_provider, optional otherwise).

shipment_courierstring

Shipping courier (required when fulfillment_method is shipping_provider, optional otherwise). While any value can be accepted, instant verification is supported for specific couriers.

See the Shipments API documentation for the complete list of supported couriers.

send_emailboolean

Whether to send the buyer an invoice updated email.

Example request

{
  "merchant_invoice_id": "inv_1234567890abcdef",
  "fulfillment_method": "shipping_provider",
  "shipment_tracking_number": "1Z123E45678901234",
  "shipment_courier": "ups",
  "file": {
    "url": "https://bucket.s3.amazonaws.com/1234567890-document.pdf",
    "size": 204800,
    "metadata": {
      "original_filename": "proof_of_delivery.pdf"
    }
  }
}

Response

An object representing the Shipment.

idstring

Unique identifier of the Shipment.

merchant_invoice_idstring

ID of the associated merchant invoice.

fulfillment_method'shipping_provider' | 'self_delivery' | 'customer_pickup' | 'services_only'

Method of fulfillment for the shipment.

shipment_tracking_numberstring

Tracking number provided by the shipping courier.

shipment_courierstring

Shipping courier or provider name. While any value can be accepted, instant verification is supported for specific couriers.

See the Shipments API documentation for the complete list of supported couriers.

verification_status'verified' | 'pending'

Manual or automatic verification status of the shipment.

created_atstring date-time

Date time when the shipment was created.

updated_atstring date-time

Date time when the shipment was last updated.

tracking_statusstring nullable

Current tracking status of the shipment from the courier.

tracking_substatusstring nullable

Detailed tracking substatus providing additional context about the shipment's current state.

expected_deliverystring date-time nullable

Expected delivery date and time provided by the shipping courier.

Example response

{
  "id": "ship_1234567890abcdef",
  "merchant_invoice_id": "inv_1234567890abcdef",
  "fulfillment_method": "shipping_provider",
  "shipment_tracking_number": "1Z123E45678901234",
  "shipment_courier": "ups",
  "verification_status": "verified",
  "created_at": "2024-01-15T10:30:00Z",
  "updated_at": "2024-01-15T14:45:00Z",
  "tracking_status": "delivered",
  "tracking_substatus": "delivered_001",
  "expected_delivery": "2024-01-20T18:00:00Z"
}

Changes

No recorded changes to this operation across all 1 revision of this API.