REST API v1
Programmatically manage vehicles, rig checks, users, checklists, inventory, and more. The UnitClear API uses standard REST conventions with JSON request and response bodies.
Base URL
https://www.unitclearems.com/api/v1Authentication
All API requests require an API key passed via the x-api-key header. API keys can be created from Dashboard → Billing → API Keys or via the POST /api/v1/api-keys endpoint.
curl https://www.unitclearems.com/api/v1/vehicles \ -H "x-api-key: uc_live_abc123..."
Pagination
List endpoints return paginated results. Use page and per_page query parameters (max 100 items per page).
{
"data": [...],
"meta": {
"page": 1,
"per_page": 25,
"total": 42,
"total_pages": 2
}
}API Keys
/api/v1/api-keysList all API keys for the organization. Full key is never shown again after creation.
Response
[ { id, name, key_prefix, role, created_by, last_used_at, expires_at, is_active, created_at } ]/api/v1/api-keysCreate a new API key. The full key is returned only on creation.
Request Body
- name (string, required)
- role (string, default: "manager")
- expires_in_days (number, optional)
Response
{ id, name, key, role, created_at }/api/v1/api-keys/:idDelete (revoke) an API key.
Vehicles
/api/v1/vehiclesList vehicles for the organization with pagination and filtering.
Query Parameters
- page (default: 1)
- per_page (default: 25, max: 100)
- status (green | yellow | red)
- in_service (true | false)
- on_shift (true | false)
- sort_by (rig_number | status | created_at | last_checked_at)
- order (asc | desc)
Response
{ data: [ { id, rig_number, unit_number, status, in_service, on_shift_since, lat, lng, ... } ], meta: { page, per_page, total, total_pages } }/api/v1/vehiclesCreate a new vehicle. Checks against subscription vehicle limits.
Request Body
- rig_number (string, required)
- unit_number (string, optional)
Response
{ id, rig_number, unit_number, status, ... }/api/v1/vehicles/:idGet a single vehicle by ID.
/api/v1/vehicles/:idUpdate vehicle fields.
Request Body
- rig_number (string)
- unit_number (string)
- in_service (boolean)
/api/v1/vehicles/:idDelete a vehicle. Returns 204 No Content.
/api/v1/vehicles/:id/statusUpdate vehicle status (green, yellow, red).
Request Body
- status (string, required: green | yellow | red)
/api/v1/vehicles/:id/shiftStart a shift on a vehicle.
/api/v1/vehicles/:id/shiftEnd a shift on a vehicle.
Rig Checks
/api/v1/rig-checksList rig checks with vehicle and user details.
Query Parameters
- page e
- per_page e
- vehicle_id d
- severity (green | yellow | red)
- emt_id d
- since (ISO date)
- until (ISO date)
Response
{ data: [ { id, vehicle_id, emt_id, damage_notes, ai_damage_severity, ai_analysis_notes, created_at, vehicles, users } ], meta }/api/v1/rig-checksSubmit a new rig check.
Request Body
- vehicle_id (string, required)
- checklist_id (string)
- answers (object)
- damage_notes (string)
- crew_last_name (string)
/api/v1/rig-checks/:idGet a single rig check by ID.
Users
/api/v1/usersList users in the organization. Requires manager role.
Query Parameters
- page e
- per_page e
- role e
Response
{ data: [ { id, username, email, first_name, last_name, role, created_at } ], meta }/api/v1/usersCreate a new user. Returns a temporary password.
Request Body
- first_name (string, required)
- last_name (string, required)
- role (string, required: emt | paramedic | nurse | manager | director)
- recovery_email (string, optional)
Response
{ id, username, role, temp_password }/api/v1/users/:idGet a single user by ID.
/api/v1/users/:idUpdate user fields.
Request Body
- first_name (string)
- last_name (string)
- role (string)
- recovery_email (string)
/api/v1/users/:idDelete a user.
/api/v1/users/:id/reset-passwordReset a user's password. Returns the new temporary password.
Response
{ temp_password }Checklists
/api/v1/checklistsList checklists. By default returns only active checklists.
Query Parameters
- active (default: true)
- vehicle_id d
/api/v1/checklistsCreate a checklist.
Request Body
- title (string, required)
- categories (array, required)
- vehicle_ids (array, optional)
- description (string)
- restock_items (array)
/api/v1/checklists/:idGet a single checklist by ID.
/api/v1/checklists/:idUpdate a checklist.
Request Body
- title (string)
- categories (array)
- vehicle_ids (array)
- is_active (boolean)
/api/v1/checklists/:idDelete a checklist.
Inventory
/api/v1/inventoryList inventory items with optional filters.
Query Parameters
- category y
- low_stock (true | false)
/api/v1/inventoryAdd an inventory item.
Request Body
- name (string, required)
- category (string, default: "General")
- unit (string, default: "unit")
- quantity (number, default: 0)
- low_threshold (number)
- critical_threshold (number)
/api/v1/inventory/:idGet a single inventory item.
/api/v1/inventory/:idUpdate an inventory item.
/api/v1/inventory/:idDelete an inventory item.
/api/v1/inventory/takeRecord an inventory take (consume items).
Request Body
- item_id (string, required)
- quantity (number, required)
/api/v1/inventory/:id/restockRestock an inventory item.
Request Body
- quantity (number, required)
/api/v1/inventory/transactionsList inventory transactions (takes and restocks).
Notifications
/api/v1/notificationsList notifications for the current user/org.
Query Parameters
- page e
- per_page e
- unread (true | false)
/api/v1/notifications/readMark specific notifications as read.
Request Body
- ids (array of strings, required)
/api/v1/notifications/read-allMark all notifications as read.
Map Points
/api/v1/map-pointsList map points (stations, hospitals, landmarks).
Query Parameters
- type (hospital | station | landmark | ...)
/api/v1/map-pointsCreate a map point.
Request Body
- name (string, required)
- type (string, required)
- lat (number, required)
- lng (number, required)
- description (string)
/api/v1/map-points/:idUpdate a map point.
/api/v1/map-points/:idDelete a map point.
Shift Issues
/api/v1/shift-issuesList shift issues. Requires manager role.
Query Parameters
- page e
- per_page e
- status (pending | approved | rejected)
- vehicle_id d
- severity y
/api/v1/shift-issuesReport a shift issue.
Request Body
- vehicle_id (string, required)
- category (string, required)
- description (string, required)
- rig_check_id (string)
- fuel_level (string)
/api/v1/shift-issues/:id/reviewReview (approve/reject) a shift issue.
Request Body
- action (string, required: approve | reject)
- notes (string)
Shift Reports
/api/v1/shift-reportsList end-of-shift reports. Requires manager role.
Query Parameters
- page e
- per_page e
- vehicle_id d
- emt_id d
- since (ISO date)
- until (ISO date)
/api/v1/shift-reports/:idGet a single shift report by ID.
Organization
/api/v1/organizationGet current organization details with user and vehicle counts.
Response
{ id, name, display_name, slug, subscription_status, user_count, vehicle_count, subscription }/api/v1/organization/brandingUpdate organization branding settings.
Request Body
- display_name (string)
- primary_color (string)
- accent_color (string)
/api/v1/organization/logoUpload organization logo. Send as multipart/form-data.
Request Body
- logo (File, required)
Audit Log
/api/v1/audit-logList audit log entries. Requires director role.
Query Parameters
- page e
- per_page e
- action n
- target_type e
- actor_id d
- since (ISO date)
- until (ISO date)
Response
{ data: [ { id, action, target_type, target_id, actor_id, actor_name, changes, created_at } ], meta }Admin (super_admin)
/api/v1/admin/statsGet platform-wide statistics. Requires super_admin role.
/api/v1/admin/organizationsList all organizations on the platform.
/api/v1/admin/organizations/:idGet details for a specific organization.
/api/v1/admin/organizations/:idUpdate an organization (subscription, status, etc.).
Rate Limiting
API requests are rate limited to prevent abuse. If you receive a 429 status, wait before retrying. Rate limits are applied per API key.
UnitClear — Digital Rig Checks for EMS & Fire
Home · Pricing · Get Started