POST api/RegisterBatch

This method is used for registering a list of Ocean Carrier Bill of Lading numbers (CBLs). This method is required to be called for the GetTracking method to return tracking feeds.

Request Information


URI Parameters

None.

Body Parameters

RegisterBatchRequest
NameDescriptionTypeAdditional information
items

List of Register Item Requests

Collection of RegisterItemRequest

None.

apikey

Unique Value assigned by an administrator during account setup.

string

None.

username

Username Assigned by an administrator during account setup

string

None.

password

Password Assigned by an administrator during account setup

string

None.

ctoken

Optional Client Token

string

None.

Request Formats

application/json, text/json

Sample:
{
  "items": [
    {
      "cbl": "EGLV0833300168439",
      "scac": null,
      "cnt": null,
      "load": null,
      "refs": [
        "PO00001",
        "PO00002"
      ],
      "enablecallback": true,
      "callbackauthkey": null,
      "callbackurl": "http://abc.com/aescallback/",
      "customattributes": null
    },
    {
      "cbl": "ZBMURUI743564",
      "scac": null,
      "cnt": null,
      "load": null,
      "refs": null,
      "enablecallback": false,
      "callbackauthkey": null,
      "callbackurl": null,
      "customattributes": null
    }
  ],
  "apikey": "8881BA2F-5FE2-4CF1-D99E-5963J9192806",
  "username": "demoapi",
  "password": "dpassword",
  "ctoken": null
}

text/xml, application/xml

Sample:
<RegisterBatchRequest>
  <apikey>8881BA2F-5FE2-4CF1-D99E-5963J9192806</apikey>
  <ctoken />
  <password>dpassword</password>
  <username>demoapi</username>
  <items>
    <RegisterItemRequest>
      <callbackauthkey />
      <callbackurl>http://abc.com/aescallback/</callbackurl>
      <cbl>EGLV0833300168439</cbl>
      <cnt />
      <customattributes />
      <enablecallback>true</enablecallback>
      <load />
      <refs>
        <string xmlns="http://schemas.microsoft.com/2003/10/Serialization/Arrays">PO00001</string>
        <string xmlns="http://schemas.microsoft.com/2003/10/Serialization/Arrays">PO00002</string>
      </refs>
      <scac />
    </RegisterItemRequest>
    <RegisterItemRequest>
      <callbackauthkey />
      <callbackurl />
      <cbl>ZBMURUI743564</cbl>
      <cnt />
      <customattributes />
      <enablecallback>false</enablecallback>
      <load />
      <refs />
      <scac />
    </RegisterItemRequest>
  </items>
</RegisterBatchRequest>

application/x-www-form-urlencoded

Sample:
Items=System.Collections.Generic.List%601%5BExternalRestService.Models.RegisterItemRequest%5D&ApiKey=8881BA2F-5FE2-4CF1-D99E-5963J9192806&Username=demoapi&Password=dpassword

Response Information


Resource Description

RegisterBatchResponse
NameDescriptionTypeAdditional information
items

List of responses to request items

Collection of RegisterItemResponse

None.

ack

A flag indicating success or failure of the web service response back to the client. Default is success.

AcknowledgeType

None.

exceptions

Message back to client. Mostly used when a web service failure occurs.

Collection of ResponseExceptionDto

None.

ctoken

Optional Client Token

string

None.

Response Formats

application/json, text/json

Sample:
{
  "items": [
    {
      "ack": 1,
      "updated_cbl": null,
      "exceptions": null,
      "cbl": "EGLV0833300168439",
      "scac": null,
      "cnt": null,
      "load": null,
      "refs": [
        "PO00001",
        "PO00002"
      ],
      "enablecallback": true,
      "callbackauthkey": null,
      "callbackurl": "http://abc.com/aescallback/",
      "customattributes": null
    },
    {
      "ack": 0,
      "updated_cbl": null,
      "exceptions": [
        {
          "errorcode": "BOL-4",
          "msg": "BOL MVOCC SCAC IS INCORRECT.",
          "validationcodes": null,
          "suggestion": null
        }
      ],
      "cbl": "ZBMURUI743564",
      "scac": null,
      "cnt": null,
      "load": null,
      "refs": null,
      "enablecallback": false,
      "callbackauthkey": null,
      "callbackurl": null,
      "customattributes": null
    }
  ],
  "ack": 1,
  "exceptions": null,
  "ctoken": null
}

text/xml, application/xml

Sample:
<RegisterBatchResponse>
  <ack>Success</ack>
  <ctoken />
  <exceptions />
  <items>
    <RegisterItemResponse>
      <callbackauthkey />
      <callbackurl>http://abc.com/aescallback/</callbackurl>
      <cbl>EGLV0833300168439</cbl>
      <cnt />
      <customattributes />
      <enablecallback>true</enablecallback>
      <load />
      <refs>
        <string xmlns="http://schemas.microsoft.com/2003/10/Serialization/Arrays">PO00001</string>
        <string xmlns="http://schemas.microsoft.com/2003/10/Serialization/Arrays">PO00002</string>
      </refs>
      <scac />
      <ack>Valid</ack>
      <exceptions />
      <updated_cbl />
    </RegisterItemResponse>
    <RegisterItemResponse>
      <callbackauthkey />
      <callbackurl />
      <cbl>ZBMURUI743564</cbl>
      <cnt />
      <customattributes />
      <enablecallback>false</enablecallback>
      <load />
      <refs />
      <scac />
      <ack>Invalid</ack>
      <exceptions>
        <ItemExceptionDto>
          <errorcode>BOL-4</errorcode>
          <msg>BOL MVOCC SCAC IS INCORRECT.</msg>
          <suggestion />
          <validationcodes />
        </ItemExceptionDto>
      </exceptions>
      <updated_cbl />
    </RegisterItemResponse>
  </items>
</RegisterBatchResponse>