Getting Started
Authorization header of every request.
Welcome to the RoadBays API. To get started, sign into your account, navigate to Company Settings → API, and generate your API key.
Include your key as a Bearer token on every request:
curl --location --request GET 'https://www.roadbays.com/api/v1_Cases' \
--header 'Authorization: Bearer YOUR_API_KEY_HERE'
Rate Limits
The following limits apply per API key. They are set well above the volume a typical integration needs, and are published so you can design against a known ceiling.
| Limit | Value | Applies To |
|---|---|---|
| Sustained requests | 300 / minute | All endpoints |
| Daily volume | 250,000 / day | All endpoints |
| Write operations | 60 / minute | POST, PUT, DELETE |
| Concurrent requests | 10 | Simultaneous in-flight requests |
| Page size | 500 records | List endpoints |
Requests beyond these limits are throttled and receive a 429 Too Many Requests response. Honor the Retry-After header and back off exponentially rather than retrying immediately.
To stay well inside the limits, pull in pages of 500 using the largest date range your process allows rather than requesting records one at a time, and cache reference data such as repair reasons, users, and PM tasks instead of refetching it on every run.
List Cases
Retrieve a list of cases filtered by date range using the case open date.
curl --location --request GET \
'https://www.roadbays.com/api/v1_Cases?startdate=10-1-2021&enddate=10-4-2021' \
--header 'Authorization: Bearer YOUR_API_KEY'
[
{
"id": 408500,
"dateCreated": "2021-10-03T09:07:13.84",
"inactive": 0,
"accountGUID": "b5b1032a-6336-4d51-c1z3-bad295795192",
"dateOpened": "2021-10-03T09:07:13.84",
"dateCompleted": "2021-10-03T09:09:56.12",
"dateClosed": "2021-10-03T09:09:56.12",
"assignedUser": 81,
"vendors": {
"id": 10464,
"name": "Shop Location 1",
"address": "1234 Main Ave",
"city": "Green Bay",
"zip": "54304",
"email": "test@email.com",
"phone": "92012345687",
"latitude": 47.254547,
"longitude": -67.9403301,
"vendorType": "CustomerShop",
"ranking": 6
},
"vendorsId": 10464,
"caseNumber": 8,
"caseStatus": { "id": 3, "name": "Closed" },
"caseStatusId": 3,
"description": "Test Header",
"units": {
"id": 1030,
"unitNumber": "3345",
"description": "Mack Truck",
"unitTypesId": 1014,
"serialNo": "1XPBDP956AD486131",
"engine": "MP8",
"engineManufacturer": "MACK",
"unitMake": "MACK",
"unitModel": "Anthem",
"modelYear": "2020",
"unitSearchLabel": "3345 Tractor"
},
"unitsId": 1030,
"repairReasonsId": 12,
"priority": { "id": 5, "value": "5" },
"priorityId": 5,
"maintenanceBoard": 1
}
]
| Parameter | Type | Description |
|---|---|---|
| Authorization | string | Bearer token API key required |
| startdate | DateTime | Start date filter by case open date required |
| enddate | DateTime | End date filter by case open date required |
Get Case
Retrieve full details for a single case by its RoadBays system-generated ID.
curl --location --request GET \
'https://www.roadbays.com/api/v1_Cases/408500' \
--header 'Authorization: Bearer YOUR_API_KEY'
{
"id": 408500,
"dateCreated": "2021-10-03T09:07:13.84",
"inactive": 0,
"accountGUID": "b5b1032a-6336-4d51-c1z3-bad295795192",
"dateOpened": "2021-10-03T09:07:13.84",
"dateCompleted": "2021-10-03T09:09:56.12",
"dateClosed": "2021-10-03T09:09:56.12",
"assignedUser": 81,
"vendors": null,
"vendorsId": 10464,
"caseNumber": 8,
"driverId": null,
"caseStatus": null,
"caseStatusId": 3,
"description": "This is a case description",
"locationDescription": null,
"units": null,
"unitsId": 100030,
"repairReasonsId": 12,
"offSet": "-05:00",
"latitude": null,
"longitude": null,
"priority": null,
"priorityId": 5,
"maintenanceBoard": 1
}
| Parameter | Type | Description |
|---|---|---|
| Authorization | string | Bearer token API key required |
| caseId | integer | RoadBays system-generated case ID required |
Create Case
Create a new maintenance case for a unit. Identify the unit by vin or by unitsId. If a VIN isn't in your account yet, RoadBays decodes it and adds the unit automatically. If you don't send assignedUser, the case is assigned to the first active user on your account.
curl --location --request POST \
'https://www.roadbays.com/api/v1_Cases' \
--header 'Authorization: Bearer YOUR_API_KEY' \
--header 'Content-Type: application/x-www-form-urlencoded' \
--data-urlencode 'vin=1XPCEP6Y0JD486131' \
--data-urlencode 'description=Case Description' \
--data-urlencode 'assignedUser=81' \
--data-urlencode 'locDescription=located in NE corner of lot' \
--data-urlencode 'latitude=44.503807048107156' \
--data-urlencode 'longitude=-88.0080488474994' \
--data-urlencode 'userField1=custom field data 1' \
--data-urlencode 'userField2=custom field data 2'
{
"id": 4102,
"dateCreated": "2021-10-24T20:40:44.428835-05:00",
"inactive": 0,
"accountGUID": "b5b1032a-6336-4d51-c1z3-bad295795192",
"dateOpened": "2021-10-24T20:40:44.428835-05:00",
"dateCompleted": null,
"dateClosed": null,
"assignedUser": 81,
"vendorsId": null,
"caseNumber": 39,
"caseStatusId": 1,
"description": "Case Description",
"unitsId": 1030,
"repairReasonsId": null,
"offSet": "-05:00",
"latitude": "44.503807048107156",
"longitude": "-88.0080488474994",
"priorityId": 5,
"maintenanceBoard": 1
}
| Parameter | Type | Description |
|---|---|---|
| Authorization | string | Bearer token API key required |
| vin | string | 17-character VIN; required if no unitsId |
| unitsId | integer | RoadBays unit ID; required if no vin |
| description | string | Case description optional |
| assignedUser | integer | User ID from List Users; defaults to the first active user optional |
| locDescription | string | Where the unit is located optional |
| latitude | string | Unit latitude optional |
| longitude | string | Unit longitude optional |
| userField1 | string | Custom field 1 optional |
| userField2 | string | Custom field 2 optional |
Create Case Note
Append a text note to an existing case. Notes appear in the case communication feed visible to all assigned parties.
curl --location --request POST \
'https://www.roadbays.com/api/v1_CaseNotes' \
--header 'Authorization: Bearer YOUR_API_KEY' \
--header 'Content-Type: application/x-www-form-urlencoded' \
--data-urlencode 'caseId=4102' \
--data-urlencode 'noteText=Hello World'
{
"id": 2176,
"dateCreated": "2021-10-24T20:42:57.4429432-05:00",
"accountGUID": "b5b1032a-6336-4d51-c1z3-bad295795192",
"createdBy": "Roadbays API_External",
"createdByName": "Roadbays API_External",
"note": "Hello World",
"caseID": 4102,
"offSet": "-05:00"
}
| Parameter | Type | Description |
|---|---|---|
| Authorization | string | Bearer token API key required |
| caseId | integer | RoadBays system-generated case ID required |
| noteText | string | Text to append to the case note feed required |
List Case Notes
Returns every note on a case, oldest first.
curl --location --request GET \
'https://www.roadbays.com/api/v1_CaseNotes?caseId=4102' \
--header 'Authorization: Bearer YOUR_API_KEY'
[
{
"id": 2176,
"dateCreated": "2021-10-24T20:42:57.443",
"accountGUID": "b5b1032a-6336-4d51-c1z3-bad295795192",
"createdBy": "Roadbays API_External",
"createdByName": "Roadbays API_External",
"note": "Hello World",
"caseID": 4102,
"offSet": "-05:00"
}
]
| Parameter | Type | Description |
|---|---|---|
| Authorization | string | Bearer token API key required |
| caseId | integer | RoadBays system-generated case ID required |
Case Notification
Send a notification for a case via Email or SMS. Set NotificationTypesId to 2 for Email or 3 for SMS.
curl --location --request POST \
'https://www.roadbays.com/api/v1CaseNotifications' \
--header 'Authorization: Bearer YOUR_API_KEY' \
--header 'Content-Type: application/x-www-form-urlencoded' \
--data-urlencode 'CaseId=4102' \
--data-urlencode 'NotificationTypesId=3' \
--data-urlencode 'NotificationContact=9207640865' \
--data-urlencode 'CaseHeader=True' \
--data-urlencode 'CaseNotes=True'
{
"id": 39,
"caseId": 4102,
"invoiceId": 0,
"accountGUID": "b5b1032a-6336-4d51-c1z3-bad295795192",
"inactive": 0,
"dateCreated": "2021-12-05T05:59:37",
"notificationTypesId": 3,
"notificationContact": "9207640865",
"caseHeader": true,
"caseNotes": true
}
| Parameter | Type | Description |
|---|---|---|
| Authorization | string | Bearer token API key required |
| CaseId | integer | RoadBays system-generated case ID required |
| NotificationTypesId | integer | Email = 2 · SMS = 3 required |
| NotificationContact | string | Email address or phone number required |
| CaseHeader | bool | Notify on case header changes required |
| CaseNotes | bool | Notify on new case notes required |
Tire Alert
Send a low tire pressure reading from your TPMS or telematics system. RoadBays opens a priority 1 case on the unit and, if your account has a tire alert AI assistant set up, calls the phone number on your company profile to report it.
curl --location --request POST \
'https://www.roadbays.com/api/v1/TireAlert' \
--header 'Authorization: Bearer YOUR_API_KEY' \
--header 'Content-Type: application/json' \
--data '{
"vin": "1XPBDP956AD486131",
"tirePosition": "Rear Right Outer",
"pressurePsi": 78,
"thresholdPsi": 95,
"pressureTrend": "slow leak",
"assignedUser": 81
}'
{
"caseId": 4188,
"caseNumber": 52,
"vapiCallId": "c1f7e2a4-3b9d-4f0e-8a61-2d7c9b5e4a10",
"message": "Case created and alert call initiated."
}
| Parameter | Type | Description |
|---|---|---|
| Authorization | string | Bearer token API key required |
| vin | string | VIN of an existing unit in RoadBays required |
| tirePosition | string | Tire location, e.g. Front Left or Rear Right Outer required |
| pressurePsi | decimal | Current pressure reading required |
| thresholdPsi | decimal | Pressure threshold that triggered the alert required |
| pressureTrend | string | Short description, e.g. dropping fast optional |
| assignedUser | integer | User to assign the case to; defaults to the first active user optional |
Billing Workbench Overview
A billing workbench groups three documents for one repair: an Estimate, a Work Order, and an Invoice. All three share a documentGroupId and are created together in a single call.
Lines (parts, labor, fees) are added to a specific document by its billingDocumentId. Each line belongs to a section. If you don't pass a section, the line goes into a section named General, which is created if needed.
Billing Lookups
Returns the IDs you need to build billing requests: document types, line types, statuses, repair reasons, and active inventory locations for your account.
curl --location --request GET \
'https://www.roadbays.com/api/v1_Billing/lookups' \
--header 'Authorization: Bearer YOUR_API_KEY'
{
"documentTypes": [
{ "id": 1, "name": "Estimate" },
{ "id": 2, "name": "WorkOrder" },
{ "id": 3, "name": "Invoice" }
],
"lineTypes": [
{ "id": 1, "name": "Labor" },
{ "id": 4, "name": "Part" }
],
"statuses": [
{ "id": 1, "name": "Open" },
{ "id": 2, "name": "Complete" },
{ "id": 3, "name": "Closed" }
],
"repairReasons": [ { "id": 11, "name": "Breakdown" } ],
"inventoryLocations": [ { "id": 7, "name": "Main Shop" } ]
}
| Parameter | Type | Description |
|---|---|---|
| Authorization | string | Bearer token API key required |
List Billing Documents
Returns Estimates, Work Orders, and Invoices opened within a date range, with their current totals. Filter by document type or case number if needed.
curl --location --request GET \
'https://www.roadbays.com/api/v1_Billing?startdate=9-1-2026&enddate=9-30-2026&documentType=invoice' \
--header 'Authorization: Bearer YOUR_API_KEY'
[
{
"id": 9123,
"documentGroupId": "3f2a9c1e-6b7d-4e21-9a0c-2d5f8b7e1c44",
"documentTypeId": 3,
"documentType": "Invoice",
"documentNumber": "INV-1042",
"parentDocumentId": 9122,
"caseNumber": 39,
"unitsId": 1030,
"unitNumber": "3345",
"vin": "1XPBDP956AD486131",
"statusId": 1,
"status": "Open",
"description": "Brake job",
"poNumber": "PO-7781",
"repairReasonsId": 11,
"odometer": 145585,
"dateCreated": "2026-09-23T14:02:11.12",
"dateOpened": "2026-09-23T14:02:11.12",
"dateCompleted": null,
"dateClosed": null,
"taxRate": 5.5,
"laborTotal": 450.00,
"partsTotal": 312.40,
"serviceTotal": 0.00,
"subtotal": 762.40,
"taxTotal": 41.93,
"grandTotal": 804.33
}
]
| Parameter | Type | Description |
|---|---|---|
| Authorization | string | Bearer token API key required |
| startdate | DateTime | Start of the document open date range required |
| enddate | DateTime | End of the document open date range, inclusive of the whole day required |
| documentType | string | estimate, workorder (or wo), or invoice optional |
| caseNumber | integer | Only documents linked to this case number optional |
Get Billing Document
Returns one Estimate, Work Order, or Invoice with its sections, line items, and freshly calculated totals.
curl --location --request GET \
'https://www.roadbays.com/api/v1_Billing/9122' \
--header 'Authorization: Bearer YOUR_API_KEY'
{
"document": {
"id": 9122,
"documentGroupId": "3f2a9c1e-6b7d-4e21-9a0c-2d5f8b7e1c44",
"documentTypeId": 2,
"documentType": "WorkOrder",
"documentNumber": "WO-1042",
"statusId": 1,
"status": "Open",
"grandTotal": 804.33
},
"sections": [
{ "id": 551, "sectionCode": 1, "title": "Front Brakes", "billable": true, "sectionNotes": null }
],
"lines": [
{
"id": 20871,
"billingDocumentId": 9122,
"billingSectionId": 551,
"sectionCode": 1,
"sectionTitle": "Front Brakes",
"billable": true,
"invoiceLineTypeId": 4,
"invoiceLineTypeName": "Part",
"vmrsId": null,
"description": "Brake pad set",
"partNumber": "BP-4471",
"partId": 318,
"inventoryLocationId": 7,
"quantity": 2.0,
"chargeAmount": 156.20,
"totalAmount": 312.40,
"approved": null,
"denied": null,
"deniedComments": null,
"sourceLineId": 20855,
"dateCreated": "2026-09-23T14:10:44.02"
}
]
}
| Parameter | Type | Description |
|---|---|---|
| Authorization | string | Bearer token API key required |
| billingDocumentId | integer | RoadBays billing document ID required |
Get Workbench
Returns the Estimate, Work Order, and Invoice for one workbench, plus a link that opens it in RoadBays.
curl --location --request GET \
'https://www.roadbays.com/api/v1_Billing/group/3f2a9c1e-6b7d-4e21-9a0c-2d5f8b7e1c44' \
--header 'Authorization: Bearer YOUR_API_KEY'
{
"documentGroupId": "3f2a9c1e-6b7d-4e21-9a0c-2d5f8b7e1c44",
"caseNumber": 39,
"unitsId": 1030,
"workbenchUrl": "https://www.roadbays.com/Billing/Workbench?documentGroupId=3f2a9c1e-6b7d-4e21-9a0c-2d5f8b7e1c44&caseNumber=39&unitsId=1030",
"documents": [
{ "id": 9121, "documentType": "Estimate", "documentNumber": "EST-1042", "status": "Open", "grandTotal": 804.33 },
{ "id": 9122, "documentType": "WorkOrder", "documentNumber": "WO-1042", "status": "Open", "grandTotal": 804.33 },
{ "id": 9123, "documentType": "Invoice", "documentNumber": "INV-1042", "status": "Open", "grandTotal": 0.00 }
]
}
| Parameter | Type | Description |
|---|---|---|
| Authorization | string | Bearer token API key required |
| documentGroupId | guid | Workbench group ID returned by Create Workbench required |
Create Workbench
Creates an Estimate, Work Order, and Invoice for a unit in one call. Identify the unit by vin or, for units without a VIN such as trailers and equipment, by unitsId. The unit must already exist in your RoadBays account. Pass a caseId or caseNumber to link the workbench to an existing case. The tax rate is filled in from your account settings unless you send one.
curl --location --request POST \
'https://www.roadbays.com/api/v1_Billing' \
--header 'Authorization: Bearer YOUR_API_KEY' \
--header 'Content-Type: application/x-www-form-urlencoded' \
--data-urlencode 'vin=1XPBDP956AD486131' \
--data-urlencode 'caseNumber=39' \
--data-urlencode 'description=Brake job' \
--data-urlencode 'poNumber=PO-7781' \
--data-urlencode 'repairReasonsId=11' \
--data-urlencode 'odometer=145585'
{
"documentGroupId": "3f2a9c1e-6b7d-4e21-9a0c-2d5f8b7e1c44",
"caseNumber": 39,
"unitsId": 1030,
"workbenchUrl": "https://www.roadbays.com/Billing/Workbench?documentGroupId=3f2a9c1e-6b7d-4e21-9a0c-2d5f8b7e1c44&caseNumber=39&unitsId=1030",
"documents": [
{ "id": 9121, "documentTypeId": 1, "documentType": "Estimate", "documentNumber": "EST-1042", "statusId": 1, "status": "Open", "taxRate": 5.5, "grandTotal": 0.00 },
{ "id": 9122, "documentTypeId": 2, "documentType": "WorkOrder", "documentNumber": "WO-1042", "statusId": 1, "status": "Open", "taxRate": 5.5, "grandTotal": 0.00 },
{ "id": 9123, "documentTypeId": 3, "documentType": "Invoice", "documentNumber": "INV-1042", "statusId": 1, "status": "Open", "taxRate": 5.5, "grandTotal": 0.00 }
]
}
| Parameter | Type | Description |
|---|---|---|
| Authorization | string | Bearer token API key required |
| vin | string | VIN of an existing unit; required if no unitsId |
| unitsId | integer | RoadBays unit ID from List Units; required if no vin |
| caseId | integer | RoadBays case ID to link optional |
| caseNumber | integer | Case number to link, if you don't have the case ID optional |
| description | string | Repair description, applied to all three documents optional |
| poNumber | string | Purchase order number optional |
| repairReasonsId | integer | ID from Billing Lookups or Repair Reasons optional |
| odometer | integer | Odometer reading; also updates the unit if higher than its current mileage optional |
| taxRate | decimal | Tax percentage (e.g. 5.5); defaults to your account rate optional |
Add Line
Adds a part, labor, or fee line to an Estimate, Work Order, or Invoice. Lines added to an Estimate start as not approved. Totals are recalculated automatically.
curl --location --request POST \
'https://www.roadbays.com/api/v1_Billing/9122/lines' \
--header 'Authorization: Bearer YOUR_API_KEY' \
--header 'Content-Type: application/x-www-form-urlencoded' \
--data-urlencode 'invoiceLineTypeId=4' \
--data-urlencode 'description=Brake pad set' \
--data-urlencode 'quantity=2' \
--data-urlencode 'chargeAmount=156.20' \
--data-urlencode 'partNumber=BP-4471' \
--data-urlencode 'partId=318' \
--data-urlencode 'inventoryLocationId=7' \
--data-urlencode 'sectionTitle=Front Brakes' \
--data-urlencode 'sectionCode=1'
{
"id": 20871,
"billingDocumentId": 9122,
"billingSectionId": 551,
"sectionCode": 1,
"sectionTitle": "Front Brakes",
"billable": true,
"invoiceLineTypeId": 4,
"invoiceLineTypeName": "Part",
"description": "Brake pad set",
"partNumber": "BP-4471",
"partId": 318,
"inventoryLocationId": 7,
"quantity": 2.0,
"chargeAmount": 156.20,
"totalAmount": 312.40,
"approved": null,
"denied": null,
"dateCreated": "2026-09-23T14:10:44.02"
}
| Parameter | Type | Description |
|---|---|---|
| Authorization | string | Bearer token API key required |
| billingDocumentId | integer | In the URL path: the Estimate, Work Order, or Invoice ID required |
| invoiceLineTypeId | integer | Line type ID from Billing Lookups required |
| description | string | Line description required |
| quantity | decimal | Quantity or hours; defaults to 1 optional |
| chargeAmount | decimal | Unit price or hourly rate optional |
| partNumber | string | Part number shown on the document optional |
| partId | integer | RoadBays part ID; send with inventoryLocationId optional |
| inventoryLocationId | integer | Location to pull stock from; send with partId optional |
| vmrsId | integer | VMRS code ID optional |
| billingSectionId | integer | Existing section on this document optional |
| sectionTitle | string | Section to find or create when no billingSectionId is sent; defaults to General optional |
| sectionCode | integer | Sort order for a new section optional |
| sectionBillable | bool | Whether a new section is billable; defaults to true optional |
Update Line
Updates a line's type, description, quantity, or price. Only the fields you send are changed. The part and inventory location can't be edited, and neither can the quantity on inventory-linked lines; delete the line and add it again instead.
curl --location --request PUT \
'https://www.roadbays.com/api/v1_Billing/lines/20872' \
--header 'Authorization: Bearer YOUR_API_KEY' \
--header 'Content-Type: application/x-www-form-urlencoded' \
--data-urlencode 'quantity=3.5' \
--data-urlencode 'chargeAmount=135.00'
{
"id": 20872,
"billingDocumentId": 9122,
"billingSectionId": 551,
"invoiceLineTypeId": 1,
"invoiceLineTypeName": "Labor",
"description": "Replace front pads and rotors",
"quantity": 3.5,
"chargeAmount": 135.00,
"totalAmount": 472.50
}
| Parameter | Type | Description |
|---|---|---|
| Authorization | string | Bearer token API key required |
| lineId | integer | In the URL path: the line ID required |
| invoiceLineTypeId | integer | New line type optional |
| description | string | New description optional |
| quantity | decimal | New quantity or hours optional |
| chargeAmount | decimal | New unit price or rate optional |
Delete Line
Removes a line from its document. Part lines on a Work Order are returned to inventory automatically.
curl --location --request DELETE \
'https://www.roadbays.com/api/v1_Billing/lines/20871' \
--header 'Authorization: Bearer YOUR_API_KEY'
{ "ok": true, "lineId": 20871 }
| Parameter | Type | Description |
|---|---|---|
| Authorization | string | Bearer token API key required |
| lineId | integer | RoadBays line ID required |
Get Work Order PMs
Returns the preventive maintenance schedules that have been completed on a Work Order.
curl --location --request GET \
'https://www.roadbays.com/api/v1_Billing/9122/pm-schedules' \
--header 'Authorization: Bearer YOUR_API_KEY'
{
"workOrderDocumentId": 9122,
"selectedPmScheduleIds": [ 214, 215 ],
"history": [
{ "pmScheduleId": 214, "serviceDate": "2026-09-23T15:30:00", "mileageAtService": 145585, "notes": "Completed via API WO-1042" },
{ "pmScheduleId": 215, "serviceDate": "2026-09-23T15:30:00", "mileageAtService": 145585, "notes": "Completed via API WO-1042" }
]
}
| Parameter | Type | Description |
|---|---|---|
| Authorization | string | Bearer token API key required |
| workOrderDocumentId | integer | Work Order billing document ID required |
Complete PMs on a Work Order
Records that the Work Order serviced one or more PM schedules for its unit. Each schedule's last service date and mileage are updated, and its next due mileage or date is moved forward by the PM interval.
curl --location --request POST \
'https://www.roadbays.com/api/v1_Billing/9122/pm-schedules' \
--header 'Authorization: Bearer YOUR_API_KEY' \
--header 'Content-Type: application/json' \
--data '{ "pmScheduleIds": [214, 215] }'
{
"workOrderDocumentId": 9122,
"completedCount": 2,
"schedules": [
{ "pmScheduleId": 214, "lastServiceDate": "2026-09-23T15:30:00", "lastServiceOdometer": 145585, "nextDueDate": null, "nextDueMileage": 160585 },
{ "pmScheduleId": 215, "lastServiceDate": "2026-09-23T15:30:00", "lastServiceOdometer": 145585, "nextDueDate": "2026-12-22T15:30:00", "nextDueMileage": null }
]
}
| Parameter | Type | Description |
|---|---|---|
| Authorization | string | Bearer token API key required |
| workOrderDocumentId | integer | In the URL path: the Work Order billing document ID required |
| pmScheduleIds | integer[] | PM schedule IDs for the Work Order's unit required |
List Repair Reasons
Returns all repair reasons configured for your account. Use the returned id values when creating cases.
curl --location --request GET \
'https://www.roadbays.com/api/v1_RepairReasons' \
--header 'Authorization: Bearer YOUR_API_KEY'
[
{ "id": 11, "accountGUID": "b5b1032a-6336-4d51-c1z3-bad295795192", "inactive": 0, "dateCreated": "2021-08-20T11:01:30.07", "name": "Breakdown", "notes": null },
{ "id": 12, "accountGUID": "b5b1032a-6336-4d51-c1z3-bad295795192", "inactive": 0, "dateCreated": "2021-08-20T11:01:33.757", "name": "Driver Abuse", "notes": null },
{ "id": 13, "accountGUID": "b5b1032a-6336-4d51-c1z3-bad295795192", "inactive": 0, "dateCreated": "2021-08-20T11:01:37.433", "name": "Accident", "notes": null }
]
| Parameter | Type | Description |
|---|---|---|
| Authorization | string | Bearer token API key required |
List Users
Returns all users registered to your account. Use the returned id as the assignedUser value when creating cases.
curl --location --request GET \
'https://www.roadbays.com/api/v1_CustomerUsers' \
--header 'Authorization: Bearer YOUR_API_KEY'
[
{
"id": 81,
"accountGUID": "b5b1032a-6336-4d51-c1z3-bad295795192",
"inactive": 0,
"dateCreated": "2021-08-20T11:00:10",
"userTypesId": 2,
"email": "demo@roadbays.com",
"firstName": "Demo",
"lastName": "User"
}
]
| Parameter | Type | Description |
|---|---|---|
| Authorization | string | Bearer token API key required |
Get User
Returns a single user on your account by ID.
curl --location --request GET \
'https://www.roadbays.com/api/v1_CustomerUsers/81' \
--header 'Authorization: Bearer YOUR_API_KEY'
{
"id": 81,
"accountGUID": "b5b1032a-6336-4d51-c1z3-bad295795192",
"inactive": 0,
"dateCreated": "2021-08-20T11:00:10",
"userTypesId": 2,
"email": "demo@roadbays.com",
"firstName": "Demo",
"lastName": "User"
}
| Parameter | Type | Description |
|---|---|---|
| Authorization | string | Bearer token API key required |
| userId | integer | User ID from List Users required |
List Drivers
Returns all drivers registered to your account.
curl --location --request GET \
'https://www.roadbays.com/api/v1_Drivers' \
--header 'Authorization: Bearer YOUR_API_KEY'
[
{
"id": 1011,
"accountGUID": "b5b1032a-6336-4d51-c1z3-bad295795192",
"inactive": 0,
"dateCreated": "2022-02-21T05:32:48.15",
"firstName": "Demo",
"lastName": "User",
"email": "demo@roadbays.com",
"employeeId": "111111",
"balance": "1000",
"phone": "9203141144"
}
]
| Parameter | Type | Description |
|---|---|---|
| Authorization | string | Bearer token API key required |
Create Driver
Register a new driver to your RoadBays account. First name, last name, and email are required.
curl --location --request POST \
'https://www.roadbays.com/api/v1_Drivers' \
--header 'Authorization: Bearer YOUR_API_KEY' \
--header 'Content-Type: application/x-www-form-urlencoded' \
--data-urlencode 'firstName=Demo' \
--data-urlencode 'lastName=User' \
--data-urlencode 'email=demo@roadbays.com' \
--data-urlencode 'phone=9203141144' \
--data-urlencode 'employeeId=1111111' \
--data-urlencode 'balance=1000'
{
"id": 1011,
"accountGUID": "b5b1032a-6336-4d51-c1z3-bad295795192",
"inactive": 0,
"dateCreated": "2022-02-21T05:32:48.15",
"firstName": "Demo",
"lastName": "User",
"email": "demo@roadbays.com",
"employeeId": "111111",
"balance": "1000",
"phone": "9203141144"
}
| Parameter | Type | Description |
|---|---|---|
| Authorization | string | Bearer token API key required |
| firstName | string | Driver first name required |
| lastName | string | Driver last name required |
| string | Driver email address required | |
| phone | string | Phone number optional |
| employeeId | string | Internal employee identifier optional |
| balance | string | Account balance optional |
List Units
Returns all fleet assets (units) registered to your account.
curl --location --request GET \
'https://www.roadbays.com/api/v1_Units' \
--header 'Authorization: Bearer YOUR_API_KEY'
[
{
"id": 1030,
"dateCreated": "2021-08-20T11:04:50.503",
"inactive": 0,
"accountGUID": "b5b1032a-6336-4d51-c1z3-bad295795192",
"unitNumber": "3345",
"description": "Mack Truck",
"unitTypesId": 1014,
"serialNo": "1XAPDP9X0PD486131",
"engine": "MP8",
"engineManufacturer": "MACK",
"unitMake": "MACK",
"unitModel": "Anthem",
"modelYear": "2020"
}
]
| Parameter | Type | Description |
|---|---|---|
| Authorization | string | Bearer token API key required |
Get Unit
Retrieve full details for a single unit by its RoadBays system-generated ID.
curl --location --request GET \
'https://www.roadbays.com/api/v1_Units/1030' \
--header 'Authorization: Bearer YOUR_API_KEY'
{
"id": 1030,
"dateCreated": "2021-08-20T11:04:50.503",
"inactive": 0,
"accountGUID": "b5b1032a-6336-4d51-c1z3-bad295795192",
"unitNumber": "3345",
"description": "Mack Truck",
"unitTypesId": 1014,
"serialNo": "1XAPDP9X0PD486131",
"engine": "MP8",
"engineManufacturer": "MACK",
"unitMake": "MACK",
"unitModel": "Anthem",
"modelYear": "2020"
}
| Parameter | Type | Description |
|---|---|---|
| Authorization | string | Bearer token API key required |
| unitId | integer | RoadBays system-generated unit ID required |
Create Unit
Add a new fleet asset to your account. Vehicle specs are automatically decoded from the VIN via NHTSA.
curl --location --request POST \
'https://www.roadbays.com/api/v1_Units' \
--header 'Authorization: Bearer YOUR_API_KEY' \
--header 'Content-Type: application/x-www-form-urlencoded' \
--data-urlencode 'vin=1XPCEP6Y0JD486131' \
--data-urlencode 'unitNumber=12345' \
--data-urlencode 'unitTypeId=1001' \
--data-urlencode 'license=1XY23Z45'
{
"id": 1030,
"dateCreated": "2021-08-20T11:04:50.503",
"inactive": 0,
"accountGUID": "b5b1032a-6336-4d51-c1z3-bad295795192",
"unitNumber": "12345",
"unitTypesId": 1001,
"serialNo": "1XPCEP6Y0JD486131",
"license": "1XY23Z45",
"unitMake": "PETERBILT",
"unitModel": "389",
"modelYear": "2019"
}
| Parameter | Type | Description |
|---|---|---|
| Authorization | string | Bearer token API key required |
| vin | string | 17-character vehicle VIN required |
| unitTypeId | integer | RoadBays unit type ID required |
| unitNumber | string | Your internal unit/fleet number required |
| license | string | License plate number optional |
List Fault Codes
Returns every fault code recorded for a unit, by VIN.
curl --location --request GET \
'https://www.roadbays.com/api/v1_FaultCodes?serialNo=1XPCEP6Y0JD486131' \
--header 'Authorization: Bearer YOUR_API_KEY'
[
{
"id": 68139,
"externalId": "367423",
"dateCreated": "2022-03-21T15:15:09",
"inactive": 0,
"accountGUID": "b6b1032b-3150-4c51-2548-f7b3b7a8e9f70",
"unitsId": 3379,
"caseId": 5141,
"serialNo": "1XPCEP6Y0JD486131",
"code": "P1401",
"codeDescription": "Crankcase Air Pressure",
"source": "Crankcase",
"platform": "api",
"status": "open",
"firstObserved": "3/21/2022 3:15:09 PM",
"lastObserved": "3/21/2022 3:15:09 PM"
}
]
| Parameter | Type | Description |
|---|---|---|
| Authorization | string | Bearer token API key required |
| serialNo | string | VIN of the unit required |
Create Fault Code
Push DTC fault codes into RoadBays from your telematics provider. Codes are matched to the asset by VIN and linked to open cases automatically.
curl --location --request POST \
'https://www.roadbays.com/api/v1_FaultCodes' \
--header 'Authorization: Bearer YOUR_API_KEY' \
--header 'Content-Type: application/x-www-form-urlencoded' \
--data-urlencode 'vin=1XPCEP6Y0JD486131' \
--data-urlencode 'code=P1401' \
--data-urlencode 'codeDescription=Crankcase Air Pressure' \
--data-urlencode 'status=open' \
--data-urlencode 'source=Crankcase' \
--data-urlencode 'platform=api' \
--data-urlencode 'externalId=367423'
{
"id": 68139,
"externalId": "367423",
"dateCreated": "2022-03-21T15:15:09",
"inactive": 0,
"accountGUID": "b6b1032b-3150-4c51-2548-f7b3b7a8e9f70",
"units": null,
"unitsId": 3379,
"caseId": 5141,
"serialNo": "1XPCEP6Y0JD486131",
"code": "P1401",
"codeDescription": "Crankcase Air Pressure",
"source": "Crankcase",
"platform": "api",
"status": "open",
"firstObserved": "3/21/2022 3:15:09 PM",
"lastObserved": "3/21/2022 3:15:09 PM"
}
| Parameter | Type | Description |
|---|---|---|
| Authorization | string | Bearer token API key required |
| vin | string | VIN of the unit in RoadBays required |
| code | string | DTC fault code (e.g. P1401) required |
| codeDescription | string | Human-readable description of the code optional |
| platform | string | Label of originating platform (e.g. Samsara) optional |
| status | string | open or closed optional |
| source | string | Source bus or system of the code optional |
| externalId | string | Your external ID — use to update status later optional |
Update Fault Code
Update the status of an existing fault code. Identify the record using either the RoadBays internal id or the externalId assigned at creation. One of the two is required.
curl --location --request PUT \
'https://www.roadbays.com/api/v1_FaultCodes' \
--header 'Authorization: Bearer YOUR_API_KEY' \
--header 'Content-Type: application/x-www-form-urlencoded' \
--data-urlencode 'id=145585' \
--data-urlencode 'externalId=1455a58s45' \
--data-urlencode 'status=closed'
{
"id": 68139,
"externalId": "1455a58s45",
"dateCreated": "2022-03-21T15:15:09",
"inactive": 0,
"accountGUID": "b6b1032b-3150-4c51-2548-f7b3b7a8e9f70",
"unitsId": 3379,
"caseId": 5141,
"serialNo": "23TYG1EG0GFA91368",
"code": "P054A",
"codeDescription": "Cold Start B Camshaft Position Timing Over-Advanced Bank 1",
"source": "CANBUS_SECONDARY_PASSENGER_15765",
"platform": null,
"status": "closed",
"firstObserved": "3/20/2022 4:13:01 PM",
"lastObserved": "3/20/2022 4:13:01 PM"
}
| Parameter | Type | Description |
|---|---|---|
| Authorization | string | Bearer token API key required |
| id | integer | RoadBays internal fault code ID — required if no externalId |
| externalId | string | Your external ID — required if no id |
| status | string | Open or Closed required |
Update Mileage
Push updated mileage for a unit by VIN. The mileage value must be greater than the current recorded value to update correctly.
curl --location --request POST \
'https://www.roadbays.com/api/v1_Mileage' \
--header 'Authorization: Bearer YOUR_API_KEY' \
--header 'Content-Type: application/x-www-form-urlencoded' \
--data-urlencode 'vin=1XPCEP6Y0JD486131' \
--data-urlencode 'mileage=145585'
{
"id": 68139,
"dateCreated": "2022-03-21T15:15:09",
"inactive": 0,
"accountGUID": "b6b1032b-3150-4c51-2548-f7b3b7a8e9f70",
"unitsId": 3379,
"caseId": 0,
"serialNo": "1XPCEP6Y0JD486131",
"mileage": "145585"
}
| Parameter | Type | Description |
|---|---|---|
| Authorization | string | Bearer token API key required |
| vin | string | VIN of the unit to update required |
| mileage | string | Must be greater than current recorded mileage required |
List PM Schedules
Returns PM schedules with how many miles and days remain and a due status. Filter to one unit by vin or unitsId, or leave both out to see the whole fleet. Results are sorted with overdue items first.
curl --location --request GET \
'https://www.roadbays.com/api/v1_PmSchedules?vin=1XPBDP956AD486131&dueOnly=true' \
--header 'Authorization: Bearer YOUR_API_KEY'
[
{
"pmScheduleId": 214,
"unitsId": 1030,
"unitNumber": "3345",
"vin": "1XPBDP956AD486131",
"currentMileage": 159900,
"pmTaskId": 12,
"pmTaskName": "Oil & Filter Change",
"pmTaskDescription": "Engine oil, oil filter, fuel filters",
"intervalType": "Miles",
"intervalValue": 15000,
"lastServiceDate": "2026-06-02T14:20:00",
"lastServiceOdometer": 145585,
"nextDueDate": null,
"nextDueMileage": 160585,
"milesRemaining": 685,
"daysRemaining": null,
"status": "DueSoon"
}
]
| Parameter | Type | Description |
|---|---|---|
| Authorization | string | Bearer token API key required |
| vin | string | Only schedules for this unit optional |
| unitsId | integer | Only schedules for this unit; used instead of vin when both are sent optional |
| dueOnly | bool | Return only Overdue and DueSoon items; default false optional |
| dueSoonMiles | integer | Miles-before-due window for DueSoon; default 1000 optional |
| dueSoonDays | integer | Days-before-due window for DueSoon; default 14 optional |
List PM Tasks
Returns the PM task list for your account, including RoadBays system tasks, with each task's interval.
curl --location --request GET \
'https://www.roadbays.com/api/v1_PmSchedules/tasks' \
--header 'Authorization: Bearer YOUR_API_KEY'
[
{ "id": 12, "name": "Oil & Filter Change", "description": "Engine oil, oil filter, fuel filters", "intervalType": "Miles", "intervalValue": 15000, "systemTask": false },
{ "id": 3, "name": "DOT Annual Inspection", "description": null, "intervalType": "Days", "intervalValue": 365, "systemTask": true }
]
| Parameter | Type | Description |
|---|---|---|
| Authorization | string | Bearer token API key required |
Error Codes
The RoadBays API uses standard HTTP status codes. Errors return a JSON body with a message field describing the issue.
| Code | Meaning |
|---|---|
| 400 | Bad Request — A required parameter is missing or invalid. The message field explains what to fix. |
| 401 | Unauthorized — Verify your Bearer token is correct and included in the Authorization header. |
| 403 | Forbidden — Your API key is missing, invalid, or does not have permission to access this endpoint. |
| 404 | Not Found — The requested resource ID does not exist. Verify the ID and try again. |
| 429 | Too Many Requests. The rate limit has been exceeded. Pause and retry after the interval given in the Retry-After header. |
| 500 | Internal Server Error — An unexpected server error occurred. Please try again later. |
| 503 | Service Unavailable — The API is temporarily offline for maintenance. Please try again later. |