Add work to a vehicle service history
POST
/vehicles/{id}/maintenance
const url = 'https://example.com/vehicles/019205d1-6e7a-7c3b-9f6e-3a2b1c0d9e8f/maintenance';const options = { method: 'POST', headers: { cookie: '__Host-bottle.session_token=<__Host-bottle.session_token>', 'Content-Type': 'application/json' }, body: '{"kind":"service","title":"example","performedOn":"2026-04-15","mileage":1,"costPence":1,"provider":"example","notes":"example","nextDueOn":"2026-04-15","nextDueMileage":1,"lineItems":[{"description":"example","quantity":1,"amountPence":1}]}'};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request POST \ --url https://example.com/vehicles/019205d1-6e7a-7c3b-9f6e-3a2b1c0d9e8f/maintenance \ --header 'Content-Type: application/json' \ --cookie __Host-bottle.session_token=<__Host-bottle.session_token> \ --data '{ "kind": "service", "title": "example", "performedOn": "2026-04-15", "mileage": 1, "costPence": 1, "provider": "example", "notes": "example", "nextDueOn": "2026-04-15", "nextDueMileage": 1, "lineItems": [ { "description": "example", "quantity": 1, "amountPence": 1 } ] }'Authorizations
Section titled “Authorizations”Parameters
Section titled “Parameters”Path Parameters
Section titled “Path Parameters”id
required
UUID v7
string format: uuid
Example
019205d1-6e7a-7c3b-9f6e-3a2b1c0d9e8fUUID v7
Request Bodyrequired
Section titled “Request Bodyrequired”Media typeapplication/json
object
kind
required
string
title
required
string
performedOn
required
string format: date
mileage
integer | null
costPence
integer | null
provider
string | null
notes
string | null
nextDueOn
string | null format: date
nextDueMileage
integer | null
lineItems
Array<object>
object
description
required
string
quantity
required
number | null
amountPence
required
integer | null
Responses
Section titled “Responses”Recorded
Media typeapplication/json
object
id
required
UUID v7
string format: uuid
vehicleId
required
UUID v7
string format: uuid
kind
required
string
title
required
string
performedOn
required
string format: date
mileage
required
integer | null
costPence
required
integer | null
provider
required
string | null
notes
required
string | null
nextDueOn
required
string | null format: date
nextDueMileage
required
integer | null
lineItems
required
Array<object>
object
description
required
string
quantity
required
number | null
amountPence
required
integer | null
createdAt
required
string format: date-time
updatedAt
required
string format: date-time
Example
{ "id": "019205d1-6e7a-7c3b-9f6e-3a2b1c0d9e8f", "vehicleId": "019205d1-6e7a-7c3b-9f6e-3a2b1c0d9e8f", "kind": "service"}Not signed in
Media typeapplication/json
object
error
required
string
message
required
string
Example
{ "error": "not_found", "message": "Customer not found"}Not a member, or without the permission this needs
Media typeapplication/json
object
error
required
string
message
required
string
Example
{ "error": "not_found", "message": "Customer not found"}No such vehicle or record
Media typeapplication/json
object
error
required
string
message
required
string
Example
{ "error": "not_found", "message": "Customer not found"}Validation failed
Media typeapplication/json
object
error
required
string
message
required
string
issues
required
Array<object>
object
path
required
string
message
required
string
Example
{ "error": "validation", "issues": [ { "path": "email", "message": "Invalid email" } ]}