Skip to main content

Vehicle Last Active

Description

By calling this Rest end-point, it can be determined whether a vehicle is in service. Input the Vehicle ID(s) to retrieve the last active time of each vehicle. The API returns the DateTime (ISO format) when the vehicle(s) was last in service.

1. Endpoint for Data Retrieval

To access the API, use the Rest endpoint provided by the Fleet API team:

The endpoint accepts the following variables that need to be specified:

vehicles: comma-separated names of the vehicle(s) for which you want to retrieve data.

REST-ENDPOINT/last-active?vehicles=marinara,mayble

2. Authorization Token

To use the API, you need to generate an authorization token. The token should have the following scope set for Batch operations:

Scope: Scope to get authorization to this endpoint might vary with other endpoints.
All other token generation parameters remain the same as when requesting a Realtime token.

3. Data Age Limit

Please note that the information about each vehicle's last activity is retained for a week, after which the api would return the following message

vehicle hasn't been active in the past 7 days

4. Output Format

{
"marinara": "01-24-2024 23:00:26",
"mayble": "vehicle hasn't been active in the past 7 days"
}

If you have any questions or require further assistance, please don't hesitate to reach out to us. We are here to help you access and utilize MayMobility's fleet API effectively.