This resource allows clients to view, create, and delete a interchange for truck visits in Octopi.
List all the interchanges for the given truck visit ID.
Code | Description |
---|---|
404 | Not found. |
422 | Unprocessable Entity. |
500 | Internal Server Error. |
409 | Entity conflict. |
curl --location --request GET 'https://app.octopi.co/api/v1/truck_visits/1876441/interchanges.json' --header 'Content-Type: application/json' --data-raw '{}'
[ { "interchange_url": "http://app.octopi.co/api/v1/truck_visits/1876441/interchanges/2205893", "truck_visit_id": 1876441, "action_type": "interchange_in", "container_number": "CONZ1234674", "container_status": "full", "container_usage": 0, "container_has_damage": null, "container_vgm": null, "container_seal": null, "booking": "BOOKING12APR", "export_release": "EXP1", "bill_of_lading": null, "delivery_order": null, "chassis_number": "TESTCH-201", "chassis_weight": null, "genset": null, "genset_seal": null, "genset_fuel_level": null, "genset_has_reefer_compartment_seal": null, "genset_weight": null, "reefer_temperature": null, "reefer_temperature_unit": null, "reefer_set_point_temperature": null, "operating_reefer": false, "reefer_supply_temperature": null, "reefer_humidity": null, "reefer_ventilation": null, "scale_weight": null, "truck_weight": null, "completed_at": null } ]
Param name | Description |
---|---|
truck_visit_id required |
Truck visit ID. Validations:
|
Show interchange for a given interchange ID.
Code | Description |
---|---|
404 | Not found. |
422 | Unprocessable Entity. |
500 | Internal Server Error. |
409 | Entity conflict. |
curl --location --request GET 'https://app.octopi.co/api/v1/truck_visits/34234/interchanges/123.json' --header 'Content-Type: application/json'
{ "truck_visit_id": 34234, "action_type": "interchange_in", "container_number": "CONZ1234674", "container_status": "full", "container_usage": 0, "container_has_damage": null, "container_vgm": null, "container_seal": null, "booking": "BOOKING12APR", "export_release": "EXP1", "bill_of_lading": null, "delivery_order": null, "chassis_number": "TESTCH-201", "chassis_weight": null, "genset": null, "genset_seal": null, "genset_fuel_level": null, "genset_has_reefer_compartment_seal": null, "genset_weight": null, "reefer_temperature": null, "reefer_temperature_unit": null, "reefer_set_point_temperature": null, "operating_reefer": false, "reefer_supply_temperature": null, "reefer_humidity": null, "reefer_ventilation": null, "scale_weight": null, "truck_weight": null, "completed_at": null, "interchange": null }
Param name | Description |
---|---|
id required |
Interchange ID. Validations:
|
truck_visit_id required |
Truck visit ID. Validations:
|
This API endpoint allows you to delete an interchange for a specific truck visit.
Code | Description |
---|---|
404 | Not found. |
422 | Unprocessable Entity. |
500 | Internal Server Error. |
409 | Entity conflict. |
curl "https://app.octopi.co/api/v1/truck_visits/123/interchanges/353388.json" -X DELETE -H "Accept: application/json" -H "Content-Type: application/json" -H "Authorization: Token token=YOUR TOKEN HERE"
{ "id": 353388 }
Param name | Description |
---|---|
id required |
Interchange ID. Validations:
|
truck_visit_id required |
Truck visit ID. Validations:
|
Create an interchange for a truck visit.
Code | Description |
---|---|
404 | Not found. |
422 | Unprocessable Entity. |
500 | Internal Server Error. |
409 | Entity conflict. |
curl --location --request POST 'https://app.octopi.co/api/v1/truck_visits/1876441/interchanges.json' --header 'Content-Type: application/json' --data-raw '{ "purpose": "drop_off_container", "container_number": "CAIU2340022", "container_status": "full", "booking_number": "10543688", "chassis_number": "SEFZ104186" }'
{ "id": 12345, "container_status": "full", "truck_visit_id": 4567, "complete": false, "completed_at": null, "for_container": true, "for_chassis": false, "for_genset": false, "type": "interchange_in", "container": { "id": 1119659, "number": "CAIU2340022", "status": "full", "has_damages": false, "is_reefer": false, "is_flatrack": false, "unlifted_holds_exist": false, "chassis": { "id": 882733, "number": "SEFZ104186" } }, "chassis": { "id": 882733, "number": "SEFZ104186" }, "booking": { "id": 287504, "trucking_company_id": 467, "is_runner": false, "booking_number": "10543688", "voyage_number": "200S", "ship_name": "FS IPANEMA", "port_of_discharge": "ARUBA (AWAUA)", "port_of_loading": "PORT EVERGLADES (USPEF)", "port_of_delivery": "ARUBA (AWAUA)", "shipper": { "name": "SHIPPER INC." }, "trucking_company": { "name": "Seaboard" }, "items": [ { "id": 16193771, "line_item_number": 10, "quantity": 1, "description": "", "container": { "id": null, "display_name": null }, "dock_receipt_cargos": [], "hazmat_codes": [], "hazmat_ids_and_codes": {}, "hazmat_classes": [], "container_type": { "label": "20CT" } }, { "id": 1395330, "line_item_number": 4, "quantity": 1, "description": "CARGO NOS", "container": { "id": null, "display_name": null }, "dock_receipt_cargos": [], "hazmat_codes": [], "hazmat_ids_and_codes": {}, "hazmat_classes": [], "container_type": { "label": "40HC" } } ], "all_items": [ { "id": 16193771, "line_item_number": 10, "quantity": 1, "description": "", "container": { "id": null, "display_name": null }, "dock_receipt_cargos": [], "hazmat_codes": [], "hazmat_ids_and_codes": {}, "hazmat_classes": [], "container_type": { "label": "20CT" } }, { "id": 1395327, "line_item_number": 1, "quantity": 1, "description": "CARGO NOS", "container": { "id": 1101190, "display_name": "BSIU2346474" }, "dock_receipt_cargos": [], "hazmat_codes": [], "hazmat_ids_and_codes": {}, "hazmat_classes": [], "container_type": { "label": "20CT" } }, { "id": 1395328, "line_item_number": 2, "quantity": 1, "description": "CARGO NOS", "container": { "id": 1119413, "display_name": "SMLU7903607" }, "dock_receipt_cargos": [], "hazmat_codes": [], "hazmat_ids_and_codes": {}, "hazmat_classes": [], "container_type": { "label": "20CT" } }, { "id": 1395330, "line_item_number": 4, "quantity": 1, "description": "CARGO NOS", "container": { "id": null, "display_name": null }, "dock_receipt_cargos": [], "hazmat_codes": [], "hazmat_ids_and_codes": {}, "hazmat_classes": [], "container_type": { "label": "40HC" } }, { "id": 1395329, "line_item_number": 3, "quantity": 1, "description": "CARGO NOS", "container": { "id": 1119444, "display_name": "SMLU3105445" }, "dock_receipt_cargos": [], "hazmat_codes": [], "hazmat_ids_and_codes": {}, "hazmat_classes": [], "container_type": { "label": "20CT" } }, { "id": 1395333, "line_item_number": 7, "quantity": 1, "description": "CARGO NOS", "container": { "id": 1114166, "display_name": "TCNU6028886" }, "dock_receipt_cargos": [], "hazmat_codes": [], "hazmat_ids_and_codes": {}, "hazmat_classes": [], "container_type": { "label": "40HC" } } ] }, "export_release": null }
Param name | Description |
---|---|
truck_visit_id required |
Truck visit ID. Validations:
|
purpose required |
Purpose of the interchange. Validations:
|
container_number optional |
Container number to create interchange. Validations:
|
container_status optional |
Container status. Validations:
|
booking_number optional |
Booking number for the interchange. Validations:
|
chassis_number optional |
Chassis number. Validations:
|
genset_number optional |
Genset number. Validations:
|
export_release_number optional |
Export release number for the interchange. Validations:
|
bill_of_lading_number optional |
Bill of lading number for the interchange. Validations:
|
delivery_order_number optional |
Delivery order number for the interchange. Validations:
|
completed_at optional |
The date and time at which interchange was completed, in ISO 8601 format (Eg 2023-04-13T14:30:00Z). Providing this value will create the interchange with a completed status. Validations:
|
temperature_letter_port_of_discharge optional |
Temperature letter port of discharge (eg. “HTPAP”) Validations:
|
temperature_letter_vgm optional |
Temperature letter VGM in your organization’s weight unit preference (eg. 2345.0) Validations:
|
This API endpoint allows you to update a pending interchange.
Code | Description |
---|---|
404 | Not found. |
422 | Unprocessable Entity. |
500 | Internal Server Error. |
409 | Entity conflict. |
curl "https://app.octopi.co/api/v1/truck_visits/123/interchanges/12345.json" -X PATCH -H "Accept: application/json" -H "Content-Type: application/json" -H "Authorization: Token token=ADD TOKEN HERE -d '{ "container_number": "CON123456", "booking_number": "BOOK1234", "chassis_number": "CH1234", "genset_number": "GEN123", "export_release_number": "EXP123", "bill_of_lading_number": null, "delivery_order_number": null, "completed_at": "2023-06-28T21:12:29.128+09:00", }'
{ "id": 12345, "container_status": "full", "truck_visit_id": 123456, "complete": true, "completed_at": "2023-07-03T09:24:09-05:00", "for_container": true, "for_chassis": false, "for_genset": false, "type": "interchange_in", "container": { "id": 12345, "number": "CON123456", "status": "full", "has_damages": false, "is_reefer": false, "is_flatrack": false, "unlifted_holds_exist": false }, "booking": { "id": 123456, "trucking_company_id": null, "is_runner": true, "booking_number": "111111", "voyage_number": null, "ship_name": null, "port_of_discharge": null, "port_of_loading": null, "port_of_delivery": null, "items": [], "all_items": [] }, "export_release": null, "interchange": null }
Param name | Description |
---|---|
id required |
Interchange ID. Validations:
|
truck_visit_id required |
Truck visit ID. Validations:
|
container_number optional |
The container number used for the interchange. Validations:
|
booking_number optional |
The booking number used for the interchange. Validations:
|
chassis_number optional |
The chassis number used for the interchange. Validations:
|
genset_number optional |
The genset number used for the interchange. Validations:
|
export_release_number optional |
Export release number used for the interchange. Validations:
|
bill_of_lading_number optional |
Bill of lading number used for the interchange. Validations:
|
delivery_order_number optional |
Delivery order number used for the interchange. Validations:
|
completed_at optional |
The date and time at which interchange was completed, in ISO 8601 format (Eg 2023-04-13T14:30:00Z). Providing this value will update the interchange with a completed status. Validations:
|