This site contains the documentation that is relevant to older WSO2 product versions and offerings.
For the latest WSO2 documentation, visit https://wso2.com/documentation/.
Working with Vehicles in Beetrack
Overview
The following operations allow you to work with vehicles. Click an operation name to see details on how to use it.
For a sample proxy service that illustrates how to work with vehicles, see Sample configuration.
Operation | Description |
---|---|
Creates a new vehicle. | |
getVehicle | Retrieves specific vehicle details by ID. |
listVehicles | Retrieves all vehicles. |
Operation details
This section provides further details on the operations related to vehicles.
Creating a new vehicle
The
operation creates a new vehicle.createVehicle
<beetrack.createVehicle> <identifier>{$ctx:identifier}</identifier> </beetrack.createVehicle>
Properties
The unique identifier of the vehicle.identifier:
Sample request
Following is a sample REST/JSON request that can be handled by the createV
ehicle
operation.
{ "apiUrl": "http://app.beetrack.com", "accessToken": "2bad8257ad498897220c9fddfb657b9b08513619d8ef0576821d34bf31d2baa1", "identifier": "VEH004" }
Related Beetrack documentation
https://beetrack.com/apidoc/#api-Vehicle-CreateVehicle
Retrieving specific vehicle details by ID
The
operation retrieves specific vehicle details by ID.getVehicle
<beetrack.getVehicle> <vehicleId>{$ctx:vehicleId}</vehicleId> </beetrack.getVehicle>
Properties
The unique identifier of the vehicle.vehicleId:
Sample request
Following is a sample REST/JSON request that can be handled by the getVehicle
operation.
{ "apiUrl": "http://app.beetrack.com", "accessToken": "2bad8257ad498897220c9fddfb657b9b08513619d8ef0576821d34bf31d2baa1", "vehicleId": "VEH002" }
Related Beetrack documentation
https://beetrack.com/apidoc/#api-Vehicle-ShowVehicle
Retrieving all vehicles
The
operation retrieves all vehicles.listVehicles
<beetrack.listVehicles> </beetrack.listVehicles>
Sample request
Following is a sample REST/JSON request that can be handled by the listVehicles
operation.
{ "apiUrl": "http://app.beetrack.com", "accessToken": "2bad8257ad498897220c9fddfb657b9b08513619d8ef0576821d34bf31d2baa1" }
Related Beetrack documentation
https://beetrack.com/apidoc/#api-Vehicle-IndexVehicles
Sample configuration
Following is a sample proxy service that illustrates how to connect to Billomat with the init
operation and use the createVehicle
operation. The sample request for this proxy can be found in the createVehicle sample request.
<?xml version="1.0" encoding="UTF-8"?> <proxy name="beetrack_createVehicle" startOnLoad="true" statistics="disable" trace="disable" transports="https,http" xmlns="http://ws.apache.org/ns/synapse"> <target> <inSequence onError="faultHandlerSeq"> <property name="apiUrl" expression="json-eval($.apiUrl)"/> <property name="accessToken" expression="json-eval($.accessToken)"/> <property name="identifier" expression="json-eval($.identifier)"/> <beetrack.init> <apiUrl>{$ctx:apiUrl}</apiUrl> <accessToken>{$ctx:accessToken}</accessToken> </beetrack.init> <beetrack.createVehicle> <identifier>{$ctx:identifier}</identifier> </beetrack.createVehicle> <respond/> </inSequence> <outSequence> <send/> </outSequence> </target> <description/> </proxy>