Skip to content

M2X APIS (1.0.0)

M2X APIs

Download OpenAPI description
Overview
License
All Rights Reserved
Languages
Servers
Mock server
https://developer.m2x.app/_mock/apis/publicapi/openapi/
https://developer.m2x.app/apis/v0/
NZ Production server (uses live data)
https://m2x.app/apis/v0/
US Production server (uses live data)
https://us.m2x.app/apis/v0/
AUS Production server (uses live data)
https://au.m2x.app/apis/v0/
Sandbox server
https://staging.m2x.app/apis/v0/

Analytics

Analytics data

Operations

Billing Groups

Invoiceable unit used by the system

Operations

Bookings

Bookings information

Operations

Carrier Bookings

Corporate bookings received by carriers

Operations

Carrier Large Contracts

Carrier large contracts

Operations

Carrier Orders

Carrier orders

Operations

Corporate Planning

Corporate Planning supplies and demands

Operations

Customer Bookings

Customer bookings on carriers

Operations

Customers

Customers used for invoices

Operations

Drivers

Drivers information

Operations

Fuel

Fuel deliveries management

Operations

Fulfilment Requests

Fulfilment request on carriers

OperationsWebhooks

Create new fulfilment request

Request

Security
M2X_auth_application
Bodyapplication/jsonrequired

Update for the fulfilment request

fulfilmentRequestobject(FulfilmentRequestRequest)
mappingRequestsobject(FulfilmentRequestMappingRequest)
curl -i -X POST \
  https://developer.m2x.app/_mock/apis/publicapi/openapi/fulfilmentRequests \
  -H 'Authorization: Bearer <YOUR_TOKEN_HERE>' \
  -H 'Content-Type: application/json' \
  -d '{
    "fulfilmentRequest": {
      "externalReference": "string",
      "externalNote": "string",
      "internalNote": "string",
      "backOrder": true,
      "urgent": true,
      "labels": [
        "string"
      ],
      "noPayment": false,
      "noPrice": false,
      "requestedQuantity": 0,
      "massKgPerUnit": 0,
      "spatialRequirementPerUnit": 0,
      "fromDateAndTimeConstraint": {
        "date": "2019-08-24",
        "timezone": "Pacific/Auckland",
        "timeConstraint": {}
      },
      "fromTimeWindows": [
        {
          "start": 0,
          "end": 0
        }
      ],
      "fromContactDetails": {
        "email": "string",
        "phone": "string",
        "name": "string"
      },
      "toContactDetails": {
        "email": "string",
        "phone": "string",
        "name": "string"
      },
      "toDateAndTimeConstraint": {
        "date": "2019-08-24",
        "timezone": "Pacific/Auckland",
        "timeConstraint": {}
      },
      "toTimeWindows": [
        {
          "start": 0,
          "end": 0
        }
      ],
      "properties": null,
      "metadata": null
    },
    "mappingRequests": {
      "carrier": {
        "carrierExternalId": "string"
      },
      "content": null,
      "product": {
        "productCode": null,
        "productCodeExternalId": null,
        "productDescription": null
      },
      "fromLocation": {
        "locationId": null,
        "addressText": null,
        "locationExternalId": null,
        "locationName": null,
        "latitude": 0,
        "longitude": 0,
        "saveIfUnknown": false,
        "locationNameResolutionEnabled": false,
        "useDefaultParentGroup": false,
        "parentGroupExternalId": null,
        "parentGroupName": null,
        "saveGroupIfUnknown": false
      },
      "fromLocationGroup": {
        "groupId": null,
        "externalId": null,
        "usePrimaryLocation": false,
        "subLocationExternalId": null
      },
      "toLocation": {
        "locationId": null,
        "addressText": null,
        "locationExternalId": null,
        "locationName": null,
        "latitude": 0,
        "longitude": 0,
        "saveIfUnknown": false,
        "locationNameResolutionEnabled": false,
        "useDefaultParentGroup": false,
        "parentGroupExternalId": null,
        "parentGroupName": null,
        "saveGroupIfUnknown": false
      },
      "toLocationGroup": {
        "groupId": null,
        "externalId": null,
        "usePrimaryLocation": false,
        "subLocationExternalId": null
      }
    }
  }'

Responses

Successful Operation

Bodyapplication/json
successboolean
Example: true
Response
application/json
{ "success": true }

Find fulfilment request by ID

Request

Security
M2X_auth_application
Path
fulfilmentRequestIdstringrequired

The fulfilment request Id

curl -i -X GET \
  'https://developer.m2x.app/_mock/apis/publicapi/openapi/fulfilmentRequests/{fulfilmentRequestId}' \
  -H 'Authorization: Bearer <YOUR_TOKEN_HERE>'

Responses

Successful operation

Bodyapplication/json
idstring
externalReferencestring
externalNotestring
internalNotestring
remainerCanceledboolean

Whether the remaining items are not fulfilled

labelsArray of strings

Extra label for picking

noPaymentboolean

Whether upon acceptance the carrier shall get a payment or not (e.g. freight forward)

Default false
noPriceboolean

Whether the booking is free of charge, no offer generated

Default false
carrierIdstring

The M2X carrier id for this booking

carrierExternalIdstring

External carrier id for this carrier

carrierNamestring

Carrier name for this job

corporateIdstring

The M2X corporate id for this booking

corporateNamestring

Corporate name for this job

backOrderboolean
urgentboolean
updatedstring(date-time)
requestedQuantitynumber

The product quantity

Default 0
quantitynumber

The product quantity

Default 0
productSpatialRequirementnumber or null

Optional override for the volume

Default null
productSpatialRequirementPerUnitnumber or null

Optional override for the volume per unit

Default null
productMassKgnumber or null

Optional total weight override for the booking

Default null
productMassKgPerUnitnumber or null

Optional total weight override for the booking per unit

Default null
transportRequirementsIdstring

M2X internal tracking id for the product type

productCodestring or null

M2X internal tracking id for the product code used

Default null
productCodeNamestring or null

M2X name for the product code used

Default null
productCodeExternalIdstring or null

External Id for product tracking

Default null
contentobject or null(ContentFulfilled)

Specific information about the content of the booking

propertiesobject or null(CustomProperties)

A key value store containing bespoke properties usable for pricing and optimisation

metadataobject or null(Metadata)

Opaque passenger data

fromLocationobject(CorporateLocation)
fromDateAndTimeConstraintobject(DateAndTimeConstraint)
fromTimeWindowsArray of objects(TimeWindows)
fromLocationGroupobject(LocationGroup)
fromContactDetailsobject(ContactDetails)
toLocationobject(CorporateLocation)
toDateAndTimeConstraintobject(DateAndTimeConstraint)
toTimeWindowsArray of objects(TimeWindows)
toLocationGroupobject(LocationGroup)
toContactDetailsobject(ContactDetails)
fulfilmentsArray of objects(Fulfilment)

The list of fulfilment associated with the fulfilmentRequest

Response
application/json
{ "id": "string", "externalReference": "string", "externalNote": "string", "internalNote": "string", "remainerCanceled": true, "labels": [ "string" ], "noPayment": false, "noPrice": false, "carrierId": "string", "carrierExternalId": "string", "carrierName": "string", "corporateId": "string", "corporateName": "string", "backOrder": true, "urgent": true, "updated": "2019-08-24T14:15:22Z", "requestedQuantity": 0, "quantity": 0, "productSpatialRequirement": null, "productSpatialRequirementPerUnit": null, "productMassKg": null, "productMassKgPerUnit": null, "transportRequirementsId": "string", "productCode": null, "productCodeName": null, "productCodeExternalId": null, "content": null, "properties": null, "metadata": null, "fromLocation": { "addressText": "string", "latitude": 0, "longitude": 0, "locationName": "string", "locationId": "string", "locationOwnerId": "string", "locationVersion": "string", "externalId": "string", "timezone": "Pacific/Auckland", "properties": null }, "fromDateAndTimeConstraint": { "date": "2019-08-24", "timezone": "Pacific/Auckland", "timeConstraint": {} }, "fromTimeWindows": [ { … } ], "fromLocationGroup": { "groupId": "string", "code": "C123", "externalId": "asd-asd-asd", "name": "string" }, "fromContactDetails": { "email": "string", "phone": "string", "name": "string" }, "toLocation": { "addressText": "string", "latitude": 0, "longitude": 0, "locationName": "string", "locationId": "string", "locationOwnerId": "string", "locationVersion": "string", "externalId": "string", "timezone": "Pacific/Auckland", "properties": null }, "toDateAndTimeConstraint": { "date": "2019-08-24", "timezone": "Pacific/Auckland", "timeConstraint": {} }, "toTimeWindows": [ { … } ], "toLocationGroup": { "groupId": "string", "code": "C123", "externalId": "asd-asd-asd", "name": "string" }, "toContactDetails": { "email": "string", "phone": "string", "name": "string" }, "fulfilments": [ { … } ] }

Update/create fulfilment request by ID

Request

Security
M2X_auth_application
Path
fulfilmentRequestIdstringrequired

The fulfilment request Id

Bodyapplication/jsonrequired

Update for the fulfilment request

fulfilmentRequestobject(FulfilmentRequestRequest)
mappingRequestsobject(FulfilmentRequestMappingRequest)
curl -i -X PUT \
  'https://developer.m2x.app/_mock/apis/publicapi/openapi/fulfilmentRequests/{fulfilmentRequestId}' \
  -H 'Authorization: Bearer <YOUR_TOKEN_HERE>' \
  -H 'Content-Type: application/json' \
  -d '{
    "fulfilmentRequest": {
      "externalReference": "string",
      "externalNote": "string",
      "internalNote": "string",
      "backOrder": true,
      "urgent": true,
      "labels": [
        "string"
      ],
      "noPayment": false,
      "noPrice": false,
      "requestedQuantity": 0,
      "massKgPerUnit": 0,
      "spatialRequirementPerUnit": 0,
      "fromDateAndTimeConstraint": {
        "date": "2019-08-24",
        "timezone": "Pacific/Auckland",
        "timeConstraint": {}
      },
      "fromTimeWindows": [
        {
          "start": 0,
          "end": 0
        }
      ],
      "fromContactDetails": {
        "email": "string",
        "phone": "string",
        "name": "string"
      },
      "toContactDetails": {
        "email": "string",
        "phone": "string",
        "name": "string"
      },
      "toDateAndTimeConstraint": {
        "date": "2019-08-24",
        "timezone": "Pacific/Auckland",
        "timeConstraint": {}
      },
      "toTimeWindows": [
        {
          "start": 0,
          "end": 0
        }
      ],
      "properties": null,
      "metadata": null
    },
    "mappingRequests": {
      "carrier": {
        "carrierExternalId": "string"
      },
      "content": null,
      "product": {
        "productCode": null,
        "productCodeExternalId": null,
        "productDescription": null
      },
      "fromLocation": {
        "locationId": null,
        "addressText": null,
        "locationExternalId": null,
        "locationName": null,
        "latitude": 0,
        "longitude": 0,
        "saveIfUnknown": false,
        "locationNameResolutionEnabled": false,
        "useDefaultParentGroup": false,
        "parentGroupExternalId": null,
        "parentGroupName": null,
        "saveGroupIfUnknown": false
      },
      "fromLocationGroup": {
        "groupId": null,
        "externalId": null,
        "usePrimaryLocation": false,
        "subLocationExternalId": null
      },
      "toLocation": {
        "locationId": null,
        "addressText": null,
        "locationExternalId": null,
        "locationName": null,
        "latitude": 0,
        "longitude": 0,
        "saveIfUnknown": false,
        "locationNameResolutionEnabled": false,
        "useDefaultParentGroup": false,
        "parentGroupExternalId": null,
        "parentGroupName": null,
        "saveGroupIfUnknown": false
      },
      "toLocationGroup": {
        "groupId": null,
        "externalId": null,
        "usePrimaryLocation": false,
        "subLocationExternalId": null
      }
    }
  }'

Responses

Successful Operation

Bodyapplication/json
successboolean
Example: true
Response
application/json
{ "success": true }

Find site fulfilment request by fulfilment request ID

Request

Security
M2X_auth_application
Path
fulfilmentRequestIdstringrequired

The fulfilment request Id

curl -i -X GET \
  'https://developer.m2x.app/_mock/apis/publicapi/openapi/fulfilmentRequests/{fulfilmentRequestId}/siteFulfilments' \
  -H 'Authorization: Bearer <YOUR_TOKEN_HERE>'

Responses

Successful operation

Bodyapplication/jsonArray [
fulfilmentRequestobject(SiteFulfilmentRequest)
siteobject
statusstring
updatedstring(date-time)
extrasobject
assignmentobject
]
Response
application/json
[ { "fulfilmentRequest": { … }, "site": { … }, "status": "string", "updated": "2019-08-24T14:15:22Z", "extras": { … }, "assignment": { … } } ]

Site fulfilment webhookWebhook

Request

webhook type: SITE_FULFILMENT

Bodyapplication/jsonrequired
fulfilmentRequestobject(SiteFulfilmentRequest)
siteobject
statusstring
updatedstring(date-time)
extrasobject
assignmentobject
application/json
{ "fulfilmentRequest": { "id": "string", "externalReference": "string", "externalNote": "string", "internalNote": "string", "remainerCanceled": true, "labels": [ … ], "noPayment": false, "noPrice": false, "carrierId": "string", "carrierExternalId": "string", "carrierName": "string", "corporateId": "string", "corporateName": "string", "backOrder": true, "urgent": true, "updated": "2019-08-24T14:15:22Z", "requestedQuantity": 0, "quantity": 0, "productSpatialRequirement": null, "productSpatialRequirementPerUnit": null, "productMassKg": null, "productMassKgPerUnit": null, "transportRequirementsId": "string", "productCode": null, "productCodeName": null, "productCodeExternalId": null, "content": null, "properties": null, "metadata": null, "fromLocation": { … }, "fromDateAndTimeConstraint": { … }, "fromTimeWindows": [ … ], "fromLocationGroup": { … }, "fromContactDetails": { … }, "toLocation": { … }, "toDateAndTimeConstraint": { … }, "toTimeWindows": [ … ], "toLocationGroup": { … }, "toContactDetails": { … }, "bookingId": "string", "acted": false, "done": false, "type": "cancel", "offerStatus": "None", "offerPriceFaf": null, "offerPriceTransport": null, "bookingPriceFaf": null, "bookingPriceTransport": null, "siteStatus": "pending", "siteOnHoldReason": null, "fulfilmentId": "string", "fulfilmentRequestId": "string" }, "site": { "description": "string", "name": "string", "siteId": "string", "locationGroupId": "string", "locationGroupName": "string" }, "status": "string", "updated": "2019-08-24T14:15:22Z", "extras": { "backOrder": true, "urgent": true, "bookingGroup": "string", "labels": [ … ] }, "assignment": { "name": "string", "operatorId": "string", "code": "string" } }

Responses

Webhook received successfully

Fulfilment request webhookWebhook

Request

webhook type: FULFILMENT_REQUEST

Bodyapplication/jsonrequired
idstring
externalReferencestring
externalNotestring
internalNotestring
remainerCanceledboolean

Whether the remaining items are not fulfilled

labelsArray of strings

Extra label for picking

noPaymentboolean

Whether upon acceptance the carrier shall get a payment or not (e.g. freight forward)

Default false
noPriceboolean

Whether the booking is free of charge, no offer generated

Default false
carrierIdstring

The M2X carrier id for this booking

carrierExternalIdstring

External carrier id for this carrier

carrierNamestring

Carrier name for this job

corporateIdstring

The M2X corporate id for this booking

corporateNamestring

Corporate name for this job

backOrderboolean
urgentboolean
updatedstring(date-time)
requestedQuantitynumber

The product quantity

Default 0
quantitynumber

The product quantity

Default 0
productSpatialRequirementnumber or null

Optional override for the volume

Default null
productSpatialRequirementPerUnitnumber or null

Optional override for the volume per unit

Default null
productMassKgnumber or null

Optional total weight override for the booking

Default null
productMassKgPerUnitnumber or null

Optional total weight override for the booking per unit

Default null
transportRequirementsIdstring

M2X internal tracking id for the product type

productCodestring or null

M2X internal tracking id for the product code used

Default null
productCodeNamestring or null

M2X name for the product code used

Default null
productCodeExternalIdstring or null

External Id for product tracking

Default null
contentobject or null(ContentFulfilled)

Specific information about the content of the booking

propertiesobject or null(CustomProperties)

A key value store containing bespoke properties usable for pricing and optimisation

metadataobject or null(Metadata)

Opaque passenger data

fromLocationobject(CorporateLocation)
fromDateAndTimeConstraintobject(DateAndTimeConstraint)
fromTimeWindowsArray of objects(TimeWindows)
fromLocationGroupobject(LocationGroup)
fromContactDetailsobject(ContactDetails)
toLocationobject(CorporateLocation)
toDateAndTimeConstraintobject(DateAndTimeConstraint)
toTimeWindowsArray of objects(TimeWindows)
toLocationGroupobject(LocationGroup)
toContactDetailsobject(ContactDetails)
fulfilmentsArray of objects(Fulfilment)

The list of fulfilment associated with the fulfilmentRequest

application/json
{ "id": "string", "externalReference": "string", "externalNote": "string", "internalNote": "string", "remainerCanceled": true, "labels": [ "string" ], "noPayment": false, "noPrice": false, "carrierId": "string", "carrierExternalId": "string", "carrierName": "string", "corporateId": "string", "corporateName": "string", "backOrder": true, "urgent": true, "updated": "2019-08-24T14:15:22Z", "requestedQuantity": 0, "quantity": 0, "productSpatialRequirement": null, "productSpatialRequirementPerUnit": null, "productMassKg": null, "productMassKgPerUnit": null, "transportRequirementsId": "string", "productCode": null, "productCodeName": null, "productCodeExternalId": null, "content": null, "properties": null, "metadata": null, "fromLocation": { "addressText": "string", "latitude": 0, "longitude": 0, "locationName": "string", "locationId": "string", "locationOwnerId": "string", "locationVersion": "string", "externalId": "string", "timezone": "Pacific/Auckland", "properties": null }, "fromDateAndTimeConstraint": { "date": "2019-08-24", "timezone": "Pacific/Auckland", "timeConstraint": {} }, "fromTimeWindows": [ { … } ], "fromLocationGroup": { "groupId": "string", "code": "C123", "externalId": "asd-asd-asd", "name": "string" }, "fromContactDetails": { "email": "string", "phone": "string", "name": "string" }, "toLocation": { "addressText": "string", "latitude": 0, "longitude": 0, "locationName": "string", "locationId": "string", "locationOwnerId": "string", "locationVersion": "string", "externalId": "string", "timezone": "Pacific/Auckland", "properties": null }, "toDateAndTimeConstraint": { "date": "2019-08-24", "timezone": "Pacific/Auckland", "timeConstraint": {} }, "toTimeWindows": [ { … } ], "toLocationGroup": { "groupId": "string", "code": "C123", "externalId": "asd-asd-asd", "name": "string" }, "toContactDetails": { "email": "string", "phone": "string", "name": "string" }, "fulfilments": [ { … } ] }

Responses

Webhook received successfully

General Consignments

General consignments

Operations

ISO containers

ISO containers information

Operations

Jobs

Vehicle units of work

OperationsWebhooks

Locations

Locations information

Operations

Master Bookings

Master bookings

OperationsWebhooks

Offers

Corporate monetary offers to carriers

OperationsWebhooks

Products

Products used by the system

Operations

Runs

Runs management

Operations

Subcontractors

Subcontractors information

Operations

Tractor Unit

Tractor units information

Operations

Trailer

Trailers information

Operations

Transaction

Transaction management

Operations

Vehicle

Vehicles information

Operations

Vehicle Execution Statements

Unit of execution for trucks

OperationsWebhooks

Consignments

Webhooks