Create Shipment Exception

POST /shipment_exceptions

Create a Shipment Exception for a Shipment

  • Clients can create shipment exceptions of a single type currently:requested_hold_to_collect

  • A shipment must have a pending or confirmed status to create a requested_hold_to_collect shipment exception.

  • hold_until date cannot be greater than 30 days from the associated shipment's created_at timestamp.

Headers

  • Authorization string Required

    Authorize your API calls with an Arta API token

application/json

Body

  • shipment_exception object Required

    Additional properties are allowed.

    Hide shipment_exception attributes Show shipment_exception attributes object
    • Optionally provide a date to hold collection for the shipment. Values should be in the YYYY-MM-DD format. Hold until dates must be fewer than 30 days from the shipment's created_at datetime.

    • shipment_id string Required

      The ID for the shipment associated to the shipment exception

    • type string Required

      The type ID for this resource. Options are defined in the Shipment Exception Types metadata endpoint. Currently, the only accepted type for client-created shipment exceptions is requested_hold_to_collect.

      Value is requested_hold_to_collect.

Responses

  • 201 application/json

    Successful response

    Hide headers attributes Show headers attributes
    Hide response attributes Show response attributes object
    • created_at string(date-time)

      A NaiveDatetime-formatted timestamp describing when the exception was created with microsecond precision

    • An additional label providing context about the exception type (optional)

    • hold_until string(date) | null

      The date the shipment will be held until

    • id string(uuid)

      The id of the exception in UUID format

    • package_id integer(int64) | null

      The package associated with this exception (optional)

    • resolution string | null

      A brief description of the method by which this exception was resolved

    • shipment_id string(uuid)

      The id of the shipment associated with this exception

    • source string

      The source of the exception

    • status string

      The current status for this exception

      Values are new, in_progress, or resolved.

    • type string

      The type of exception

    • updated_at string(date-time)

      A NaiveDatetime-formatted timestamp describing when the exception was last updated with microsecond precision

POST /shipment_exceptions
curl \
 -X POST https://api.arta.io/shipment_exceptions \
 -H "Content-Type: application/json" \
 -H "Authorization: ARTA_APIKey s0e1t2e3c4a5s6t7r8o9n10o11m12y" \
 -d '{"shipment_exception":{"type":"requested_hold_to_collect","hold_until":"2023-08-15","shipment_id":"5baff45a-281d-416e-9310-a4a7c637952e"}}'
Request example
{
  "shipment_exception": {
    "type": "requested_hold_to_collect",
    "hold_until": "2023-08-15",
    "shipment_id": "5baff45a-281d-416e-9310-a4a7c637952e"
  }
}
Response examples (201)
{
  "id": "d686ad3b-33fd-454c-a7aa-94b1ecbc539f",
  "type": "held_at_customs",
  "source": "api",
  "status": "new",
  "created_at": "2023-05-26T19:33:19.693833",
  "hold_until": null,
  "package_id": 4366794,
  "resolution": null,
  "updated_at": "2023-05-26T19:33:19.693833",
  "shipment_id": "a5cbb58c-43ab-4658-9999-98a33b0070d5",
  "exception_type_label": null
}