Anchor | ||||
---|---|---|---|---|
|
Table of Contents | ||
---|---|---|
|
...
Panel | ||
---|---|---|
| ||
How will versioning be handled?CXT Software will support the latest version, plus one previous published version. Response and Request objects, in addition to URLs, may have properties added with new releases. Business logic within the endpoints may change, and/or permission hardening may be applicable to existing endpoints with new releases |
Requirements
- X Dispatch 21.0 or newer.
- TLS 1.2
- When calling the web services for CXT hosted customers (designated by a domain in the format <CXTID>0.cxtsoftware.net), the calling system must connect with TLS 1.2
- TLS 1.2 is not supported on Windows 2008 R2 or below. The calling system can run Windows 7, 8.1 or 2012 or newer, all of which support TLS 1.2
...
You can see which user type(s) are required for an endpoint under "Implementation Notes". For example, "Allowed requestors: [Inet user]" requires an authenticated internet user and "Allowed requestors: [Mobile Users]" requires an authenticated driver user.
To authenticate, select sending an authorization token or doing a basic authentication with the call.
...
Token based authentication uses one of the following endpoints to get the authorization token for the user:
Driver endpoint: /v1v2/Authentication/Drivers
Div Valid duration of an authentication token: 30 days
Note title X Dispatch User Note "Allow web access" must be enabled on the driver record in the X Dispatch application. See Drivers - New / Edit Driver.
Internet User endpoint: /v1v2/Authentication/InetUser
Div Valid duration of an authentication token: 20 minutes
Note title X Dispatch User Note "Allow Web Service API" must be enabled on the internet user record in the X Dispatch application. See Internet Users - New / Edit Internet User.
Human Resources endpoint: /v1v2/Authentication/Worker
Div Valid duration of an authentication token: 30 days
Note X Dispatch User endpoint: /v1v2/Authentication/XdUser
Div Valid duration of an authentication token: 60 minutes
...
Paste code macro | ||
---|---|---|
| ||
curl -X POST --header "Content-Type: application/json" --header "Accept: application/json" -d "{ \"driverId\": 123, \"password\": \"password\", }" "https://XXXX0.cxtsoftware.net/CxtWebService/CXTWCF.svc/v1v2/Authentication/Drivers" |
Including Tokens in Subsequent Requests
...
Paste code macro | ||
---|---|---|
| ||
curl -X GET --header "Accept: application/json" --header "Authorization: Token b1661ab49e5d42139b99a4a0ee741f0a" "https://XXXX0.cxtsoftware.net/CxtWebService/CXTWCF.svc/v1v2/Orders/9876" |
Basic Authentication
...
To get a list of available order types, use the /v1v2/Orders/RatesWithTimeWindows endpoint.
...
How to Create an Order
You can use the /v1v2/Orders endpoint to create new on demand order in X Dispatch.
...
How to Create a Route Stop
You can use the /v2/RouteStops endpoint to create new route stops in X Dispatch.
Endpoint URL: https://XXXX0.cxtsoftware.net/CxtWebService/CXTWCF.svc/api-docs/index.html?url=/CxtWebService/CXTWCF.svc/v2/swagger.json#!/Route_Stops/CxtSoftware_MiddleTier_WebService_CXTWCF_PostRouteStopV2
Section: Route Stops
Endpoint: /v2/RouteStops
Implementation Notes: Allowed requestors: [XD User]
...
Section: Work Orders
Endpoint: /v1v2/WorkOrders/Signatures
Implementation Notes: Allowed requestors: [Mobile User]
...
Parameter | Description | Parameter Type | Data Type |
---|---|---|---|
onDemandOrderId | The ID of the on demand order to be updated | path | string |
Troubleshooting
...