Supported Formats

json

Errors

Code Description
404 Not found
409 Conflict
500 Server crashed for some reason

Examples

This endpoint returns a list of holds that have been placed on the cargo.
curl "https://app.octopi.co/api/v1/cargoes/ID/holds.json" -H "Accept: application/json" -H "Content-Type: application/json" -H "Authorization: Token token=YOURTOKEN"
{
  "holds": [
    {
      "lifted": false,
      "applied_at": "2016-11-30T14:12:05Z",
      "lifted_at": null,
      "lifted_until": null,
      "lifted_by": null,
      "hold_type_id": 1,
      "hold_type": "DETENTION HOLD",
      "actions": {
        "lift": {
          "method": "PUT",
          "url": "https://app.octopi.co/api/v1/cargoes/CARGO_ID/holds/HOLD_ID/lift.json"
        },
        "apply": {
          "method": "PUT",
          "url": "https://app.octopi.co/api/v1/cargoes/CARGO_ID/holds/HOLD_TYPE_ID/apply.json"
        }
      },
      "id": 51359,
      "reference_number": null,
      "applied_by": {
        "id": 3140,
        "created_at": "2020-08-04T07:56:04.939-04:00",
        "updated_at": "2022-03-28T11:11:59.496-04:00",
        "organization_id": 8,
        "agent_id": null,
        "shipping_line_id": null,
        "consignee_id": null,
        "email": "jane.smith@example.com",
        "firstname": "Jane",
        "lastname": "Smith",
        "office_phone": "",
        "mobile_phone": "",
        "title": "Clerical Officer",
        "address": "",
        "roles_users_count": 5,
        "work_location_type": "",
        "work_location_id": null,
        "trucking_company_id": null,
        "active": true,
        "is_equipment_operator": false,
        "high_contrast_ui": false,
        "freight_forwarder_id": null,
        "staff": false,
        "beta_tester": false,
        "locale": "en",
        "pending_approval": false,
        "broker_id": null,
        "enforce_mfa": false,
        "name": "Jane Smith"
      }
    },
    {
      "lifted_at": null,
      "lifted_until": null,
      "lifted_by": null,
      "lifted": false,
      "applied_at": null,
      "applied_by": null,
      "actions": {
        "lift": {
          "method": "PUT",
          "url": "https://app.octopi.co/api/v1/cargoes/CARGO_ID/holds/HOLD_ID/lift.json"
        },
        "apply": {
          "method": "PUT",
          "url": "https://app.octopi.co/api/v1/cargoes/CARGO_ID/holds/HOLD_TYPE_ID/apply.json"
        }
      },
      "hold_type_id": 2,
      "hold_type": "GATE MOVE INVOICE FEE",
      "reference_number": null,
      "id": 51360
    }
  ]
}

Params

Param name Description
id
required

Validations:

  • Must be a String