1. Bookings
  • Introduction
  • Getting Started
  • Authentication
  • Error Handling
  • Contact Support
  • Modaltrans API
    • Get Auth Token
      • Get Bearer Token
    • Accounting
      • Invoices
        • Retrieve an Invoice
        • List all Invoices
    • Customs
      • NCTS Declarations
        • List all NCTS Declarations
        • Retrieve an NCTS Declaration
        • Create an NCTS Declaration with XML Data
        • Create an Ens Declaration from JSON
        • Update an NCTS Declaration
        • Download an NCTS Declaration
        • List Timelines of NCTS Declaration
        • List Messages of NCTS Decalaration
      • Customs Declarations
        • List all Customs Declarations
        • Retrieve a Custom Declaration
        • Create a Customs Declaration
        • Update a Custom Declaration
        • Delete a Custom Declaration
        • Retrieve a Declaration History
        • Retrieve an MRN Status of Declaration
      • Declaration Requests
        • List all Declaration Orders
        • Retrieve a Declaration Request
        • Create a Declaration Request
        • Update a Declaration Request
        • Delete a Declaration Request
    • Logistics
      • Bookings
        • Retrieve a Booking
          GET
        • List all Bookings
          GET
        • Create a Booking
          POST
        • Update a Booking
          PATCH
      • Locations
        • List all Locations
        • Retrieve a Location
      • Positions
        • Update a Transport
      • Tracking
        • Available Shipping Lines
        • Retrieve a Tracking Data
        • Subscribe to Tracking
      • Shipments
        • Retrieve a Shipment
        • List All Shipments
        • Retrieve Financials of Shipment
        • List Contacts of the Shipment
        • Create a Shipment
        • Update a Shipment
    • Depot
      • Orders
        • Retrieve an Order
        • List all Orders
        • Create an Order
        • Update an Order
      • Products
        • Retrieve a Product
        • List all Products
        • Create a Product
        • Update a Product
        • List Product Stocks
      • Inventories
        • List all Inventories
    • Fleet Management
      • Drivers
        • Retrieve a Driver
        • Retrieve a Driver's Vehicle
        • List Driver Positions
        • Update a Driver
      • Vehicles
        • Retrieve a Vehicle
        • Update a Vehicle
      • Gps Service Controller
        • Create Gps Responses
      • Service Logs
        • List all Service Logs
        • Retrieve a Service Log
        • Create a Service Log
        • Delete a Service Log
        • Update a Service Log
      • Periodic Documents
        • Retrieve a Periodic Document
        • Update a Periodic Document
        • Create a Periodic Document
    • CRM
      • Companies
        • List all Companies
        • Retrieve a Company
        • Create a Company
        • Update a Company
        • Delete a Company
    • Timelines
      • Retrieve a Timeline
      • List Timelines
      • Create a Timeline
    • S3 Files
      • List all S3Files
      • Create an S3File
      • Delete an S3File
    • Notifications
      • List all Notifications
      • Update a Notification Status
    • User Details
      • List User Details
      • Update User Details
  1. Bookings

Update a Booking

Developing
Testing Env
https://demo.modaltrans.com
Testing Env
https://demo.modaltrans.com
PATCH
/api/v1/bookings/{transaction_id}
Updates a booking's detail by transaction ID.

Request

Authorization
Provide your bearer token in the
Authorization
header when making requests to protected resources.
Example:
Authorization: Bearer ********************
Path Params
transaction_id
integer 
required
Transaction ID of booking.
Body Params application/json
booking
object 
required
trans_mode
enum<string> 
optional
Transportation Mode; The options are: road -> Road Transport, air -> Air Transport, sea -> Ocean Transport, courier -> Courier Ops
Allowed values:
roadairseacourier
load_type
enum<string> 
optional
FCL/FTL or LCL/FTL option; The options are: P -> LCL/LTL bookings, K -> FCL/FTL bookings
Allowed values:
PK
in_container
enum<string> 
optional
If the goods will be carried in a container or not; The options are: at_container -> has containers data (you need to send container details in the containers_attributes), out_of_container -> No container, you need to send package details in packages_attributes)
Allowed values:
at_containerout_of_container
total_pack
number 
optional
Total Pack
brut_wg
number 
optional
Total Weight
volume
number 
optional
Total Volume
price_wg
number 
optional
Chargeable Weight
operation_code
string 
optional
Specific Operation/Team code, you need to discuss with the account admin if you will work with different teams
company_no
string 
optional
Company account number
company_name
string  | null 
optional
Company name
company_taxno
string 
optional
Company tax no
company_country_id
string 
optional
Company country code (like GB, US, CH..)
sender_name
string 
optional
Consignor company name
sender_eori
string 
optional
Consignor company EORI or account no
load_place_type
enum<string> 
optional
Origin location type; The options are: air -> Airports, sea -> Seaports, port -> Seaports + Airports + Customs, company -> Company locations, other -> Manual address entry
Allowed values:
airseaportcompanyother
load_place_code
string 
optional
Origin place code: If the location type is airport or seaport, then you need to send the airport or seaport code. Like GBSOU, LHR...
load_place
string 
optional
Origin place address if the location type is "other", then you need to send address here
dep_zipcode
string 
optional
Origin place postcode if the location type is "other", then you need to send postcode here
load_state_name
string 
optional
Origin place state name if the location type is "other", then you need to send the state code here
load_coun
string 
optional
Origin place country code, Origin or departure country code, two digits code like GB, US, CN...
consignee_name
string 
optional
Consignee company name
consignee_eori
string 
optional
Consignee company EORI or account no
unload_place_type
enum<string> 
optional
Destination location type; The options are: air -> Airports, sea -> Seaports, port -> Seaports + Airports + Customs, company -> Company locations, other -> Manual address entry
Allowed values:
airseaportcompanyother
unload_place_code
string 
optional
Destination place code: If the location type is airport or seaport, then you need to send the airport or seaport code. Like GBSOU, LHR...
unload_place
string 
optional
Destination place address if the location type is "other", then you need to send address here
company_id
integer 
optional
Company ID
arv_zipcode
string 
optional
Destination place postcode if the location type is "other", then you need to send postcode here
unload_state_name
string 
optional
Destination place state code if the location type is "other", then you need to send state code here
unload_coun
string 
optional
Destination country code, Destination or arrival country code, two digits code like GB, US, CN...
incoterm
string 
optional
Incoterm
packages_attributes
array [object {8}] 
optional
containers_attributes
array [object {8}] 
optional
Example
{
    "booking": {
        "load_coun": "UK"
    }
}

Request samples

Shell
JavaScript
Java
Swift
Go
PHP
Python
HTTP
C
C#
Objective-C
Ruby
OCaml
Dart
R
Request Request Example
Shell
JavaScript
Java
Swift
curl --location --request PATCH 'https://demo.modaltrans.com/api/v1/bookings/' \
--header 'Content-Type: application/json' \
--data-raw '{
    "booking": {
        "load_coun": "UK"
    }
}'

Responses

🟢200Success
application/json
Body
alert
string 
required
Example
{
    "alert": "Booking has been updated succesfully"
}
🟠400Bad Request
🟠403Forbidden
🟠404Record Not Found
Modified at 2024-08-29 12:21:16
Previous
Create a Booking
Next
List all Locations
Built with