Skip to content

Get work report settings

GET
/work-report/settings
curl --request GET \
--url https://example.com/work-report/settings \
--cookie __Host-bottle.session_token=<__Host-bottle.session_token>

Whether work reports are on, who they are emailed to, which stops get one, the next report number, what the customer agrees to and what the driver must record. The first time any business reads this, Bottle adds the starting job types (Install, Refill, Return, Service) and checks (Condition, Gauge, Leaks) and saves the settings with their defaults. This happens once; removing them later does not bring them back.

The settings

Media typeapplication/json
object
enabled
required
boolean
emailTo
required

Main_contact: the customer’s main contact. everyone: every contact on the account. ask_driver: the driver picks at the stop.

string
Allowed values: main_contact everyone ask_driver
sendAfter
required

Tracked: stops where a tracked cylinder is delivered or collected. every: every stop.

string
Allowed values: tracked every
nextNumber
required
integer
>= 1
acknowledgement
required
Array<string>
mustRecord
required
object
cylinderDetails
required
boolean
allChecks
required
boolean
customerSignature
required
boolean
driverSignature
required
boolean
purchaseOrder
required
boolean

Example

{
"emailTo": "main_contact",
"sendAfter": "tracked"
}

Not signed in

Media typeapplication/json
object
error
required
string
message
required
string

Example

{
"error": "not_found",
"message": "Customer not found"
}

Not an owner or admin, or the plan does not open Assets

Media typeapplication/json
object
error
required
string
message
required
string

Example

{
"error": "not_found",
"message": "Customer not found"
}

Not found, or Assets is not available to this business

Media typeapplication/json
object
error
required
string
message
required
string

Example

{
"error": "not_found",
"message": "Customer not found"
}

Assets is switched off, or the business already has 50 job types or checks

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
Allowed values: validation
message
required
string
issues
required
Array<object>
object
path
required
string
message
required
string

Example

{
"error": "validation",
"issues": [
{
"path": "email",
"message": "Invalid email"
}
]
}