subs.view
The subcontractor's page for one job: the shop, job summary, work address, scope note, upcoming visit times and their notes. state is ok, gone (removed, expired, job cancelled or shop closed) or wrong_person (signed in with a different email, or someone else opened it first). Opening it the first time binds it to you. Hosted page only.
When to use it
The subcontractor's page for one job: the shop, job summary, work address, scope note, upcoming visit times and their notes. state is ok, gone (removed, expired, job cancelled or shop closed) or wrong_person (signed in with a different email, or someone else opened it first).
What to tell the owner
Send the person the link. They finish this step themselves on the page; you never do it for them.
| Field | Type | Required |
|---|
k | string | yes |
Example
GET https://doingwork.work/v1/subs/view?k=...
Output
| Field | Type | Always there |
|---|
state | string | yes |
subcontractor_id | string (uuid) | no |
job_id | string (uuid) | no |
shop | string | no |
company_name | string | no |
trade | ['string', 'null'] | no |
scope_note | ['string', 'null'] | no |
summary | ['string', 'null'] | no |
job_status | string | no |
address | string | no |
time_zone | string | no |
expires_at | string (date-time) | no |
visits | array | no |
visits[].visit_id | string (uuid) | yes |
visits[].title | ['string', 'null'] | yes |
visits[].starts_at | string (date-time) | yes |
visits[].ends_at | string (date-time) | yes |
notes | array | no |
notes[].note_id | string (uuid) | yes |
notes[].body | string | yes |
notes[].created_at | string (date-time) | yes |
{
"state": "..."
}
Errors
| Code | Status | What to do |
|---|
invalid_input, invalid_token, rate_limited | | Can happen on any call. See errors. |