### GET /websites/developer_gomotive_reference Source: https://developer.gomotive.com/reference/fetch-the-documents-for-all-the-drivers Fetches a list of all available driver's documents and their details. Requires start and end dates to narrow down the search. ```APIDOC ## GET /websites/developer_gomotive_reference ### Description Use this API to fetch a list of all the available driver's documents, and its details such as the document ID, the category, reference number, fields of the document, date, and others. You must provide the start date and the end date for the document to view the records. ### Method GET ### Endpoint /websites/developer_gomotive_reference #### Query Parameters - **startDate** (Date) - Required - The start date for filtering documents. - **endDate** (Date) - Required - The end date for filtering documents. ### Response #### Success Response (200) - **documents** (Array of Objects) - A list of documents associated with a particular category or reference number. - **id** (Integer) - The unique identifier for the document. - **category** (String) - The category of the document, e.g., "fuel receipt". - **public_url** (String) - The URL to access the document. - **ref_no** (String) - The reference number associated with the document. - **notes** (String) - Notes associated with the document. - **doc_date** (Date) - The date the document was created. - **doc_fields** (Array of Objects) - Custom fields associated with the document (nullable). - **doc_time** (DateTime) - The date and time when a user completed or filled out a document. - **uploader** (Object) - Information about the uploader. - **id** (Integer) - The unique identifier for the uploader. - **first_name** (String) - The first name of the uploader. - **last_name** (String) - The last name of the uploader. - **email** (String) - The email of the uploader. - **role** (String) - The role of the uploader, e.g., "dispatcher". - **deactivated_at** (DateTime) - The timestamp when the uploader was deactivated (nullable). - **driver_company_id** (Integer) - The company ID of the uploader if they are a driver (nullable). - **created_at** (DateTime) - The timestamp when the document was created. - **updated_at** (DateTime) - The timestamp when the document was last updated. #### Response Example { "documents": [ { "id": 123, "category": "fuel receipt", "public_url": "https://example.com/docs/123.pdf", "ref_no": "REF456", "notes": "Some notes about the document.", "doc_date": "2023-10-27", "doc_fields": [ { "key": "amount", "value": "100.50" } ], "doc_time": "2023-10-27T10:30:00Z", "uploader": { "id": 789, "first_name": "John", "last_name": "Doe", "email": "john.doe@example.com", "role": "dispatcher", "deactivated_at": null, "driver_company_id": 101 }, "created_at": "2023-10-27T11:00:00Z", "updated_at": "2023-10-27T11:05:00Z" } ] } ``` -------------------------------- ### Example Endpoint Documentation Source: https://developer.gomotive.com/reference/fetch-a-list-of-all-the-company-dispatches This snippet demonstrates the structure of documentation for a hypothetical API endpoint, including request and response examples. ```APIDOC ## GET /example/endpoint ### Description This endpoint retrieves example data based on provided parameters. ### Method GET ### Endpoint /example/endpoint #### Query Parameters - **id** (string) - Required - The unique identifier for the data to retrieve. - **limit** (integer) - Optional - The maximum number of results to return. ### Request Example (No request body for GET requests) ### Response #### Success Response (200) - **data** (object) - Contains the retrieved data. - **name** (string) - The name of the item. - **value** (integer) - The value associated with the item. - **pagination** (object) - Information about pagination. - **per_page** (integer) - Number of items per page. - **page_no** (integer) - The current page number. - **total** (integer) - The total number of items available. #### Response Example ```json { "data": { "name": "Example Item", "value": 123, "address": { "city": "San Francisco", "state": "CA", "zip": "94104", "country": "US", "arrive_radius": 200, "depart_radius": 200, "phone": "(650) 238-9293" } }, "pagination": { "per_page": 25, "page_no": 1, "total": 2 } } ``` ``` -------------------------------- ### Create New User API Response Example Source: https://developer.gomotive.com/reference/create-a-new-user This example demonstrates the JSON structure of a successful response when creating a new user. It includes comprehensive details about the user's profile, company associations, and system settings. Ensure all required fields are correctly populated for successful user creation. ```json { "user": { "id": 5397423, "email": null, "first_name": "John", "last_name": "Doe", "group_ids": [], "company_reference_id": "1a", "phone": null, "phone_country_code": null, "phone_ext": null, "time_zone": null, "metric_units": false, "carrier_name": "KT Test Carrier", "carrier_street": null, "carrier_city": null, "carrier_state": null, "carrier_zip": null, "violation_alerts": "1_hour", "terminal_street": null, "terminal_city": null, "terminal_state": null, "terminal_zip": null, "cycle": null, "exception_24_hour_restart": false, "exception_8_hour_break": false, "exception_wait_time": false, "exception_short_haul": false, "exception_ca_farm_school_bus": false, "cycle2": null, "exception_24_hour_restart2": false, "exception_8_hour_break2": false, "exception_wait_time2": false, "exception_short_haul2": false, "exception_ca_farm_school_bus2": false, "exception_adverse_driving": false, "exception_adverse_driving2": false, "export_combined": true, "export_recap": true, "export_odometers": true, "username": "john.doe.demo.fleet", "driver_company_id": null, "minute_logs": false, "duty_status": "off_duty", "eld_mode": "none", "drivers_license_number": null, "drivers_license_state": null, "yard_moves_enabled": false, "personal_conveyance_enabled": false, "manual_driving_enabled": false, "time_tracking_mode": "logs", "mobile_last_active_at": null, "mobile_current_sign_in_at": null, "mobile_last_sign_in_at": null, "web_last_active_at": null, "company_connection": { "id": 4698551, "role": "driver", "status": "active", "company_connection_user_roles": [] }, "role": "driver", "status": "active", "web_current_sign_in_at": null, "web_last_sign_in_at": null, "external_ids": [], "created_at": "2025-02-05T19:30:04Z", "updated_at": "2025-02-05T19:30:04.209050Z" } } ``` -------------------------------- ### GET /websites/developer_gomotive_reference Source: https://developer.gomotive.com/reference/fetch-a-list-of-all-the-company-asset-geofence-events Retrieves a list of geofence events associated with a specific geofence. This endpoint returns detailed information about each event, including start and end times, duration, and the asset involved. ```APIDOC ## GET /websites/developer_gomotive_reference ### Description Retrieves a list of geofence events associated with a specific geofence. This endpoint returns detailed information about each event, including start and end times, duration, and the asset involved. ### Method GET ### Endpoint /websites/developer_gomotive_reference ### Parameters #### Query Parameters - **geofence_id** (integer) - Required - The ID of the geofence to retrieve events for. - **start_time** (string) - Optional - The start of the time range to filter events (ISO 8601 format). - **end_time** (string) - Optional - The end of the time range to filter events (ISO 8601 format). ### Request Example ```json { "query": "?geofence_id=1&start_time=2021-08-23T00:00:00Z&end_time=2021-08-26T23:59:59Z" } ``` ### Response #### Success Response (200) - **geofence_events** (array) - A list of geofence event objects. - **geofence_event** (object) - Contains details of a single geofence event. - **id** (integer) - The unique identifier for the geofence event. - **geofence_id** (integer) - The ID of the geofence associated with this event. - **start_time** (string) - The timestamp when the asset entered the geofence (ISO 8601 format). - **end_time** (string) - The timestamp when the asset exited the geofence (ISO 8601 format). - **duration** (integer) - The duration in seconds the asset spent within the geofence. - **asset** (object) - Information about the asset involved in the geofence event. - **id** (integer) - The unique identifier for the asset. - **name** (string) - The name of the asset. - **status** (string) - The current status of the asset (e.g., "active"). - **type** (string) - The type of the asset (e.g., "curtain_side"). - **vin** (string) - The Vehicle Identification Number (VIN) of the asset (nullable). - **license_plate_state** (string) - The state where the license plate is registered (nullable). - **license_plate_number** (string) - The license plate number of the asset (nullable). - **make** (string) - The manufacturer of the asset. - **model** (string) - The model of the asset. - **year** (string) - The manufacturing year of the asset. - **axle** (integer) - The number of axles on the asset (nullable). - **weight_metric_units** (boolean) - True if weight is in metric units, false otherwise. - **length_metric_units** (boolean) - True if length is in metric units, false otherwise. - **leased** (boolean) - True if the asset is leased, false otherwise. - **notes** (string) - Any additional notes about the asset (nullable). - **length** (number) - The length of the asset (nullable). - **gvwr** (integer) - The Gross Vehicle Weight Rating (GVWR). - **gawr** (integer) - The Gross Axle Weight Rating (GAWR). - **asset_gateway** (object) - Information about the asset's gateway. - **id** (integer) - The unique identifier for the asset gateway. - **identifier** (string) - The identifier string of the asset gateway. - **active** (boolean) - Whether the asset gateway is active. - **external_ids** (array) - A list of external identifiers for the asset. #### Response Example ```json { "geofence_events": [ { "geofence_event": { "id": 13, "geofence_id": 1, "start_time": "2021-08-23T22:31:02Z", "end_time": "2021-08-23T22:31:18Z", "duration": 16, "asset": { "id": 197, "name": "testasset1", "status": "active", "type": "curtain_side", "vin": null, "license_plate_state": null, "license_plate_number": null, "make": "John Deere", "model": "uwu", "year": "2017", "axle": null, "weight_metric_units": false, "length_metric_units": false, "leased": false, "notes": null, "length": null, "gvwr": 0, "gawr": 0, "asset_gateway": { "id": 20, "identifier": "AT0-V9P-DD3", "active": true }, "external_ids": [] } } } ] } ``` ``` -------------------------------- ### GET /v1/oem_entities Source: https://developer.gomotive.com/reference/fetch-a-list-of-all-the-companys-oem-entities Retrieves a list of the company's OEM entities. You can filter the results by specifying a start time, end time, or equipment ID. ```APIDOC ## GET /v1/oem_entities ### Description Lists the company's OEM entities. This endpoint allows you to fetch a list of all OEM entities associated with your company, with options to filter by time range and specific equipment. ### Method GET ### Endpoint /v1/oem_entities ### Parameters #### Query Parameters - **start_time** (string) - Optional - Specify the start time for fetching the location of the OEM entities (format: date). - **end_time** (string) - Optional - Specify the end time for fetching the location of the OEM entities (format: date). - **equipment_id** (string) - Optional - Specify the ID of the equipment that you want to fetch. ### Request Example ```json { "example": "GET /v1/oem_entities?start_time=2023-01-01&end_time=2023-01-31&equipment_id=XYZ123" } ``` ### Response #### Success Response (200) - **oem_entities** (array) - An array of OEM entity objects. - **oem_entity** (object) - Details of a single OEM entity. - **id** (integer) - The unique identifier for the OEM entity. - **updated_at** (string) - The timestamp when the entity was last updated. - **status** (string) - The current status of the entity (e.g., 'active'). - **entity_type** (string) - The type of the entity (e.g., 'asset'). - **make** (string) - The manufacturer of the entity. - **model** (string) - The model of the entity. - **type** (string) - The general type of the entity. - **custom_type** (string) - A custom type designation for the entity. - **serial_number** (string) - The serial number of the entity. - **vendor** (string) - The vendor associated with the entity. - **locations** (array) - An array of location objects for the entity. - **updated_at** (string) - The timestamp when the location data was last updated. - **zip** (string) - The zip code of the location. - **country** (string) - The country of the location. - **state** (string) - The state of the location. - **city** (string) - The city of the location. - **street** (string) - The street of the location. - **house_number** (string) - The house number of the location. - **lat** (number) - The latitude coordinate. - **lon** (number) - The longitude coordinate. - **operating_hours** (number) - The total operating hours. - **idle_hours** (number) - The total idle hours. - **fuel_used** (number) - The total fuel consumed. - **fuel_used_last_day** (number) - Fuel consumed in the last day. - **fuel_units** (string) - The unit for fuel measurement (e.g., 'litre'). - **fuel_remaining** (number) - The amount of fuel remaining. - **def_remaining** (number) - The amount of DEF remaining. - **engine_number** (string) - The engine number. - **engine_running** (boolean) - Indicates if the engine is currently running. - **power_take_off_hours** (number) - Hours the power take-off was active. - **avg_load_factor_last_day** (number) - Average load factor in the last day. - **max_speed_last_day** (number) - Maximum speed recorded in the last day. - **max_speed_unit** (string) - The unit for maximum speed. - **load_count** (number) - The number of load cycles. - **payload_totals** (number) - Total payload processed. - **payload_units** (string) - The unit for payload measurement. - **non_productive_regen_hours** (number) - Hours spent on non-productive regeneration. - **idle_non_operating_hours** (number) - Hours spent idle without operation. #### Response Example ```json { "oem_entities": [ { "oem_entity": { "id": 19913, "updated_at": "2023-08-28T16:40:01Z", "status": "active", "entity_type": "asset", "make": "KOMATSU", "model": "PC138USLC-11", "type": "other", "custom_type": "123", "serial_number": "51151", "vendor": "Komtrax (Komatsu)", "locations": [ { "updated_at": "2023-08-28T00:10:02+00:00", "zip": "70363", "country": "US", "state": "LA", "city": "Houma", "street": "S Van Ave", "house_number": null, "lat": 29.575864791870117, "lon": -90.71229553222656, "operating_hours": 2252.7, "idle_hours": 0, "fuel_used": 8651, "fuel_used_last_day": null, "fuel_units": "litre", "fuel_remaining": null, "def_remaining": null, "engine_number": null, "engine_running": false, "power_take_off_hours": 0, "avg_load_factor_last_day": null, "max_speed_last_day": null, "max_speed_unit": null, "load_count": 0, "payload_totals": 0, "payload_units": null, "non_productive_regen_hours": 0, "idle_non_operating_hours": 0 } ] } } ] } ``` ``` -------------------------------- ### Fetch Geofence Information by ID (OpenAPI Example) Source: https://developer.gomotive.com/reference/fetch-a-geofence-information-using-its-id This snippet demonstrates an example response for fetching geofence information using its ID. It details the structure of a successful response, including geofence details like name, category, status, address, and location points. The API uses an 'x-api-key' for authentication. ```json { "geofence": { "id": 1004, "name": "alpha", "category": "Fuel Station", "status": "active", "description": "notes for geofence", "address": "1303 N Collins St, Arlington, TX 76011, USA", "location_points": [ { "lat": 33.667893, "lon": 73.062074 }, { "lat": 33.665052, "lon": 73.067689 }, { "lat": 33.662428, "lon": 73.061814 }, { "lat": 33.666374, "lon": 73.058196 }, { "lat": 33.667893, "lon": 73.062074 } ] } } ``` -------------------------------- ### Create User with OAuth 2.0 (Ruby) Source: https://developer.gomotive.com/reference/create-a-new-user This Ruby script utilizes the Net::HTTP library to send a POST request to the Gomotive API for user creation. It includes setting up authentication with an OAuth 2.0 token and constructing the user payload, including role and other attributes. This code is useful for programmatic user management within the Gomotive platform. ```ruby require 'uri' require 'net/http' require 'json' url = URI('https://api.gomotive.com/v1/users') http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Post.new(url) request['Authorization'] = "Bearer " request['Content-Type'] = 'application/json' params = { :email => nil, :first_name => "John", :last_name => "Doe", :phone => nil, :phone_country_code => nil, :phone_ext => nil, :time_zone => nil, :carrier_name => nil, :carrier_street => nil, :carrier_city => nil, :carrier_state => nil, :carrier_zip => nil, :violation_alerts => "1_hour", :terminal_street => nil, :terminal_city => nil, :terminal_state => nil, :terminal_zip => nil, :exception_24_hour_restart => false, :exception_8_hour_break => false, :exception_wait_time => false, :exception_short_haul => false, :exception_ca_farm_school_bus => false, :exception_adverse_driving => false, :export_combined => true, :export_recap => true, :export_odometers => true, :metric_units => false, :username => "john.doe.demo.fleet", :password => "password", :cycle => nil, :driver_company_id => nil, :minute_logs => false, :duty_status => "off_duty", :eld_mode => "none", :drivers_license_number => nil, :drivers_license_state => nil, :yard_moves_enabled => false, :personal_conveyance_enabled => false, :manual_driving_enabled => false, :role => "driver", :status => "active", :dot_id => "12345678", :time_tracking_mode => "logs" } request.body = params.to_json response = http.request(request) puts response.read_body ``` -------------------------------- ### List Company Webhooks OpenAPI Definition Source: https://developer.gomotive.com/reference/list-the-companys-webhooks Defines the GET endpoint for listing company webhooks. It includes query and header parameters for pagination, timezone, units, and user ID. The response schema and an example are provided. ```json { "openapi": "3.1.0", "info": { "title": "Motive", "version": "1.0" }, "servers": [ { "url": "https://api.gomotive.com" } ], "components": { "securitySchemes": { "sec0": { "type": "apiKey", "in": "header", "name": "x-api-key" } } }, "security": [ { "sec0": [] } ], "paths": { "/v1/company_webhooks": { "get": { "summary": "List the company's webhooks", "description": "", "operationId": "list-the-companys-webhooks", "parameters": [ { "name": "per_page", "in": "query", "description": "Number of records to return per page.", "schema": { "type": "integer", "format": "int32", "default": 25 } }, { "name": "page_no", "in": "query', "description": "Current page number.", "schema": { "type": "integer", "format": "int32", "default": 1 } }, { "name": "X-Time-Zone", "in": "header", "description": "Specify the timezone for formatting the timestamps.", "schema": { "type": "string" } }, { "name": "X-Metric-Units", "in": "header", "description": "Specify if you want to use the Metric units or the Imperial units. TRUE: Metric units. FALSE: Imperial Units", "schema": { "type": "boolean" } }, { "name": "X-User-Id", "in": "header", "description": "Specify the ID of the Fleet Admin or the Fleet Manager who is accessing this endpoint.", "schema": { "type": "integer", "format": "int32" } } ], "responses": { "200": { "description": "200", "content": { "application/json": { "examples": { "List all the webhooks": { "value": "{\n \"company_webhooks\": [\n {\n \"company_webhook\": {\n \"id\": 42,\n \"url\": \"https://api.gomotive.com/callbacktest/842b02\",\n \"secret\": \"fe8b75de0a4e5898f0011faeb8c93654\",\n \"format\": \"json\",\n \"actions\": [\n \"vehicle_location_received\",\n \"vehicle_location_updated\"\n ],\n \"enabled\": false\n }\n },\n {\n \"company_webhook\": {\n \"id\": 43,\n \"url\": \"https://api.gomotive.com/callbacktest/a6a783\",\n \"secret\": \"66a7368063cb21887f546c7af91be59c\",\n \"format\": \"json\",\n \"actions\": [\n \"vehicle_location_received\",\n \"vehicle_location_updated\"\n ],\n \"enabled\": false\n }\n },\n {\n \"company_webhook\": {\n \"id\": 44,\n \"url\": \"https://api.gomotive.com/callbacktest/53a52c\",\n \"secret\": \"4451dc96513b3a67107466dd2c4d9589\",\n \"format\": \"json\",\n \"actions\": [\n \"vehicle_location_received\",\n \"vehicle_location_updated\"\n ],\n \"enabled\": false\n }\n },\n {\n \"company_webhook\": {\n \"id\": 45,\n \"url\": \"https://api.gomotive.com/callbacktest/6fb337\",\n \"secret\": \"4177fbd88c30faaee03a4362648bd663\",\n \"format\": \"json\",\n \"actions\": [\n \"vehicle_location_received\",\n \"vehicle_location_updated\"\n ],\n \"enabled\": false\n }\n },\n {\n \"company_webhook\": {\n \"id\": 46,\n \"url\": \"https://api.gomotive.com/callbacktest/8cd6da\",\n \"secret\": \"6e41817a048b009435e5102fca17db55\",\n \"format\": \"json\",\n \"actions\": [\n \"vehicle_location_received\",\n \"vehicle_location_updated\"\n ],\n \"enabled\": false\n }\n }\n ],\n \"pagination\": {\n \"per_page\": 25,\n \"page_no\": 1,\n \"total\": 5\n }\n}" } }, "schema": { "type": "object", "properties": { "company_webhooks": { "type": "array", "items": { "type": "object", "properties": { "company_webhook": { "type": "object", "properties": { "id": { "type": "integer", "example": 42, "default": 0 }, "url": { ``` -------------------------------- ### GET /websites/developer_gomotive_reference Source: https://developer.gomotive.com/reference/fetch-a-list-of-the-vehicles-driving-periods Retrieves a list of driving periods, including details about each period such as start and end times, duration, driver information, vehicle details, and location data. Supports pagination for managing large result sets. ```APIDOC ## GET /websites/developer_gomotive_reference ### Description Retrieves a list of driving periods with detailed information. This endpoint supports pagination. ### Method GET ### Endpoint /websites/developer_gomotive_reference ### Query Parameters - **per_page** (integer) - Optional - Number of items per page for pagination. - **page_no** (integer) - Optional - The page number to retrieve. ### Response #### Success Response (200) - **driving_periods** (array) - An array of driving period objects. - **driving_period** (object) - Contains details of a single driving period. - **id** (integer) - Unique identifier for the driving period. - **start_time** (string) - The start timestamp of the driving period in ISO 8601 format. - **end_time** (string) - The end timestamp of the driving period in ISO 8601 format. - **status** (any) - The status of the driving period (can be null). - **type** (string) - The type of the period (e.g., "driving"). - **annotation_status** (any) - The annotation status of the driving period (can be null or an integer). - **notes** (any) - Any notes associated with the driving period (can be null). - **duration** (integer) - The duration of the driving period in seconds. - **start_kilometers** (integer) - The odometer reading at the start of the period. - **end_kilometers** (integer) - The odometer reading at the end of the period. - **start_hvb_state_of_charge** (number) - The HVB state of charge at the start. - **end_hvb_state_of_charge** (number) - The HVB state of charge at the end. - **start_hvb_lifetime_energy_output** (number) - The HVB lifetime energy output at the start. - **end_hvb_lifetime_energy_output** (number) - The HVB lifetime energy output at the end. - **driver** (object) - Information about the driver. - **id** (integer) - Driver's unique identifier. - **first_name** (string) - Driver's first name. - **last_name** (string) - Driver's last name. - **username** (any) - Driver's username (can be null). - **email** (string) - Driver's email address. - **driver_company_id** (any) - Driver's company ID (can be null). - **status** (string) - Driver's status (e.g., "active"). - **role** (string) - Driver's role (e.g., "driver"). - **vehicle** (object) - Information about the vehicle. - **id** (integer) - Vehicle's unique identifier. - **number** (string) - Vehicle's identifier number. - **year** (any) - Vehicle's year (can be null). - **make** (any) - Vehicle's make (can be null). - **model** (any) - Vehicle's model (can be null). - **vin** (any) - Vehicle's VIN (can be null). - **metric_units** (boolean) - Whether the vehicle uses metric units. - **origin** (string) - The origin address of the driving period. - **origin_lat** (number) - The latitude of the origin. - **origin_lon** (number) - The longitude of the origin. - **destination_lat** (number) - The latitude of the destination. - **destination_lon** (number) - The longitude of the destination. - **destination** (string) - The destination address of the driving period. - **distance** (string) - The distance covered during the period (e.g., "54.7 mi"). - **source** (integer) - The source of the data. - **pagination** (object) - Pagination details. - **per_page** (integer) - Number of items per page. - **page_no** (integer) - Current page number. - **total** (integer) - Total number of items available. #### Response Example ```json { "driving_periods": [ { "driving_period": { "id": 71, "start_time": "2018-01-01T14:00:00Z", "end_time": "2018-01-01T15:00:00Z", "status": null, "type": "driving", "annotation_status": null, "notes": null, "duration": 3600, "start_kilometers": 76, "end_kilometers": 164, "start_hvb_state_of_charge": 70.1, "end_hvb_state_of_charge": 90.1, "start_hvb_lifetime_energy_output": 1101.1, "end_hvb_lifetime_energy_output": 1201.1, "driver": { "id": 3102, "first_name": "bfoo", "last_name": "bar", "username": null, "email": "3e9595c90b19@keeptruckin.com", "driver_company_id": null, "status": "active", "role": "driver" }, "vehicle": { "id": 1009, "number": "bar", "year": null, "make": null, "model": null, "vin": null, "metric_units": false }, "origin": "84 Corporate Park, Irvine, CA 92606", "origin_lat": 33.6932408, "origin_lon": -117.8266837, "destination_lat": 33.6930478, "destination_lon": 33.6930478, "destination": "Chino Hills, CA", "distance": "54.7 mi", "source": 1 } }, { "driving_period": { "id": 70, "start_time": "2018-01-01T13:00:00Z", "end_time": "2018-01-01T14:00:00Z", "status": null, "type": "driving", "annotation_status": 2, "notes": null, "duration": 3600, "start_kilometers": 80, "end_kilometers": 137, "start_hvb_state_of_charge": 70.1, "end_hvb_state_of_charge": 90.1, "start_hvb_lifetime_energy_output": 1101.1, "end_hvb_lifetime_energy_output": 1201.1, "driver": { "id": 3102, "first_name": "bfoo", "last_name": "bar", "username": null, "email": "3e9595c90b19@keeptruckin.com", "driver_company_id": null, "status": "active", "role": "driver" }, "vehicle": { "id": 1009, "number": "bar", "year": null, "make": null, "model": null, "vin": null, "metric_units": false }, "origin": "963 Sweeney St, City of North Tonawanda, NY 14120", "origin_lat": 43.0210282, "origin_lon": -78.8457431, "destination_lat": 43.0209093, "destination_lon": -78.8457486, "destination": "963 Sweeney St, City of North Tonawanda, NY 14120", "distance": "35.4 mi", "source": 2 } } ], "pagination": { "per_page": 25, "page_no": 1, "total": 2 } } ``` ``` -------------------------------- ### Pagination Information Example Source: https://developer.gomotive.com/reference/fetch-a-list-of-all-the-assets-and-their-locations This JSON object details the pagination parameters for a list of assets. It includes the number of items per page and the current page number. This is crucial for handling large datasets and implementing client-side pagination to efficiently retrieve and display information. ```json { "pagination": { "per_page": 25, "page_no": ``` -------------------------------- ### GET /v3/vehicle_locations Source: https://developer.gomotive.com/reference/overview-locations Retrieves the location information for all vehicles with the Motive Vehicle Gateway installed. For other vehicles, use v1 and v2 endpoints. Fleet operators use this to access refined vehicle location data, improving tracking and operational insights. ```APIDOC ## GET /v3/vehicle_locations ### Description Retrieves the location information for all vehicles that have the Motive Vehicle Gateway installed. ### Method GET ### Endpoint /v3/vehicle_locations ### Parameters #### Query Parameters None #### Request Body None ### Response #### Success Response (200) - **vehicles** (array) - An array of vehicle location objects with v3 enhancements. - **id** (string) - The unique identifier for the vehicle. - **location** (object) - The current or last-known location of the vehicle. - **latitude** (number) - The latitude coordinate. - **longitude** (number) - The longitude coordinate. - **timestamp** (string) - The timestamp of the location data. - **gateway_status** (string) - The status of the Motive Vehicle Gateway. #### Response Example ```json { "vehicles": [ { "id": "vehicle-789", "location": { "latitude": 37.7749, "longitude": -122.4194, "timestamp": "2023-10-27T10:10:00Z", "gateway_status": "online" } } ] } ``` ``` -------------------------------- ### User and System Settings Source: https://developer.gomotive.com/reference/create-a-new-user This section details various fields related to user profiles, system settings, and operational parameters within the Gomotive platform. ```APIDOC ## User and System Settings ### Description This section details various fields related to user profiles, system settings, and operational parameters within the Gomotive platform. ### Fields - **terminal_zip** (String) - Zip code of the terminal. - **exception_24_hour_restart** (Boolean) - Indicates if the 24-hour restart exception is enabled. - **exception_8_hour_break** (Boolean) - Indicates if the 8-hour break exception is enabled. - **exception_wait_time** (Boolean) - Indicates if the wait time exception is enabled. - **exception_short_haul** (Boolean) - Indicates if the short haul exception is enabled. - **exception_ca_farm_school_bus** (Boolean) - Indicates if the California farm school bus exception is enabled. - **exception_adverse_driving** (Boolean) - Indicates if the adverse driving exception is enabled. - **export_combined** (Boolean) - Indicates if the combined export option is enabled. - **export_recap** (Boolean) - Indicates if the recap export option is enabled. - **export_odometers** (Boolean) - Indicates if the odometer export option is enabled. - **metric_units** (Boolean) - Indicates if metric units are used. - **username** (String) - Username of the user. - **cycle** (String) - Cycle type associated with the user. - **driver_company_id** (String) - Driver's company ID. - **minute_logs** (Boolean) - Indicates if minute logs are enabled. - **duty_status** (String) - Current duty status of the user. - **eld_mode** (String) - The mode of the vehicle gateway. - **drivers_license_number** (String) - Driver's license number. - **drivers_license_state** (String) - State where the driver's license was issued. - **yard_moves_enabled** (Boolean) - Indicates if yard moves are enabled. - **personal_conveyance_enabled** (Boolean) - Indicates if personal conveyance is enabled. - **manual_driving_enabled** (Boolean) - Indicates if manual driving is enabled. - **role** (String) - Role of the user (e.g., `driver`). - **status** (String) - Status of the user (e.g., `active`). - **created_at** (String) - Timestamp when the user was created. - **updated_at** (String) - Timestamp when the user was last updated. - **external_ids** (Array) - External IDs associated with the user. - **dot_id** (String) - DOT ID associated with the user. ``` -------------------------------- ### API Response Example: Timestamp Fields Source: https://developer.gomotive.com/reference/fetch-a-list-of-all-active-subscriptions Demonstrates how timestamp data is represented in API responses, using ISO 8601 formatted strings for start and end times. This format is standard for date-time information. ```json { "start_time": { "type": "string", "example": "2020-05-06T18:32:59Z" }, "end_time": { "type": "string", "example": "2020-05-08T18:32:59Z" } } ``` -------------------------------- ### GET /websites/developer_gomotive_reference/assets Source: https://developer.gomotive.com/reference/view-reefer-activity-data Retrieves a list of assets with their details and sensor information. Supports pagination. ```APIDOC ## GET /websites/developer_gomotive_reference/assets ### Description Retrieves a list of assets along with their details and sensor data. This endpoint supports pagination to manage large datasets. ### Method GET ### Endpoint /websites/developer_gomotive_reference/assets ### Query Parameters - **per_page** (integer) - Optional - The number of assets to return per page. - **page_no** (integer) - Optional - The page number to retrieve. ### Response #### Success Response (200) - **assets** (array) - An array of asset objects, each containing detailed information and sensor readings. - **pagination** (object) - An object containing pagination details (per_page, page_no, total). #### Response Example ```json { "assets": [ { "asset": { "id": 31773, "make": "CARRIER", "model": "NDK537*6LHJ2", "type": "reefer", "notes": null, "status": "active", "license_plate_state": null, "license_plate_number": null, "year": null, "length": null, "length_metric_units": null, "axle": null, "gvwr": null, "gawr": null, "weight_metric_units": null, "leased": null, "name": "RJ426020", "source": "Carrier", "location": { "read_id": 8960641526, "sensors": [ { "zone_number": 1, "thermoking": null, "snowpiercers": [ { "id": 123, "identifier": "ACDE31AE110001", "model": "DES-2", "temperature_deg_c": 34, "humidity_pct": 14, "zone_location": "front", "door_status_open": true, "last_updated_at": "2024-06-13T14:23:31Z" } ] }, { "zone_number": 2, "thermoking": null, "snowpiercers": [ { "id": 7251, "identifier": "ACDE31AE110007", "model": "ES-2", "temperature_deg_c": 9, "humidity_pct": 14, "zone_location": "front", "door_status_open": null, "last_updated_at": "2024-11-26T13:06:51Z" } ] } ] } } } ], "pagination": { "per_page": 25, "page_no": 1, "total": 4 } } ``` ```