v1 Resource Matrix
| Resource | Collection | Item | Required scopes |
|---|---|---|---|
| Vehicles | GET, POST | GET, PUT, DELETE | vehicles:read, vehicles:write |
| Vehicle Fields | GET | GET /vehicle-fields/{id}/vehicles | vehicle-fields:read |
| Vehicle Groups | GET, POST | GET, PUT, DELETE | vehicle-groups:read, vehicle-groups:write |
| Inspection Templates | GET, POST | GET, PUT, DELETE | inspection-templates:read, inspection-templates:write |
| Inspections | GET, POST | GET, PATCH, DELETE | inspections:read, inspections:write |
| Damages | GET, POST | GET, PUT, DELETE | damages:read, damages:write |
| Driver Assignments | GET, POST | GET, PATCH, DELETE | driver-assignments:read, driver-assignments:write |
Legacy Compatibility
The original v1 coarse scopes still work:vehicles:readalso covers read access forvehicle-groups,damages, anddriver-assignmentsvehicles:readalso covers read access forvehicle-fieldsvehicles:writealso covers write access for those resourcesinspections:readalso covers read access forinspection-templatesinspections:writealso covers write access forinspection-templates
Delete Semantics
| Resource | Delete behavior |
|---|---|
| Vehicles | Soft-delete. Subsequent reads reflect the deleted state. |
| Vehicle Groups | Hard-delete, but only after the group is empty. |
| Inspection Templates | Hard-delete. Use force=true when the template already has inspections. |
| Inspections | Hard-delete. Intended for correction and rollback flows. |
| Damages | Hard-delete. Prefer status updates for ordinary repair lifecycle changes. |
| Driver Assignments | Release transition. DELETE records returnedAt and preserves history. |
Notes
- Every collection route supports
pageandlimit. - Every mutation route validates company scope before it writes.
- All responses use the standard
data,meta, anderrorsenvelope.