Octopi is a modern Terminal Operating System (TOS).

REST & Hypermedia

The Octopi API is a RESTful API using JSON and the HATEOAS paradigm. In every JSON response from the API, you will find a list of actions returned as a JSON array. These actions are all the methods available on the API resource. We encourage you to build your clients to use these actions dynamically. That way, if the API changes URLs, your client will keep functioning without changing the source code of your client application.

Authentication

The Octopi API uses HTTP Token Access Authentication.

To authenticate, you need to pass in your API Key (obtained from the Octopi Team) in the HTTP request header using an ‘Authorization’ header with the API key as a token. For example, the header should have “Token token=yourapikey”.

Dates and Times

The Octopi API returns all dates and times in ISO 8601 format and UTC.

Resources

Average truck visit durations
This resource allows you to fetch daily average truck visit durations.

Resource Description
GET /api/v1/average_truck_visit_durations.json Gets a list of average truck visit durations

Bill of ladings
This resources allows you to create bill of ladings in Octopi.

Resource Description
POST /api/v1/manifests/:manifest_client_identifier/bill_of_ladings.json
GET /api/v1/manifests/:manifest_client_identifier/bill_of_ladings.json
PATCH /api/v1/manifests/:manifest_client_identifier/bill_of_ladings/:bill_of_lading_client_identifier.json

Bill of ladings-holds
This resource allows you to view the holds on bill of ladings.

Resource Description
GET /api/v1/api/v1/manifests/:manifest_client_identifier/bill_of_ladings/:bill_of_lading_number/holds.json
DELETE /api/v1/manifests/:manifest_client_identifier/bill_of_ladings/:bill_of_lading_number/holds/:hold_id.json
PUT /api/v1/manifests/:manifest_client_identifier/bill_of_ladings/:bill_of_lading_number/holds/:hold_id.json

Billing-payment providers-paycargo
This resource allows PayCargo to interact with Octopi.

Resource Description
GET /api/v1/billing/payment_providers/paycargo/fees
POST /api/v1/billing/payment_providers/paycargo/payment

Bookings
This resource allows you to fetch one booking from Octopi.

Resource Description
GET /api/v1/bookings/:number.json

Cargoes
This resources allows you to create cargoes associated with a bill of lading in Octopi.

Resource Description
POST /api/v1/manifests/:manifest_client_identifier/bill_of_ladings/:number/cargoes.json

Cargoes-holds
This resource allows you to list or lift holds for cargo.

Resource Description
GET /api/v1/cargoes/:id/holds.json
PATCH /api/v1/cargoes/:cargo_id/holds/:id/lift.json

Consignees
This resources allows you to create, read, update, or delete consignees in Octopi.

Resource Description
GET /api/v1/consignees Returns the list of consignees
GET /api/v1/consignees/:id Returns information about a consignee
POST /api/v1/consignees Create a new consignee
PUT /api/v1/consignees/:id Updates a consignee record
DELETE /api/v1/consignees/:id Delete a consignee record

Consignees-bill of ladings
This resource returns bill of ladings linked to a consignee.

Resource Description
GET /api/v1/consignees/:consignee_id/bill_of_ladings.json

Consignees-packing list items
This resource returns packing list items linked to a consignee.

Resource Description
GET /api/v1/consignees/:consignee_id/packing_list_items.json

Containers
This resource allows you to interact with containers in Octopi.

Resource Description
GET /api/v1/containers/:number.json Returns information about a container
PUT /api/v1/containers/:number/strip Creates a full stripping movement on the container
PUT /api/v1/containers/:number/stuff Creates a full stuffing movement on the container

Containers-flex fields
This resource allows you modify flex fields for containers on Octopi.

Resource Description
PUT /api/v1/containers/:number/flex_fields/:label Updates a Container

Containers-holds
This resource allows you to list or lift holds for a container.

Resource Description
GET /api/v1/containers/:container_number/holds.json
PUT /api/v1/containers/:container_number/holds/:id/lift.json
PUT /api/v1/containers/:container_number/holds/:hold_type_id/apply.json

Containers-movements
This resource allows you to fetch information about movements.

Resource Description
GET /api/v1/containers/:container_number/movements.json

Containers-tags
This resource allows you to apply tags to containers in Octopi.

Resource Description
POST /api/v1/containers/:container_number/tags.json Apply tags to containers in Octopi.

Containers-weights
This resource allows you to update container gross weight in Octopi.

Resource Description
POST /api/v1/containers/:container_number/weights.json Updates a container gross weight.

Freight forwarders
This resources allows you to create, read, update, or delete freight forwarders in Octopi.

Resource Description
GET /api/v1/freight_forwarders.json Returns the list of freight forwarders
GET /api/v1/freight_forwarders/:id Returns information about a freight forwarder
POST /api/v1/freight_forwarders Create a new freight forwarder
PUT /api/v1/freight_forwarders/:id Updates a freight forwarder record
DELETE /api/v1/freight_forwarders/:id Soft deletes a freight forwarder record

General cargoes
This resource allows you to fetch data about general cargo.

Resource Description
GET /api/v1/general_cargoes.json Gets a list of general cargo
GET /api/v1/general_cargoes/:id.json Returns information about a specific general cargo

General cargoes-flex fields
This resource allows you modify flex fields for general_cargo on Octopi.

Resource Description
PUT /api/v1/general_cargoes/:id/flex_fields/:label Updates a specific general cargo

General cargoes-weights
This resource allows you to update general cargo gross weight in Octopi.

Resource Description
POST /api/v1/general_cargoes/:general_cargo_id/weights.json Updates a general cargo gross weight.

Invoices
This resource allows you to fetch customer invoices from Octopi.

Resource Description
GET /api/v1/invoices.json Gets a list of invoices
PUT /api/v1/invoices/:id.json Updates an invoice

Manifests
This resources allows you to create a manifest in Octopi.

Resource Description
POST /api/v1/manifests.json
DELETE /api/v1/manifests/:client_identifier
GET /api/v1/manifests

Movements
This resource allows you to fetch movements from Octopi.

Resource Description
GET /api/v1/movements.json Gets a list of movements

Packing list items
This resources allows you to create a packing list item in Octopi.

Resource Description
GET /api/v1/packing_list_items/:reference_number.json
POST /api/v1/bill_of_ladings/:bill_of_lading_number/packing_list_items.json
DELETE /api/v1/packing_list_items/:reference_number.json

Packing list items-cargoes
This resource allows you to list the cargo associated to a packing list item.

Resource Description
GET /api/v1/packing_list_items/:reference_number/cargoes.json

Packing lists
This resources allows you to create a packing list.

Resource Description
GET /api/v1/bill_of_ladings/:bill_of_lading_number/packing_lists.json
POST /api/v1/bill_of_ladings/:bill_of_lading_number/packing_lists.json
DELETE /api/v1/bill_of_ladings/:bill_of_lading_number/packing_lists/:client_identifier.json

Shipping lines
This resource allows you to create, read, and update shipping lines in Octopi.

Resource Description
GET /api/v1/shipping_lines.json Returns a list of shipping lines.
GET /api/v1/shipping_lines/:id Returns information about a shipping line.
POST /api/v1/shipping_lines.json Creates a new shipping line.
PUT /api/v1/shipping_lines/:id Updates a shipping line record.

Ships
This resource allows you to fetch information about vessels.

Resource Description
GET /api/v1/vessels/:name

Truck drivers
This resource lets clients manipulate truck driver information.

Resource Description
GET /api/v1/truck_drivers.json Gets a list of truck drivers
POST /api/v1/truck_drivers.json
PATCH /api/v1/truck_drivers/:number.json
GET /api/v1/truck_driver.json?number=:number&license_number=:license_number

Truck visits
This resource allows you to view or manipulate truck visits within Octopi.

Resource Description
GET /api/v1/truck_visits.json Gets a list of truck visits.
GET /api/v1/truck_visits/:id
POST /api/v1/truck_visits.json

Trucking companies
This resources allows you to create, read, update, or delete trucking companies in Octopi.

Resource Description
GET /api/v1/trucking_companies Returns the list of trucking companies
GET /api/v1/trucking_companies/:id Returns information about a trucking company
POST /api/v1/trucking_companies Create a new trucking company
PUT /api/v1/trucking_companies/:id Updates a trucking company record
DELETE /api/v1/trucking_companies/:id Soft deletes a trucking company record

Trucks
This resources allows you to create, read, update, or delete trucks in Octopi.

Resource Description
GET /api/v1/trucks Returns a list of trucks

Voyages
This resource allows you to fetch one voyage from Octopi.

Resource Description
GET /api/v1/voyages.json
GET /api/v1/voyages/:number.json

Voyages-bill of ladings
This resources allows you to fetch cargo information (Bill Of Lading and Packing List Items) for a voyage

Resource Description
GET /api/v1/voyages/:voyage_number/bill_of_ladings.json
GET /api/v1/voyages/VOYAGE_NUMBER/bill_of_ladings/BILL_OF_LADING_NUMBER.json

Voyages-bill of ladings-hold types
This resource allows you to edit the holds on a bill of lading.

Resource Description
PUT /api/v1/voyages/:voyage_number/bill_of_ladings/:bill_of_lading_number/hold_types/:hold_type_id/lift.json
PUT /api/v1/voyages/:voyage_number/bill_of_ladings/:bill_of_lading_number/hold_type/:hold_type_id/apply.json

Voyages-bill of ladings-holds
This resource allows you to view and edit the holds on cargo.

Resource Description
GET /api/v1/api/v1/voyages/:voyage_number/bill_of_ladings/:bill_of_lading_number/holds.json

Voyages-bill of ladings-packing list items

Resource Description
DELETE /api/v1/voyages/:voyage_number/bill_of_ladings/:bill_of_lading_number/packing_list_items.json

Voyages-consignees
This resources allows you to fetch consignees for voyages

Resource Description
GET /api/v1/voyages/:number/consignees.json

Voyages-flex fields
This resource allows you modify flex fields for voyages on Octopi.

Resource Description
PUT /api/v1/voyages/:number/flex_fields/:label Updates a Voyage

Voyages-movements
This resources allows you to fetch movements for containers that were discharged on a voyage

Resource Description
GET /api/v1/voyages/:number/movements.json

Voyages-tallies
This resource allows you to fetch data on the tallies for a voyage.

Resource Description
GET /api/v1/voyages/:voyage_number/tallies.json

Work queues
This resource allows you to fetch work queues from Octopi.

Resource Description
GET /api/v1/work_queues.json

Work queues-work queue items
This resource allows you to create a work queue item for a work queue

Resource Description
POST /api/v1/work_queues/:work_queue_id/work_queue_items.json

Yard areas
This resource allows you to fetch yard areas.

Resource Description
GET /api/v1/yard_areas.json Gets a list of yard areas