• Register

Booking API Documentation

Welcome to the My JAS Connect Booking API. This service allows your business applications (such as an ERP, TMS, or e-commerce platform) to communicate directly with our core booking systems.

By integrating with this REST-based API, you can automate your entire booking creation process, enabling your systems to directly register new bookings with JAS in an easy and automated way. This guide provides a complete overview of how to use the Booking API services to get started.

Key Capabilities & Features

Our Booking API is a powerful service designed for simplicity, security, and accuracy.

  • Create Bookings: The API's primary function is to create new bookings in the JAS system. Bookings are easily generated by providing basic information about the shipper, consignee, and shipment details.
  • Flexible Data Formats: We support both major data formats for your convenience. You can submit your booking requests in either application/json or application/xml.
  • Broad Transport Mode Support: The API can be used to book freight across our global network, including:
    • Air Freight (Loose and ULD)
    • Sea Freight (FCL and LCL)
    • Road Freight (FTL and LCL/LTL)
    • Rail Freight (FCL and LCL)
    • Courier
  • Secure & Encrypted: All API communication is secured. We use the OAuth 2.0 protocol for authentication, and all web calls are made over HTTPS to ensure your data is always encrypted in transit.
  • Robust Error Handling: The API provides clear and accurate error handling. You will receive standard HTTP response codes (like 400 Bad Request or 401 Unauthorized) to help your team debug any issues with an integration request .

Getting Started: Authentication & Endpoints

All API requests must be securely authenticated before they can interact with the system. Accessing the API is a two-step process.

Step 1: Generate an Access Token

Before you can create a booking, you must request a bearer token using the OAuth 2.0 client_credentials grant type.

Step 2: Call the Booking API

Once you have your access token, you can call the CreateBooking endpoint. You must include the token and your unique API key in the headers of every request.

Understanding the API Flow

The process of creating a booking is straightforward.

1. Request Validation

When JAS receives your CreateBooking request, our system first performs a validation. This check ensures:

  • Your Authentication headers (Authorization and x-api-key) are valid.
  • Your Content-Type header matches the endpoint (e.g., application/json for the CreateBookingjson endpoint).
  • Your request payload is well-formed and includes all mandatory fields. A 400 Bad Request error will be returned if there are mismatches or other issues with the request .

2. Create Booking & Receive Confirmation

After a successful validation, JAS creates the booking in our system. The API will return a synchronous response in the same format you sent (JSON or XML), indicating the result:

  • On Success (Code 200 ): You will receive a response containing:
    • "Success": true
    • "JobNumber": "S508480248" (This is your new JAS Booking ID)
  • On Failure: You will receive a response with:
    • "Success": false
    • "Error": "Detailed error message..."
    • This can be due to business logic errors or unexpected server issues (e.g., 500 Internal Server Error ).

Core Data Structure

A booking request is built from several primary data collections. The full specification is available for download, but the key components are:

  • Details : The main information about the booking, including the mandatory ContainerMode and TransportModeCode , as well as ServiceLevelCode , GoodsDescription , and total weight/volume.
  • ClientAddress: Information about your organization (the "client") that is placing the booking.
  • ShippersAddress: The full address and contact details for the party sending the goods.
  • ConsigneeAddress: The full address and contact details for the final recipient of the goods. This section contains several mandatory fields, including Address1, City, CompanyName, CountryCode, and PostCode.
  • DateCollection : Contains critical dates for the booking, including the mandatory PickupRequiredBy date and time.
  • OrderNumberCollection : A list where you can provide your internal order references.
  • AdditionalReferenceCollection : Allows you to add other key business identifiers, such as a Purchase Order Number (Code: PO) or Client Reference (Code: CRF) .
  • PackingLineCollection: A detailed, item-level list of the goods being shipped. You can include unlimited packing lines. Each line must include:
    • ItemNo (Line Number)
    • GoodsDescription
    • PackQty (Package Quantity)
    • PackTypeCode (e.g., PKG, CTN, PLT)
    • Weight
    • WeightUnitCode (e.g., KG, LB)
    • ContainerCollection : For sea freight, this collection specifies the ContainerType (e.g., 20GP, 40HC) and Quantity .