{"openapi":"3.1.0","info":{"title":"Estimark API","version":"1.0.0","description":"The public Estimark API.\n\n**Authentication.** Send your key in an `X-API-Key` header. Create and revoke keys in Settings → API. Keys are scoped to one company and carry read or write scopes.\n\n**Rate limits.** Requests are limited per key. A `429` means slow down; retry after a short delay rather than immediately.\n\n**Errors.** Failures return a JSON body with a `detail` field. A `422` carries a list of per-field validation problems.\n\n**Webhooks.** Rather than polling, register an endpoint and receive events. Every delivery is signed with HMAC-SHA256 over `timestamp.body` in an `X-Estimark-Signature` header — verify it before trusting the payload.","contact":{"name":"Estimark","url":"https://estimark.co.uk"}},"servers":[{"url":"https://api.estimark.co.uk","description":"Production"}],"paths":{"/api/v1/status":{"get":{"tags":["Status","Status"],"summary":"Public Status","operationId":"public_status_api_v1_status_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/StatusResponse"}}}}}}},"/api/v1/clients":{"get":{"tags":["Clients"],"summary":"List Clients","operationId":"list_clients_api_v1_clients_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"page","in":"query","required":false,"schema":{"type":"integer","minimum":1,"default":1,"title":"Page"}},{"name":"per_page","in":"query","required":false,"schema":{"type":"integer","maximum":100,"minimum":1,"default":20,"title":"Per Page"}},{"name":"include_archived","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Include Archived"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PaginatedResponse_ClientResponse_"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["Clients"],"summary":"Create Client","operationId":"create_client_api_v1_clients_post","security":[{"HTTPBearer":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ClientCreateRequest"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ClientResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/clients/bulk":{"post":{"tags":["Clients"],"summary":"Bulk Clients","operationId":"bulk_clients_api_v1_clients_bulk_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BulkRequest"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/app__schemas__common__MessageResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"HTTPBearer":[]}]}},"/api/v1/clients/{client_id}":{"get":{"tags":["Clients"],"summary":"Get Client","operationId":"get_client_api_v1_clients__client_id__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"client_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Client Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ClientResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"patch":{"tags":["Clients"],"summary":"Update Client","operationId":"update_client_api_v1_clients__client_id__patch","security":[{"HTTPBearer":[]}],"parameters":[{"name":"client_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Client Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ClientUpdateRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ClientResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["Clients"],"summary":"Delete Client","operationId":"delete_client_api_v1_clients__client_id__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"client_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Client Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/app__schemas__common__MessageResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/clients/{client_id}/contacts":{"get":{"tags":["Client Contacts"],"summary":"List Contacts","operationId":"list_contacts_api_v1_clients__client_id__contacts_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"client_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Client Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/ClientContactResponse"},"title":"Response List Contacts Api V1 Clients  Client Id  Contacts Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["Client Contacts"],"summary":"Create Contact","operationId":"create_contact_api_v1_clients__client_id__contacts_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"client_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Client Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ClientContactCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ClientContactResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/clients/{client_id}/contacts/{contact_id}":{"patch":{"tags":["Client Contacts"],"summary":"Update Contact","operationId":"update_contact_api_v1_clients__client_id__contacts__contact_id__patch","security":[{"HTTPBearer":[]}],"parameters":[{"name":"client_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Client Id"}},{"name":"contact_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Contact Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ClientContactUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ClientContactResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["Client Contacts"],"summary":"Delete Contact","operationId":"delete_contact_api_v1_clients__client_id__contacts__contact_id__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"client_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Client Id"}},{"name":"contact_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Contact Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/app__schemas__common__MessageResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/clients/{client_id}/interactions":{"get":{"tags":["Client Contacts"],"summary":"List Interactions","operationId":"list_interactions_api_v1_clients__client_id__interactions_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"client_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Client Id"}},{"name":"page","in":"query","required":false,"schema":{"type":"integer","minimum":1,"default":1,"title":"Page"}},{"name":"per_page","in":"query","required":false,"schema":{"type":"integer","maximum":100,"minimum":1,"default":20,"title":"Per Page"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PaginatedResponse_ClientInteractionResponse_"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["Client Contacts"],"summary":"Log Interaction","operationId":"log_interaction_api_v1_clients__client_id__interactions_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"client_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Client Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ClientInteractionCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ClientInteractionResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/clients/{client_id}/interactions/{iact_id}":{"delete":{"tags":["Client Contacts"],"summary":"Delete Interaction","operationId":"delete_interaction_api_v1_clients__client_id__interactions__iact_id__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"client_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Client Id"}},{"name":"iact_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Iact Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/app__schemas__common__MessageResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/clients/{client_id}/sites":{"get":{"tags":["Client Sites"],"summary":"List Sites","operationId":"list_sites_api_v1_clients__client_id__sites_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"client_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Client Id"}},{"name":"active_only","in":"query","required":false,"schema":{"type":"boolean","default":true,"title":"Active Only"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/ClientSiteResponse"},"title":"Response List Sites Api V1 Clients  Client Id  Sites Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["Client Sites"],"summary":"Create Site","operationId":"create_site_api_v1_clients__client_id__sites_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"client_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Client Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ClientSiteCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ClientSiteResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/clients/{client_id}/sites/{site_id}":{"get":{"tags":["Client Sites"],"summary":"Get Site","operationId":"get_site_api_v1_clients__client_id__sites__site_id__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"client_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Client Id"}},{"name":"site_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Site Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ClientSiteResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"patch":{"tags":["Client Sites"],"summary":"Update Site","operationId":"update_site_api_v1_clients__client_id__sites__site_id__patch","security":[{"HTTPBearer":[]}],"parameters":[{"name":"client_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Client Id"}},{"name":"site_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Site Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ClientSiteUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ClientSiteResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["Client Sites"],"summary":"Delete Site","operationId":"delete_site_api_v1_clients__client_id__sites__site_id__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"client_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Client Id"}},{"name":"site_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Site Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/app__schemas__common__MessageResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/clients/{client_id}/sites/{site_id}/jobs":{"get":{"tags":["Client Sites"],"summary":"List Site Jobs","operationId":"list_site_jobs_api_v1_clients__client_id__sites__site_id__jobs_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"client_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Client Id"}},{"name":"site_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Site Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/ClientSiteJobSummary"},"title":"Response List Site Jobs Api V1 Clients  Client Id  Sites  Site Id  Jobs Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/tenders":{"get":{"tags":["Tenders"],"summary":"List Tenders","operationId":"list_tenders_api_v1_tenders_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"page","in":"query","required":false,"schema":{"type":"integer","minimum":1,"default":1,"title":"Page"}},{"name":"per_page","in":"query","required":false,"schema":{"type":"integer","maximum":100,"minimum":1,"default":20,"title":"Per Page"}},{"name":"status","in":"query","required":false,"schema":{"anyOf":[{"$ref":"#/components/schemas/TenderStatus"},{"type":"null"}],"title":"Status"}},{"name":"include_archived","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Include Archived"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PaginatedResponse_TenderResponse_"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["Tenders"],"summary":"Create Tender","operationId":"create_tender_api_v1_tenders_post","security":[{"HTTPBearer":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/TenderCreateRequest"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TenderResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/tenders/bulk":{"post":{"tags":["Tenders"],"summary":"Bulk Tenders","operationId":"bulk_tenders_api_v1_tenders_bulk_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BulkRequest"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/app__schemas__common__MessageResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"HTTPBearer":[]}]}},"/api/v1/tenders/{tender_id}":{"get":{"tags":["Tenders"],"summary":"Get Tender","operationId":"get_tender_api_v1_tenders__tender_id__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"tender_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Tender Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TenderResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"patch":{"tags":["Tenders"],"summary":"Update Tender","operationId":"update_tender_api_v1_tenders__tender_id__patch","security":[{"HTTPBearer":[]}],"parameters":[{"name":"tender_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Tender Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/TenderUpdateRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TenderResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["Tenders"],"summary":"Delete Tender","operationId":"delete_tender_api_v1_tenders__tender_id__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"tender_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Tender Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/app__schemas__common__MessageResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/tenders/{tender_id}/submit":{"post":{"tags":["Tenders"],"summary":"Submit Tender","operationId":"submit_tender_api_v1_tenders__tender_id__submit_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"tender_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Tender Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TenderResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/tenders/{tender_id}/bid-score":{"get":{"tags":["Tenders"],"summary":"Get Bid Score","operationId":"get_bid_score_api_v1_tenders__tender_id__bid_score_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"tender_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Tender Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["Tenders"],"summary":"Upsert Bid Score","operationId":"upsert_bid_score_api_v1_tenders__tender_id__bid_score_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"tender_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Tender Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BidScoreBody"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["Tenders"],"summary":"Delete Bid Score","operationId":"delete_bid_score_api_v1_tenders__tender_id__bid_score_delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"tender_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Tender Id"}}],"responses":{"204":{"description":"Successful Response"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/quotes":{"get":{"tags":["Quotes"],"summary":"List Quotes","operationId":"list_quotes_api_v1_quotes_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"page","in":"query","required":false,"schema":{"type":"integer","minimum":1,"default":1,"title":"Page"}},{"name":"per_page","in":"query","required":false,"schema":{"type":"integer","maximum":100,"minimum":1,"default":20,"title":"Per Page"}},{"name":"include_archived","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Include Archived"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PaginatedResponse_QuoteResponse_"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["Quotes"],"summary":"Create Quote","operationId":"create_quote_api_v1_quotes_post","security":[{"HTTPBearer":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/QuoteCreateRequest"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/QuoteResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/quotes/bulk":{"post":{"tags":["Quotes"],"summary":"Bulk Quotes","operationId":"bulk_quotes_api_v1_quotes_bulk_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BulkRequest"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/app__schemas__common__MessageResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"HTTPBearer":[]}]}},"/api/v1/quotes/{quote_id}":{"get":{"tags":["Quotes"],"summary":"Get Quote","operationId":"get_quote_api_v1_quotes__quote_id__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"quote_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Quote Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/QuoteResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"patch":{"tags":["Quotes"],"summary":"Update Quote","operationId":"update_quote_api_v1_quotes__quote_id__patch","security":[{"HTTPBearer":[]}],"parameters":[{"name":"quote_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Quote Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/QuoteUpdateRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/QuoteResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["Quotes"],"summary":"Delete Quote","operationId":"delete_quote_api_v1_quotes__quote_id__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"quote_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Quote Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/app__schemas__common__MessageResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/quotes/{quote_id}/pdf":{"get":{"tags":["Quotes"],"summary":"Quote Pdf","description":"Branded quotation PDF — the document the customer actually receives.","operationId":"quote_pdf_api_v1_quotes__quote_id__pdf_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"quote_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Quote Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/quotes/{quote_id}/send":{"post":{"tags":["Quotes"],"summary":"Send Quote","operationId":"send_quote_api_v1_quotes__quote_id__send_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"quote_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Quote Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/QuoteResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/quotes/{quote_id}/accept":{"post":{"tags":["Quotes"],"summary":"Accept Quote","operationId":"accept_quote_api_v1_quotes__quote_id__accept_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"quote_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Quote Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/QuoteResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/quotes/{quote_id}/convert-to-job":{"post":{"tags":["Quotes"],"summary":"Convert To Job","operationId":"convert_to_job_api_v1_quotes__quote_id__convert_to_job_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"quote_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Quote Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JobResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/quotes/{quote_id}/portal-link":{"post":{"tags":["Quotes"],"summary":"Get Portal Link","description":"Generate (or regenerate) a public portal link for the quote.","operationId":"get_portal_link_api_v1_quotes__quote_id__portal_link_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"quote_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Quote Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PortalLinkResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["Quotes"],"summary":"Revoke Portal Link","description":"Revoke the active portal link for the quote.","operationId":"revoke_portal_link_api_v1_quotes__quote_id__portal_link_delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"quote_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Quote Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/app__schemas__common__MessageResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/quotes/{quote_id}/send-portal":{"post":{"tags":["Quotes"],"summary":"Send Portal Link","description":"Generate portal link and email it to the client.","operationId":"send_portal_link_api_v1_quotes__quote_id__send_portal_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"quote_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Quote Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PortalLinkResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/quotes/ai-generate":{"post":{"tags":["Quotes"],"summary":"Ai Generate Quote","description":"Generate quote line items from BoQ text or uploaded PDF.","operationId":"ai_generate_quote_api_v1_quotes_ai_generate_post","requestBody":{"content":{"multipart/form-data":{"schema":{"$ref":"#/components/schemas/Body_ai_generate_quote_api_v1_quotes_ai_generate_post"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Ai Generate Quote Api V1 Quotes Ai Generate Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"HTTPBearer":[]}]}},"/api/v1/quotes/{quote_id}/options":{"put":{"tags":["Quotes"],"summary":"Select Quote Options","description":"Set which optional lines are in. The customer usually does this in the portal, but\na rep taking the decision over the phone needs the same lever.","operationId":"select_quote_options_api_v1_quotes__quote_id__options_put","security":[{"HTTPBearer":[]}],"parameters":[{"name":"quote_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Quote Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/QuoteOptionSelection"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/QuoteResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/quotes/{quote_id}/deposit-invoice":{"post":{"tags":["Quotes"],"summary":"Raise Deposit Invoice","description":"Raise the deposit invoice for an accepted quote.\n\nA deposit here means an invoice the customer owes and the contractor records payment\nagainst — not a card charge. Customer-facing collection is switched off for launch,\nand money would settle into Estimark's account rather than the contractor's.","operationId":"raise_deposit_invoice_api_v1_quotes__quote_id__deposit_invoice_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"quote_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Quote Id"}}],"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DepositInvoiceResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/quotes/personalisation/hints":{"get":{"tags":["Quotes"],"summary":"Get Estimate Hints","description":"Return personalisation hints based on company profile.\n\n- Regional labour cost uplift recommendation\n- CIS deduction note if registered\n- Warning if estimate exceeds typical project value","operationId":"get_estimate_hints_api_v1_quotes_personalisation_hints_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"estimate_total","in":"query","required":false,"schema":{"type":"number","description":"Current estimate total in pence","default":0,"title":"Estimate Total"},"description":"Current estimate total in pence"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/jobs":{"get":{"tags":["Jobs"],"summary":"List Jobs","operationId":"list_jobs_api_v1_jobs_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"page","in":"query","required":false,"schema":{"type":"integer","minimum":1,"default":1,"title":"Page"}},{"name":"per_page","in":"query","required":false,"schema":{"type":"integer","maximum":100,"minimum":1,"default":20,"title":"Per Page"}},{"name":"status","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Status"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PaginatedResponse_JobResponse_"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["Jobs"],"summary":"Create Job","operationId":"create_job_api_v1_jobs_post","security":[{"HTTPBearer":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/JobCreateRequest"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JobResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/jobs/calendar":{"get":{"tags":["Jobs"],"summary":"Calendar Jobs","operationId":"calendar_jobs_api_v1_jobs_calendar_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"from_date","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"From Date"}},{"name":"to_date","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"To Date"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/CalendarJobResponse"},"title":"Response Calendar Jobs Api V1 Jobs Calendar Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/jobs/gantt":{"get":{"tags":["Jobs"],"summary":"Gantt Jobs","description":"Return all non-cancelled jobs with start dates, including milestones, for Gantt chart.","operationId":"gantt_jobs_api_v1_jobs_gantt_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"items":{"$ref":"#/components/schemas/GanttJobResponse"},"type":"array","title":"Response Gantt Jobs Api V1 Jobs Gantt Get"}}}}},"security":[{"HTTPBearer":[]}]}},"/api/v1/jobs/map-data":{"get":{"tags":["Jobs"],"summary":"Jobs Map Data","description":"Pins for the live project map.\n\nJobs that carry a postcode but no coordinates are geocoded once (postcodes.io) and\nthe result is persisted, so the map fills in as addresses are added without\nrequiring a manual backfill.","operationId":"jobs_map_data_api_v1_jobs_map_data_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"include_closed","in":"query","required":false,"schema":{"type":"boolean","description":"Include complete/invoiced/cancelled jobs","default":false,"title":"Include Closed"},"description":"Include complete/invoiced/cancelled jobs"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JobMapResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/jobs/bulk":{"post":{"tags":["Jobs"],"summary":"Bulk Jobs","operationId":"bulk_jobs_api_v1_jobs_bulk_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BulkRequest"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/app__schemas__common__MessageResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"HTTPBearer":[]}]}},"/api/v1/jobs/{job_id}":{"get":{"tags":["Jobs"],"summary":"Get Job","operationId":"get_job_api_v1_jobs__job_id__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"job_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Job Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JobResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"patch":{"tags":["Jobs"],"summary":"Update Job","operationId":"update_job_api_v1_jobs__job_id__patch","security":[{"HTTPBearer":[]}],"parameters":[{"name":"job_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Job Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/JobUpdateRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JobResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["Jobs"],"summary":"Delete Job","operationId":"delete_job_api_v1_jobs__job_id__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"job_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Job Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/app__schemas__common__MessageResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/jobs/{job_id}/budget-vs-actual":{"get":{"tags":["Jobs"],"summary":"Get Budget Vs Actual","description":"Return budget vs actual cost breakdown for a job.\n\nEvery figure comes from `app.services.cost_service`. This route previously summed a\ncolumn that does not exist on the model (`PurchaseOrder.amount_total`) and would have\nraised on any job with a purchase order.","operationId":"get_budget_vs_actual_api_v1_jobs__job_id__budget_vs_actual_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"job_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Job Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/jobs/{job_id}/recurrence":{"patch":{"tags":["Jobs"],"summary":"Set Job Recurrence","description":"Set or clear recurring schedule for a job template.","operationId":"set_job_recurrence_api_v1_jobs__job_id__recurrence_patch","security":[{"HTTPBearer":[]}],"parameters":[{"name":"job_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Job Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","title":"Body"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/jobs/{job_id}/analyse-risk":{"post":{"tags":["Jobs"],"summary":"Analyse Job Risk","description":"Run AI risk analysis on a job.","operationId":"analyse_job_risk_api_v1_jobs__job_id__analyse_risk_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"job_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Job Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/jobs/{job_id}/status":{"patch":{"tags":["Jobs"],"summary":"Set Job Status","description":"Set a job's board status directly (used by the kanban drag-and-drop and the\ninline status dropdown). Free movement between pending/active/on_hold/complete;\n'invoiced' is not settable here — it is reached via POST /jobs/{id}/invoice,\nwhich also generates the invoice.","operationId":"set_job_status_api_v1_jobs__job_id__status_patch","security":[{"HTTPBearer":[]}],"parameters":[{"name":"job_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Job Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/JobStatusUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JobResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/jobs/{job_id}/reschedule":{"patch":{"tags":["Jobs"],"summary":"Reschedule Job","operationId":"reschedule_job_api_v1_jobs__job_id__reschedule_patch","security":[{"HTTPBearer":[]}],"parameters":[{"name":"job_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Job Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RescheduleRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JobResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/jobs/{job_id}/start":{"post":{"tags":["Jobs"],"summary":"Start Job","operationId":"start_job_api_v1_jobs__job_id__start_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"job_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Job Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JobResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/jobs/{job_id}/complete":{"post":{"tags":["Jobs"],"summary":"Complete Job","operationId":"complete_job_api_v1_jobs__job_id__complete_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"job_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Job Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JobResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/jobs/{job_id}/invoice":{"post":{"tags":["Jobs"],"summary":"Invoice Job","operationId":"invoice_job_api_v1_jobs__job_id__invoice_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"job_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Job Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JobResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/jobs/{job_id}/workers":{"get":{"tags":["Jobs"],"summary":"List Job Workers","operationId":"list_job_workers_api_v1_jobs__job_id__workers_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"job_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Job Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/app__api__v1__jobs__WorkerResponse"},"title":"Response List Job Workers Api V1 Jobs  Job Id  Workers Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["Jobs"],"summary":"Assign Worker","operationId":"assign_worker_api_v1_jobs__job_id__workers_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"job_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Job Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/WorkerAssignRequest"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/app__schemas__common__MessageResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/jobs/{job_id}/workers/{worker_user_id}":{"delete":{"tags":["Jobs"],"summary":"Remove Worker","operationId":"remove_worker_api_v1_jobs__job_id__workers__worker_user_id__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"job_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Job Id"}},{"name":"worker_user_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Worker User Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/app__schemas__common__MessageResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/jobs/{job_id}/milestones":{"get":{"tags":["Jobs"],"summary":"List Milestones","operationId":"list_milestones_api_v1_jobs__job_id__milestones_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"job_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Job Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/MilestoneResponse"},"title":"Response List Milestones Api V1 Jobs  Job Id  Milestones Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["Jobs"],"summary":"Create Milestone","operationId":"create_milestone_api_v1_jobs__job_id__milestones_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"job_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Job Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/MilestoneCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/MilestoneResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/jobs/{job_id}/milestones/{milestone_id}":{"patch":{"tags":["Jobs"],"summary":"Update Milestone","operationId":"update_milestone_api_v1_jobs__job_id__milestones__milestone_id__patch","security":[{"HTTPBearer":[]}],"parameters":[{"name":"job_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Job Id"}},{"name":"milestone_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Milestone Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/MilestoneUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/MilestoneResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["Jobs"],"summary":"Delete Milestone","operationId":"delete_milestone_api_v1_jobs__job_id__milestones__milestone_id__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"job_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Job Id"}},{"name":"milestone_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Milestone Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/app__schemas__common__MessageResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/jobs/{job_id}/qr-code":{"post":{"tags":["Jobs"],"summary":"Generate Job Qr Code","description":"Generate (or return existing active) QR code for a job's site entrance.","operationId":"generate_job_qr_code_api_v1_jobs__job_id__qr_code_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"job_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Job Id"}}],"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JobQRCodeResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/jobs/{job_id}/qr-code.png":{"get":{"tags":["Jobs"],"summary":"Get Job Qr Png","description":"Return the active QR code as a PNG image.","operationId":"get_job_qr_png_api_v1_jobs__job_id__qr_code_png_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"job_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Job Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/documents/upload":{"post":{"tags":["Documents"],"summary":"Upload Document","operationId":"upload_document_api_v1_documents_upload_post","requestBody":{"content":{"multipart/form-data":{"schema":{"$ref":"#/components/schemas/Body_upload_document_api_v1_documents_upload_post"}}},"required":true},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"HTTPBearer":[]}]}},"/api/v1/documents/{document_id}/download":{"get":{"tags":["Documents"],"summary":"Download Document","operationId":"download_document_api_v1_documents__document_id__download_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"document_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Document Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/documents/{document_id}":{"delete":{"tags":["Documents"],"summary":"Delete Document","operationId":"delete_document_api_v1_documents__document_id__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"document_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Document Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/app__schemas__common__MessageResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/subcontractors/subs":{"get":{"tags":["Subcontractors"],"summary":"List Subcontractors","operationId":"list_subcontractors_api_v1_subcontractors_subs_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"search","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Search"}},{"name":"trade","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Trade"}},{"name":"include_inactive","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Include Inactive"}},{"name":"page","in":"query","required":false,"schema":{"type":"integer","minimum":1,"default":1,"title":"Page"}},{"name":"per_page","in":"query","required":false,"schema":{"type":"integer","maximum":500,"minimum":1,"default":100,"title":"Per Page"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PaginatedResponse_SubcontractorResponse_"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["Subcontractors"],"summary":"Create Subcontractor","operationId":"create_subcontractor_api_v1_subcontractors_subs_post","security":[{"HTTPBearer":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SubcontractorCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SubcontractorResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/subcontractors/subs/approved":{"get":{"tags":["Subcontractors"],"summary":"List Approved Subcontractors","description":"Return approved subcontractors, optionally filtered by trade.","operationId":"list_approved_subcontractors_api_v1_subcontractors_subs_approved_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"trade","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Trade"}},{"name":"page","in":"query","required":false,"schema":{"type":"integer","minimum":1,"default":1,"title":"Page"}},{"name":"per_page","in":"query","required":false,"schema":{"type":"integer","maximum":500,"minimum":1,"default":100,"title":"Per Page"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PaginatedResponse_SubcontractorResponse_"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/subcontractors/subs/{sub_id}":{"get":{"tags":["Subcontractors"],"summary":"Get Subcontractor","operationId":"get_subcontractor_api_v1_subcontractors_subs__sub_id__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"sub_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Sub Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SubcontractorResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"patch":{"tags":["Subcontractors"],"summary":"Update Subcontractor","operationId":"update_subcontractor_api_v1_subcontractors_subs__sub_id__patch","security":[{"HTTPBearer":[]}],"parameters":[{"name":"sub_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Sub Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SubcontractorUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SubcontractorResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["Subcontractors"],"summary":"Delete Subcontractor","operationId":"delete_subcontractor_api_v1_subcontractors_subs__sub_id__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"sub_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Sub Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/app__schemas__common__MessageResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/subcontractors/rfqs":{"get":{"tags":["Subcontractors"],"summary":"List Rfqs","operationId":"list_rfqs_api_v1_subcontractors_rfqs_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"status","in":"query","required":false,"schema":{"anyOf":[{"$ref":"#/components/schemas/RFQStatus"},{"type":"null"}],"title":"Status"}},{"name":"page","in":"query","required":false,"schema":{"type":"integer","minimum":1,"default":1,"title":"Page"}},{"name":"per_page","in":"query","required":false,"schema":{"type":"integer","maximum":500,"minimum":1,"default":100,"title":"Per Page"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PaginatedResponse_RFQResponse_"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["Subcontractors"],"summary":"Create Rfq","operationId":"create_rfq_api_v1_subcontractors_rfqs_post","security":[{"HTTPBearer":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RFQCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RFQResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/subcontractors/rfqs/{rfq_id}":{"get":{"tags":["Subcontractors"],"summary":"Get Rfq","operationId":"get_rfq_api_v1_subcontractors_rfqs__rfq_id__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"rfq_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Rfq Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RFQResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"patch":{"tags":["Subcontractors"],"summary":"Update Rfq","operationId":"update_rfq_api_v1_subcontractors_rfqs__rfq_id__patch","security":[{"HTTPBearer":[]}],"parameters":[{"name":"rfq_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Rfq Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RFQUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RFQResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["Subcontractors"],"summary":"Delete Rfq","operationId":"delete_rfq_api_v1_subcontractors_rfqs__rfq_id__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"rfq_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Rfq Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/app__schemas__common__MessageResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/subcontractors/rfqs/{rfq_id}/invitations":{"get":{"tags":["Subcontractors"],"summary":"List Invitations","operationId":"list_invitations_api_v1_subcontractors_rfqs__rfq_id__invitations_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"rfq_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Rfq Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/RFQInvitationResponse"},"title":"Response List Invitations Api V1 Subcontractors Rfqs  Rfq Id  Invitations Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/subcontractors/rfqs/{rfq_id}/invite":{"post":{"tags":["Subcontractors"],"summary":"Invite Subcontractors","description":"Invite one or more subcontractors. Body: {\"subcontractor_ids\": [...]}","operationId":"invite_subcontractors_api_v1_subcontractors_rfqs__rfq_id__invite_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"rfq_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Rfq Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","title":"Body"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/RFQInvitationResponse"},"title":"Response Invite Subcontractors Api V1 Subcontractors Rfqs  Rfq Id  Invite Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/subcontractors/rfqs/{rfq_id}/invitations/{inv_id}":{"patch":{"tags":["Subcontractors"],"summary":"Respond To Invitation","description":"Record a subcontractor's quote response.","operationId":"respond_to_invitation_api_v1_subcontractors_rfqs__rfq_id__invitations__inv_id__patch","security":[{"HTTPBearer":[]}],"parameters":[{"name":"rfq_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Rfq Id"}},{"name":"inv_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Inv Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/InvitationRespondBody"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RFQInvitationResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/subcontractors/rfqs/{rfq_id}/invitations/{inv_id}/accept":{"post":{"tags":["Subcontractors"],"summary":"Accept Invitation","description":"Accept the winning quote. Declines all others and pulls cost into the linked quote/tender.","operationId":"accept_invitation_api_v1_subcontractors_rfqs__rfq_id__invitations__inv_id__accept_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"rfq_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Rfq Id"}},{"name":"inv_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Inv Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RFQInvitationResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/subcontractors/accreditation-links":{"get":{"tags":["Subcontractors"],"summary":"Get Accreditation Links","description":"Return lookup URLs for accreditation scheme registers.","operationId":"get_accreditation_links_api_v1_subcontractors_accreditation_links_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}},"security":[{"HTTPBearer":[]}]}},"/api/v1/variations":{"get":{"tags":["Variations"],"summary":"List Variations","operationId":"list_variations_api_v1_variations_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"job_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Job Id"}},{"name":"status","in":"query","required":false,"schema":{"anyOf":[{"$ref":"#/components/schemas/VariationStatus"},{"type":"null"}],"title":"Status"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/VariationResponse"},"title":"Response List Variations Api V1 Variations Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["Variations"],"summary":"Create Variation","operationId":"create_variation_api_v1_variations_post","security":[{"HTTPBearer":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/VariationCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/VariationResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/variations/{var_id}":{"get":{"tags":["Variations"],"summary":"Get Variation","operationId":"get_variation_api_v1_variations__var_id__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"var_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Var Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/VariationResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"patch":{"tags":["Variations"],"summary":"Update Variation","operationId":"update_variation_api_v1_variations__var_id__patch","security":[{"HTTPBearer":[]}],"parameters":[{"name":"var_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Var Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/VariationUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/VariationResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["Variations"],"summary":"Delete Variation","operationId":"delete_variation_api_v1_variations__var_id__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"var_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Var Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/app__schemas__common__MessageResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/variations/{var_id}/submit":{"post":{"tags":["Variations"],"summary":"Submit Variation","operationId":"submit_variation_api_v1_variations__var_id__submit_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"var_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Var Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/VariationResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/variations/{var_id}/approve":{"post":{"tags":["Variations"],"summary":"Approve Variation","operationId":"approve_variation_api_v1_variations__var_id__approve_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"var_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Var Id"}}],"requestBody":{"content":{"application/json":{"schema":{"type":"object","default":{},"title":"Body"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/VariationResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/variations/{var_id}/reject":{"post":{"tags":["Variations"],"summary":"Reject Variation","operationId":"reject_variation_api_v1_variations__var_id__reject_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"var_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Var Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/VariationRejectBody"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/VariationResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/variations/{var_id}/line-items":{"post":{"tags":["Variations"],"summary":"Add Line Item","operationId":"add_line_item_api_v1_variations__var_id__line_items_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"var_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Var Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/VariationLineItemCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/VariationLineItemResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/variations/{var_id}/line-items/{li_id}":{"patch":{"tags":["Variations"],"summary":"Update Line Item","operationId":"update_line_item_api_v1_variations__var_id__line_items__li_id__patch","security":[{"HTTPBearer":[]}],"parameters":[{"name":"var_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Var Id"}},{"name":"li_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Li Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/VariationLineItemUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/VariationLineItemResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["Variations"],"summary":"Delete Line Item","operationId":"delete_line_item_api_v1_variations__var_id__line_items__li_id__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"var_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Var Id"}},{"name":"li_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Li Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/app__schemas__common__MessageResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/variations/{variation_id}/send-for-signature":{"post":{"tags":["Variations"],"summary":"Send Variation For Signature","description":"Send a variation order for e-signature.","operationId":"send_variation_for_signature_api_v1_variations__variation_id__send_for_signature_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"variation_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Variation Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","title":"Body"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/purchase-orders/summary":{"get":{"tags":["Purchase Orders"],"summary":"Get Po Summary","operationId":"get_po_summary_api_v1_purchase_orders_summary_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"job_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Job Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/POSummaryResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/purchase-orders/approval-limits":{"get":{"tags":["Purchase Orders"],"summary":"Get Approval Limits","description":"Effective per-role authorisation limits — company overrides on top of defaults.","operationId":"get_approval_limits_api_v1_purchase_orders_approval_limits_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"items":{"$ref":"#/components/schemas/POApprovalLimitResponse"},"type":"array","title":"Response Get Approval Limits Api V1 Purchase Orders Approval Limits Get"}}}}},"security":[{"HTTPBearer":[]}]},"put":{"tags":["Purchase Orders"],"summary":"Set Approval Limits","description":"Replace the company's authorisation limits. Owners and admins only.","operationId":"set_approval_limits_api_v1_purchase_orders_approval_limits_put","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/POApprovalLimitsUpdate"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"items":{"$ref":"#/components/schemas/POApprovalLimitResponse"},"type":"array","title":"Response Set Approval Limits Api V1 Purchase Orders Approval Limits Put"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"HTTPBearer":[]}]}},"/api/v1/purchase-orders/pending-approval":{"get":{"tags":["Purchase Orders"],"summary":"List Pending Approval","operationId":"list_pending_approval_api_v1_purchase_orders_pending_approval_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"items":{"$ref":"#/components/schemas/POResponse"},"type":"array","title":"Response List Pending Approval Api V1 Purchase Orders Pending Approval Get"}}}}},"security":[{"HTTPBearer":[]}]}},"/api/v1/purchase-orders":{"get":{"tags":["Purchase Orders"],"summary":"List Purchase Orders","operationId":"list_purchase_orders_api_v1_purchase_orders_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"job_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Job Id"}},{"name":"status","in":"query","required":false,"schema":{"anyOf":[{"$ref":"#/components/schemas/POStatus"},{"type":"null"}],"title":"Status"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/POResponse"},"title":"Response List Purchase Orders Api V1 Purchase Orders Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["Purchase Orders"],"summary":"Create Purchase Order","operationId":"create_purchase_order_api_v1_purchase_orders_post","security":[{"HTTPBearer":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/POCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/POResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/purchase-orders/{po_id}":{"get":{"tags":["Purchase Orders"],"summary":"Get Purchase Order","operationId":"get_purchase_order_api_v1_purchase_orders__po_id__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"po_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Po Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/POResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"patch":{"tags":["Purchase Orders"],"summary":"Update Purchase Order","operationId":"update_purchase_order_api_v1_purchase_orders__po_id__patch","security":[{"HTTPBearer":[]}],"parameters":[{"name":"po_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Po Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/POUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/POResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["Purchase Orders"],"summary":"Cancel Purchase Order","operationId":"cancel_purchase_order_api_v1_purchase_orders__po_id__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"po_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Po Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/app__schemas__common__MessageResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/purchase-orders/{po_id}/submit":{"post":{"tags":["Purchase Orders"],"summary":"Submit Purchase Order","description":"Submit a draft for authorisation.\n\nAn order within the raiser's own limit is authorised on the spot — making someone\nrequest approval for an order they were always allowed to place is the fastest way to\nget an approval workflow switched off.","operationId":"submit_purchase_order_api_v1_purchase_orders__po_id__submit_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"po_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Po Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/POResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/purchase-orders/{po_id}/approve":{"post":{"tags":["Purchase Orders"],"summary":"Approve Purchase Order","operationId":"approve_purchase_order_api_v1_purchase_orders__po_id__approve_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"po_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Po Id"}}],"requestBody":{"content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/POApprovalDecision"},{"type":"null"}],"title":"Body"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/POResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/purchase-orders/{po_id}/reject":{"post":{"tags":["Purchase Orders"],"summary":"Reject Purchase Order","operationId":"reject_purchase_order_api_v1_purchase_orders__po_id__reject_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"po_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Po Id"}}],"requestBody":{"content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/POApprovalDecision"},{"type":"null"}],"title":"Body"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/POResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/purchase-orders/{po_id}/approval-trail":{"get":{"tags":["Purchase Orders"],"summary":"Get Approval Trail","operationId":"get_approval_trail_api_v1_purchase_orders__po_id__approval_trail_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"po_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Po Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/POApprovalEventResponse"},"title":"Response Get Approval Trail Api V1 Purchase Orders  Po Id  Approval Trail Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/purchase-orders/{po_id}/send":{"post":{"tags":["Purchase Orders"],"summary":"Send Purchase Order","description":"Issue the order to the supplier. Pushes to accounting if connected.\n\nThis is the moment the company is committed, so it is where authority is enforced:\nan order above the sender's own limit must have been approved by someone else first.","operationId":"send_purchase_order_api_v1_purchase_orders__po_id__send_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"po_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Po Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/POResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/purchase-orders/{po_id}/receive":{"post":{"tags":["Purchase Orders"],"summary":"Receive Purchase Order","description":"Mark line items as received.\nBody: {\"line_items\": [{\"line_item_id\": \"...\", \"quantity_received\": 5.0}, ...]}","operationId":"receive_purchase_order_api_v1_purchase_orders__po_id__receive_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"po_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Po Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","title":"Body"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/POResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/purchase-orders/{po_id}/line-items":{"post":{"tags":["Purchase Orders"],"summary":"Add Line Item","operationId":"add_line_item_api_v1_purchase_orders__po_id__line_items_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"po_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Po Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/POLineItemCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/POLineItemResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/purchase-orders/{po_id}/line-items/{li_id}":{"patch":{"tags":["Purchase Orders"],"summary":"Update Line Item","operationId":"update_line_item_api_v1_purchase_orders__po_id__line_items__li_id__patch","security":[{"HTTPBearer":[]}],"parameters":[{"name":"po_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Po Id"}},{"name":"li_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Li Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/POLineItemUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/POLineItemResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["Purchase Orders"],"summary":"Delete Line Item","operationId":"delete_line_item_api_v1_purchase_orders__po_id__line_items__li_id__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"po_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Po Id"}},{"name":"li_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Li Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/app__schemas__common__MessageResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/purchase-orders/{po_id}/send-for-signature":{"post":{"tags":["Purchase Orders"],"summary":"Send Po For Signature","description":"Send a purchase order for e-signature.","operationId":"send_po_for_signature_api_v1_purchase_orders__po_id__send_for_signature_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"po_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Po Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","title":"Body"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/timesheets":{"get":{"tags":["Timesheets"],"summary":"List Timesheet Entries","description":"Timesheet entries. Paginated — this table grows fastest of anything in the\nproduct (one row per worker per day), and previously returned every row ever\nlogged on every request.","operationId":"list_timesheet_entries_api_v1_timesheets_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"job_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Job Id"}},{"name":"date_from","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Date From"}},{"name":"date_to","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Date To"}},{"name":"approved","in":"query","required":false,"schema":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Approved"}},{"name":"worker_name","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Worker Name"}},{"name":"page","in":"query","required":false,"schema":{"type":"integer","minimum":1,"default":1,"title":"Page"}},{"name":"per_page","in":"query","required":false,"schema":{"type":"integer","maximum":500,"minimum":1,"default":100,"title":"Per Page"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PaginatedResponse_TimesheetEntryResponse_"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["Timesheets"],"summary":"Create Timesheet Entry","operationId":"create_timesheet_entry_api_v1_timesheets_post","security":[{"HTTPBearer":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/TimesheetEntryCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TimesheetEntryResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/timesheets/payroll-export":{"get":{"tags":["Timesheets"],"summary":"Payroll Export","description":"Export approved timesheet entries as CSV for payroll processing.","operationId":"payroll_export_api_v1_timesheets_payroll_export_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"date_from","in":"query","required":true,"schema":{"type":"string","format":"date","title":"Date From"}},{"name":"date_to","in":"query","required":true,"schema":{"type":"string","format":"date","title":"Date To"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/timesheets/workers":{"get":{"tags":["Timesheets"],"summary":"List Workers","description":"Return distinct worker names for autocomplete.","operationId":"list_workers_api_v1_timesheets_workers_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"items":{"type":"string"},"type":"array","title":"Response List Workers Api V1 Timesheets Workers Get"}}}}},"security":[{"HTTPBearer":[]}]}},"/api/v1/timesheets/summary":{"get":{"tags":["Timesheets"],"summary":"Get Timesheet Summary","operationId":"get_timesheet_summary_api_v1_timesheets_summary_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"job_id","in":"query","required":true,"schema":{"type":"string","format":"uuid","title":"Job Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TimesheetSummary"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/timesheets/{entry_id}":{"get":{"tags":["Timesheets"],"summary":"Get Timesheet Entry","operationId":"get_timesheet_entry_api_v1_timesheets__entry_id__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"entry_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Entry Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TimesheetEntryResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"patch":{"tags":["Timesheets"],"summary":"Update Timesheet Entry","operationId":"update_timesheet_entry_api_v1_timesheets__entry_id__patch","security":[{"HTTPBearer":[]}],"parameters":[{"name":"entry_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Entry Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/TimesheetEntryUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TimesheetEntryResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["Timesheets"],"summary":"Delete Timesheet Entry","operationId":"delete_timesheet_entry_api_v1_timesheets__entry_id__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"entry_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Entry Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/app__schemas__common__MessageResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/timesheets/{entry_id}/approve":{"post":{"tags":["Timesheets"],"summary":"Approve Timesheet Entry","operationId":"approve_timesheet_entry_api_v1_timesheets__entry_id__approve_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"entry_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Entry Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","title":"Body"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TimesheetEntryResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/timesheets/payroll-export/sage50":{"get":{"tags":["Timesheets"],"summary":"Payroll Export Sage50","description":"Export approved timesheets for PAYE employees as Sage 50 Payroll CSV.\n\nSelf-employed and contractor workers are excluded — see `/payroll-export/cis`.","operationId":"payroll_export_sage50_api_v1_timesheets_payroll_export_sage50_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"date_from","in":"query","required":true,"schema":{"type":"string","format":"date","title":"Date From"}},{"name":"date_to","in":"query","required":true,"schema":{"type":"string","format":"date","title":"Date To"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/timesheets/payroll-export/p32":{"get":{"tags":["Timesheets"],"summary":"Payroll Export P32","description":"Export approved PAYE timesheets as a P32 Employer Payment Record (per tax month).\n\nOne row per 6th-to-5th tax month, with thresholds applied once per employee per period.\nCIS workers are excluded.","operationId":"payroll_export_p32_api_v1_timesheets_payroll_export_p32_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"date_from","in":"query","required":true,"schema":{"type":"string","format":"date","title":"Date From"}},{"name":"date_to","in":"query","required":true,"schema":{"type":"string","format":"date","title":"Date To"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/timesheets/payroll-export/hmrc-rti":{"get":{"tags":["Timesheets"],"summary":"Payroll Export Hmrc Rti","description":"Export approved PAYE timesheets in HMRC RTI Full Payment Submission layout.\n\nOne row per employee per tax month. Self-employed and contractor workers do not belong\non an FPS and are excluded — their labour goes through `/payroll-export/cis`.","operationId":"payroll_export_hmrc_rti_api_v1_timesheets_payroll_export_hmrc_rti_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"date_from","in":"query","required":true,"schema":{"type":"string","format":"date","title":"Date From"}},{"name":"date_to","in":"query","required":true,"schema":{"type":"string","format":"date","title":"Date To"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/timesheets/payroll-export/cis":{"get":{"tags":["Timesheets"],"summary":"Payroll Export Cis","description":"Export self-employed and contractor labour as a CIS300 monthly-return feed.\n\nDeduction is taken on the labour element only — plant and other reimbursed costs are\nstill paid in full but are removed from the base the rate is applied to (CISR15060).\nRows are grouped into 6th-to-5th CIS tax months, and a subcontractor with no verified\nrecord is deducted at the higher rate, which is what HMRC requires of the contractor.","operationId":"payroll_export_cis_api_v1_timesheets_payroll_export_cis_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"date_from","in":"query","required":true,"schema":{"type":"string","format":"date","title":"Date From"}},{"name":"date_to","in":"query","required":true,"schema":{"type":"string","format":"date","title":"Date To"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/site-diary":{"get":{"tags":["Site Diary"],"summary":"List Site Diary Entries","operationId":"list_site_diary_entries_api_v1_site_diary_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"job_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Job Id"}},{"name":"date_from","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Date From"}},{"name":"date_to","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Date To"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/SiteDiaryEntryResponse"},"title":"Response List Site Diary Entries Api V1 Site Diary Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["Site Diary"],"summary":"Create Site Diary Entry","operationId":"create_site_diary_entry_api_v1_site_diary_post","security":[{"HTTPBearer":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SiteDiaryEntryCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SiteDiaryEntryResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/site-diary/{entry_id}":{"get":{"tags":["Site Diary"],"summary":"Get Site Diary Entry","operationId":"get_site_diary_entry_api_v1_site_diary__entry_id__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"entry_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Entry Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SiteDiaryEntryResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"patch":{"tags":["Site Diary"],"summary":"Update Site Diary Entry","operationId":"update_site_diary_entry_api_v1_site_diary__entry_id__patch","security":[{"HTTPBearer":[]}],"parameters":[{"name":"entry_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Entry Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SiteDiaryEntryUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SiteDiaryEntryResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["Site Diary"],"summary":"Delete Site Diary Entry","operationId":"delete_site_diary_entry_api_v1_site_diary__entry_id__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"entry_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Entry Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/app__schemas__common__MessageResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/defects/photo":{"post":{"tags":["Defects"],"summary":"Upload Defect Photo","description":"Upload a defect photo and return a URL to store on the defect's photo_url.\nReplaces the old paste-a-URL flow.","operationId":"upload_defect_photo_api_v1_defects_photo_post","requestBody":{"content":{"multipart/form-data":{"schema":{"$ref":"#/components/schemas/Body_upload_defect_photo_api_v1_defects_photo_post"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Upload Defect Photo Api V1 Defects Photo Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"HTTPBearer":[]}]}},"/api/v1/defects":{"get":{"tags":["Defects"],"summary":"List Defects","operationId":"list_defects_api_v1_defects_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"job_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Job Id"}},{"name":"punch_list_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Punch List Id"}},{"name":"status","in":"query","required":false,"schema":{"anyOf":[{"$ref":"#/components/schemas/DefectStatus"},{"type":"null"}],"title":"Status"}},{"name":"trade","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Trade"}},{"name":"priority","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Priority"}},{"name":"assigned_to_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Assigned To Id"}},{"name":"assigned_to_me","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Assigned To Me"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/DefectResponse"},"title":"Response List Defects Api V1 Defects Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["Defects"],"summary":"Create Defect","operationId":"create_defect_api_v1_defects_post","security":[{"HTTPBearer":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DefectCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DefectResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/defects/summary":{"get":{"tags":["Defects"],"summary":"Get Defect Summary","operationId":"get_defect_summary_api_v1_defects_summary_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"job_id","in":"query","required":true,"schema":{"type":"string","format":"uuid","title":"Job Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DefectSummary"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/defects/{defect_id}":{"get":{"tags":["Defects"],"summary":"Get Defect","operationId":"get_defect_api_v1_defects__defect_id__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"defect_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Defect Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DefectResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"patch":{"tags":["Defects"],"summary":"Update Defect","operationId":"update_defect_api_v1_defects__defect_id__patch","security":[{"HTTPBearer":[]}],"parameters":[{"name":"defect_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Defect Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DefectUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DefectResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["Defects"],"summary":"Delete Defect","operationId":"delete_defect_api_v1_defects__defect_id__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"defect_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Defect Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/app__schemas__common__MessageResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/defects/{defect_id}/sign-off":{"post":{"tags":["Defects"],"summary":"Sign Off Defect","operationId":"sign_off_defect_api_v1_defects__defect_id__sign_off_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"defect_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Defect Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DefectSignOff"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DefectResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/invoices":{"post":{"tags":["Invoices"],"summary":"Create Invoice","description":"Raise an invoice directly.\n\nInvoices could previously only appear by side effect — job completion, AFP\ncertification, retention release or the recurring cron — so there was no way to bill a\ncustomer for anything else: a deposit, a call-out, a one-off supply.","operationId":"create_invoice_api_v1_invoices_post","security":[{"HTTPBearer":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/InvoiceCreateRequest"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/InvoiceResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"get":{"tags":["Invoices"],"summary":"List Invoices","operationId":"list_invoices_api_v1_invoices_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"job_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Job Id"}},{"name":"status","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Status"}},{"name":"page","in":"query","required":false,"schema":{"type":"integer","minimum":1,"default":1,"title":"Page"}},{"name":"per_page","in":"query","required":false,"schema":{"type":"integer","maximum":100,"minimum":1,"default":20,"title":"Per Page"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PaginatedResponse_InvoiceResponse_"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/invoices/{invoice_id}":{"get":{"tags":["Invoices"],"summary":"Get Invoice","operationId":"get_invoice_api_v1_invoices__invoice_id__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"invoice_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Invoice Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/InvoiceResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/invoices/{invoice_id}/payment":{"patch":{"tags":["Invoices"],"summary":"Record Payment","description":"Record a payment against an invoice. Updates status and pushes to accounting if connected.","operationId":"record_payment_api_v1_invoices__invoice_id__payment_patch","security":[{"HTTPBearer":[]}],"parameters":[{"name":"invoice_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Invoice Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RecordPaymentRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/InvoiceResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/invoices/{invoice_id}/sync":{"post":{"tags":["Invoices"],"summary":"Sync Invoice","description":"Pull current payment status from the accounting system.","operationId":"sync_invoice_api_v1_invoices__invoice_id__sync_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"invoice_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Invoice Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/InvoiceResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/invoices/{invoice_id}/pdf":{"get":{"tags":["Invoices"],"summary":"Invoice Pdf","description":"Branded VAT invoice PDF.","operationId":"invoice_pdf_api_v1_invoices__invoice_id__pdf_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"invoice_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Invoice Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/invoices/{invoice_id}/send":{"post":{"tags":["Invoices"],"summary":"Send Invoice","description":"Email the invoice PDF to the client (or an explicit recipient).","operationId":"send_invoice_api_v1_invoices__invoice_id__send_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"invoice_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Invoice Id"}}],"requestBody":{"content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/SendInvoiceRequest"},{"type":"null"}],"title":"Body"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/app__schemas__common__MessageResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/invoices/{invoice_id}/remind":{"post":{"tags":["Invoices"],"summary":"Send Reminder","description":"Send a payment reminder email to the client.","operationId":"send_reminder_api_v1_invoices__invoice_id__remind_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"invoice_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Invoice Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/app__schemas__common__MessageResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/invoices/{invoice_id}/apply-interest":{"post":{"tags":["Invoices"],"summary":"Apply Interest","description":"Calculate simple interest on an overdue invoice and apply it.\nUses the invoice's interest_rate if set, otherwise falls back to the\ncompany's default late_payment_interest_rate.","operationId":"apply_interest_api_v1_invoices__invoice_id__apply_interest_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"invoice_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Invoice Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ApplyInterestResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/invoices/{invoice_id}/payment-plan":{"post":{"tags":["Invoices"],"summary":"Create Payment Plan","description":"Create a payment plan for an invoice, splitting it into installments.","operationId":"create_payment_plan_api_v1_invoices__invoice_id__payment_plan_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"invoice_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Invoice Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreatePaymentPlanRequest"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PaymentPlanResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"get":{"tags":["Invoices"],"summary":"Get Payment Plan","description":"View the payment plan for an invoice.","operationId":"get_payment_plan_api_v1_invoices__invoice_id__payment_plan_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"invoice_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Invoice Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PaymentPlanResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/invoices/{invoice_id}/payment-plan/{installment_idx}/pay":{"patch":{"tags":["Invoices"],"summary":"Mark Installment Paid","description":"Mark a specific installment in the payment plan as paid.","operationId":"mark_installment_paid_api_v1_invoices__invoice_id__payment_plan__installment_idx__pay_patch","security":[{"HTTPBearer":[]}],"parameters":[{"name":"invoice_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Invoice Id"}},{"name":"installment_idx","in":"path","required":true,"schema":{"type":"integer","title":"Installment Idx"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PaymentPlanResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/invoices/{invoice_id}/payment-link":{"post":{"tags":["Invoices"],"summary":"Create Payment Link","description":"Generate a Stripe Checkout payment link for an unpaid invoice.","operationId":"create_payment_link_api_v1_invoices__invoice_id__payment_link_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"invoice_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Invoice Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/invoices/{invoice_id}/payments":{"get":{"tags":["Invoices"],"summary":"List Payments","description":"Every receipt against this invoice, including voided ones (the ledger is complete).","operationId":"list_payments_api_v1_invoices__invoice_id__payments_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"invoice_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Invoice Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/PaymentResponse"},"title":"Response List Payments Api V1 Invoices  Invoice Id  Payments Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/invoices/{invoice_id}/payments/{payment_id}/void":{"post":{"tags":["Invoices"],"summary":"Void Payment","description":"Reverse a payment recorded in error.\n\nThe row is marked voided rather than deleted so the audit trail survives, and the\ninvoice balance is recalculated from the remaining ledger.","operationId":"void_payment_api_v1_invoices__invoice_id__payments__payment_id__void_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"invoice_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Invoice Id"}},{"name":"payment_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Payment Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/VoidPaymentRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/InvoiceResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/invoices/{invoice_id}/credit-notes":{"get":{"tags":["Invoices"],"summary":"List Credit Notes","operationId":"list_credit_notes_api_v1_invoices__invoice_id__credit_notes_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"invoice_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Invoice Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/CreditNoteResponse"},"title":"Response List Credit Notes Api V1 Invoices  Invoice Id  Credit Notes Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["Invoices"],"summary":"Create Credit Note","description":"Raise a credit note against an invoice.\n\nA VAT invoice must never be edited after issue — HMRC requires a credit note to\ncorrect it. The note is itself a VAT document, so net/VAT/gross are stored.","operationId":"create_credit_note_api_v1_invoices__invoice_id__credit_notes_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"invoice_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Invoice Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreditNoteCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreditNoteResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/invoices/credit-notes/{credit_note_id}/issue":{"post":{"tags":["Invoices"],"summary":"Issue Credit Note","description":"Issue a draft credit note — from here it reduces the invoice balance.","operationId":"issue_credit_note_api_v1_invoices_credit_notes__credit_note_id__issue_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"credit_note_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Credit Note Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreditNoteResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/invoices/credit-notes/{credit_note_id}/refund":{"post":{"tags":["Invoices"],"summary":"Refund Credit Note","description":"Mark a credit note as refunded — money actually returned, not just offset.","operationId":"refund_credit_note_api_v1_invoices_credit_notes__credit_note_id__refund_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"credit_note_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Credit Note Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RefundRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreditNoteResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/photos":{"get":{"tags":["Photo Management"],"summary":"List Photos","operationId":"list_photos_api_v1_photos_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"job_id","in":"query","required":true,"schema":{"type":"string","format":"uuid","title":"Job Id"}},{"name":"trade","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Trade"}},{"name":"location","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Location"}},{"name":"album_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Album Id"}},{"name":"before_after","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Before After"}},{"name":"client_only","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Client Only"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/SitePhotoResponse"},"title":"Response List Photos Api V1 Photos Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["Photo Management"],"summary":"Upload Photo","operationId":"upload_photo_api_v1_photos_post","security":[{"HTTPBearer":[]}],"requestBody":{"required":true,"content":{"multipart/form-data":{"schema":{"$ref":"#/components/schemas/Body_upload_photo_api_v1_photos_post"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SitePhotoResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/photos/{photo_id}":{"patch":{"tags":["Photo Management"],"summary":"Update Photo","description":"Edit a photo's description. Capture metadata is not editable here.","operationId":"update_photo_api_v1_photos__photo_id__patch","security":[{"HTTPBearer":[]}],"parameters":[{"name":"photo_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Photo Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SitePhotoUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SitePhotoResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["Photo Management"],"summary":"Delete Photo","operationId":"delete_photo_api_v1_photos__photo_id__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"photo_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Photo Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/app__schemas__common__MessageResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/photos/{photo_id}/capture-correction":{"post":{"tags":["Photo Management"],"summary":"Correct Capture Metadata","description":"Correct a photo's capture date or GPS, with a reason, on the record.\n\nKept separate from PATCH so that changing evidence is a deliberate act that leaves an\naudit entry holding the old and new values — not an incidental side effect of editing a\ncaption.","operationId":"correct_capture_metadata_api_v1_photos__photo_id__capture_correction_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"photo_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Photo Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SitePhotoCaptureCorrection"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SitePhotoResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/photos/{photo_id}/download":{"get":{"tags":["Photo Management"],"summary":"Download Photo","description":"The photo itself. Read through the storage layer so S3-backed installs work too.","operationId":"download_photo_api_v1_photos__photo_id__download_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"photo_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Photo Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/photos/albums":{"get":{"tags":["Photo Management"],"summary":"List Albums","operationId":"list_albums_api_v1_photos_albums_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"job_id","in":"query","required":true,"schema":{"type":"string","format":"uuid","title":"Job Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/PhotoAlbumResponse"},"title":"Response List Albums Api V1 Photos Albums Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["Photo Management"],"summary":"Create Album","operationId":"create_album_api_v1_photos_albums_post","security":[{"HTTPBearer":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PhotoAlbumCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PhotoAlbumResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/photos/albums/{album_id}":{"patch":{"tags":["Photo Management"],"summary":"Update Album","operationId":"update_album_api_v1_photos_albums__album_id__patch","security":[{"HTTPBearer":[]}],"parameters":[{"name":"album_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Album Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PhotoAlbumUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PhotoAlbumResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["Photo Management"],"summary":"Delete Album","operationId":"delete_album_api_v1_photos_albums__album_id__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"album_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Album Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/app__schemas__common__MessageResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/photos/{photo_id}/links":{"get":{"tags":["Photo Management"],"summary":"List Links","operationId":"list_links_api_v1_photos__photo_id__links_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"photo_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Photo Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/PhotoLinkResponse"},"title":"Response List Links Api V1 Photos  Photo Id  Links Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["Photo Management"],"summary":"Add Link","operationId":"add_link_api_v1_photos__photo_id__links_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"photo_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Photo Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PhotoLinkCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PhotoLinkResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/photos/{photo_id}/links/{linked_type}/{linked_id}":{"delete":{"tags":["Photo Management"],"summary":"Remove Link","operationId":"remove_link_api_v1_photos__photo_id__links__linked_type___linked_id__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"photo_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Photo Id"}},{"name":"linked_type","in":"path","required":true,"schema":{"type":"string","title":"Linked Type"}},{"name":"linked_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Linked Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/app__schemas__common__MessageResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/photos/report":{"get":{"tags":["Photo Management"],"summary":"Photo Report","operationId":"photo_report_api_v1_photos_report_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"job_id","in":"query","required":true,"schema":{"type":"string","format":"uuid","title":"Job Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/companies-house/search":{"get":{"tags":["Companies House"],"summary":"Search Companies","description":"Search Companies House by name.\n\nReturns [] rather than an error when nothing matches, when the API key is not\nconfigured, or when Companies House is unavailable. This sits behind a \"type a name\"\nfield, and a 500 there would block someone from adding a client at all — the lookup\nis a convenience on top of a form they can always complete by hand.","operationId":"search_companies_api_v1_companies_house_search_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"q","in":"query","required":true,"schema":{"type":"string","minLength":2,"description":"Company name or part of it","title":"Q"},"description":"Company name or part of it"},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":50,"minimum":1,"default":20,"title":"Limit"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"type":"object"},"title":"Response Search Companies Api V1 Companies House Search Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/companies-house/lookup":{"get":{"tags":["Companies House"],"summary":"Lookup Company","description":"Full details for one company number — name, registered office, status, SIC codes,\nand whether its accounts are overdue.","operationId":"lookup_company_api_v1_companies_house_lookup_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"number","in":"query","required":true,"schema":{"type":"string","description":"UK company number (up to 8 digits)","title":"Number"},"description":"UK company number (up to 8 digits)"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Lookup Company Api V1 Companies House Lookup Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/companies-house/officers":{"get":{"tags":["Companies House"],"summary":"Company Officers","description":"Currently appointed directors and secretaries.\n\nResigned officers are excluded — offering one as a contract signatory is worse than\noffering none.","operationId":"company_officers_api_v1_companies_house_officers_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"number","in":"query","required":true,"schema":{"type":"string","description":"UK company number","title":"Number"},"description":"UK company number"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"type":"object"},"title":"Response Company Officers Api V1 Companies House Officers Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/companies-house/public-lookup":{"get":{"tags":["Companies House"],"summary":"Public Lookup Company","description":"Public lookup used during registration, before an account exists.\n\nRate limited because it is unauthenticated and proxies a third-party API against our\nkey: without a limit it is a free, anonymous Companies House gateway, and the 600\nrequests per five minutes that key allows would be consumed by strangers.","operationId":"public_lookup_company_api_v1_companies_house_public_lookup_get","parameters":[{"name":"number","in":"query","required":true,"schema":{"type":"string","description":"UK company number (up to 8 digits)","title":"Number"},"description":"UK company number (up to 8 digits)"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Public Lookup Company Api V1 Companies House Public Lookup Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/companies-house/public-search":{"get":{"tags":["Companies House"],"summary":"Public Search Companies","description":"Public search used by the sign-up wizard, so a new customer can find their own\ncompany by name rather than having to know its number.","operationId":"public_search_companies_api_v1_companies_house_public_search_get","parameters":[{"name":"q","in":"query","required":true,"schema":{"type":"string","minLength":2,"title":"Q"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"type":"object"},"title":"Response Public Search Companies Api V1 Companies House Public Search Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/jobs/{job_id}/bom":{"get":{"tags":["Bill of Materials"],"summary":"List Bom","operationId":"list_bom_api_v1_jobs__job_id__bom_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"job_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Job Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["Bill of Materials"],"summary":"Create Bom Item","operationId":"create_bom_item_api_v1_jobs__job_id__bom_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"job_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Job Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BOMItemCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/jobs/{job_id}/bom/from-lines":{"post":{"tags":["Bill of Materials"],"summary":"Bom From Job Lines","description":"Copy job line items into BOM.","operationId":"bom_from_job_lines_api_v1_jobs__job_id__bom_from_lines_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"job_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Job Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/jobs/{job_id}/bom/generate-pos":{"post":{"tags":["Bill of Materials"],"summary":"Generate Purchase Orders","description":"Group BOM items by supplier and create draft PurchaseOrders.","operationId":"generate_purchase_orders_api_v1_jobs__job_id__bom_generate_pos_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"job_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Job Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/jobs/{job_id}/snag-portal-token":{"post":{"tags":["Snag Portal"],"summary":"Generate Snag Token","operationId":"generate_snag_token_api_v1_jobs__job_id__snag_portal_token_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"job_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Job Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/jobs/{job_id}/nps/send":{"post":{"tags":["NPS Surveys"],"summary":"Send Nps Survey","operationId":"send_nps_survey_api_v1_jobs__job_id__nps_send_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"job_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Job Id"}}],"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/webhook-endpoints/events":{"get":{"tags":["Webhooks"],"summary":"List Event Types","description":"Every event that can be subscribed to, with a description.\n\nPublished so an integrator can build against the list rather than guessing from our\ndocumentation and discovering a typo in production.","operationId":"list_event_types_api_v1_webhook_endpoints_events_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"items":{"type":"object"},"type":"array","title":"Response List Event Types Api V1 Webhook Endpoints Events Get"}}}}},"security":[{"HTTPBearer":[]}]}},"/api/v1/webhook-endpoints":{"get":{"tags":["Webhooks"],"summary":"List Endpoints","operationId":"list_endpoints_api_v1_webhook_endpoints_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"items":{"$ref":"#/components/schemas/WebhookEndpointResponse"},"type":"array","title":"Response List Endpoints Api V1 Webhook Endpoints Get"}}}}},"security":[{"HTTPBearer":[]}]},"post":{"tags":["Webhooks"],"summary":"Create Endpoint","description":"Register an endpoint. The signing secret is returned **once**, here.\n\nIt is not retrievable afterwards, the same way a payment provider treats one: a\nsecret that can be read back from an API is one an attacker with a stolen session can\nread back too, and then forge events with.","operationId":"create_endpoint_api_v1_webhook_endpoints_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/WebhookEndpointCreate"}}},"required":true},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Create Endpoint Api V1 Webhook Endpoints Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"HTTPBearer":[]}]}},"/api/v1/webhook-endpoints/{endpoint_id}":{"patch":{"tags":["Webhooks"],"summary":"Update Endpoint","operationId":"update_endpoint_api_v1_webhook_endpoints__endpoint_id__patch","security":[{"HTTPBearer":[]}],"parameters":[{"name":"endpoint_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Endpoint Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/WebhookEndpointUpdate"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/WebhookEndpointResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["Webhooks"],"summary":"Delete Endpoint","operationId":"delete_endpoint_api_v1_webhook_endpoints__endpoint_id__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"endpoint_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Endpoint Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/app__schemas__common__MessageResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/webhook-endpoints/{endpoint_id}/test":{"post":{"tags":["Webhooks"],"summary":"Test Endpoint","description":"Send a `ping` event now and report exactly what came back.\n\nDelivered synchronously rather than queued: the whole point is to tell someone\nsetting up an integration what happened, and \"it has been queued\" tells them nothing.","operationId":"test_endpoint_api_v1_webhook_endpoints__endpoint_id__test_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"endpoint_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Endpoint Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Test Endpoint Api V1 Webhook Endpoints  Endpoint Id  Test Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/webhook-endpoints/{endpoint_id}/roll-secret":{"post":{"tags":["Webhooks"],"summary":"Roll Secret","description":"Issue a new signing secret, invalidating the old one immediately.","operationId":"roll_secret_api_v1_webhook_endpoints__endpoint_id__roll_secret_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"endpoint_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Endpoint Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"object","title":"Response Roll Secret Api V1 Webhook Endpoints  Endpoint Id  Roll Secret Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}}},"components":{"schemas":{"AIAnalyseRequest":{"properties":{"text":{"type":"string","maxLength":2000,"minLength":10,"title":"Text"}},"type":"object","required":["text"],"title":"AIAnalyseRequest"},"AIAnalyseResponse":{"properties":{"company_type":{"type":"string","title":"Company Type"},"primary_trades":{"items":{"type":"string"},"type":"array","title":"Primary Trades"},"operating_regions":{"items":{"type":"string"},"type":"array","title":"Operating Regions"},"project_types":{"items":{"type":"string"},"type":"array","title":"Project Types"},"typical_project_value":{"type":"string","title":"Typical Project Value"}},"type":"object","required":["company_type","primary_trades","operating_regions","project_types","typical_project_value"],"title":"AIAnalyseResponse"},"AIRecommendRequest":{"properties":{"trades":{"items":{"type":"string"},"type":"array","title":"Trades","default":[]},"team_size":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Team Size"},"project_types":{"items":{"type":"string"},"type":"array","title":"Project Types","default":[]},"accreditations":{"items":{"type":"string"},"type":"array","title":"Accreditations","default":[]},"typical_value":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Typical Value"},"operating_regions":{"items":{"type":"string"},"type":"array","title":"Operating Regions","default":[]},"concurrent_projects":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Concurrent Projects"},"subcontracting":{"type":"boolean","title":"Subcontracting","default":false},"cis_registered":{"type":"boolean","title":"Cis Registered","default":false},"public_liability":{"type":"boolean","title":"Public Liability","default":false},"employers_liability":{"type":"boolean","title":"Employers Liability","default":false},"professional_indemnity":{"type":"boolean","title":"Professional Indemnity","default":false},"interested_in_tenders":{"type":"boolean","title":"Interested In Tenders","default":false},"current_estimating_tool":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Current Estimating Tool"},"current_job_management_tool":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Current Job Management Tool"},"wants_data_import":{"type":"boolean","title":"Wants Data Import","default":false}},"type":"object","title":"AIRecommendRequest"},"AIRecommendResponse":{"properties":{"plan":{"type":"string","title":"Plan"},"reasoning":{"type":"string","title":"Reasoning"},"highlighted_features":{"items":{"type":"string"},"type":"array","title":"Highlighted Features"},"recommended_modules":{"items":{"type":"string"},"type":"array","title":"Recommended Modules"},"estimated_savings_text":{"type":"string","title":"Estimated Savings Text"}},"type":"object","required":["plan","reasoning","highlighted_features","recommended_modules","estimated_savings_text"],"title":"AIRecommendResponse"},"AMActivityCreate":{"properties":{"activity_type":{"$ref":"#/components/schemas/AMActivityType"},"description":{"type":"string","title":"Description"},"activity_date":{"type":"string","format":"date","title":"Activity Date"}},"type":"object","required":["activity_type","description","activity_date"],"title":"AMActivityCreate"},"AMActivityResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"prospect_id":{"type":"string","format":"uuid","title":"Prospect Id"},"account_manager_id":{"type":"string","format":"uuid","title":"Account Manager Id"},"activity_type":{"$ref":"#/components/schemas/AMActivityType"},"description":{"type":"string","title":"Description"},"activity_date":{"type":"string","format":"date","title":"Activity Date"},"created_at":{"type":"string","format":"date-time","title":"Created At"}},"type":"object","required":["id","prospect_id","account_manager_id","activity_type","description","activity_date","created_at"],"title":"AMActivityResponse"},"AMActivityType":{"type":"string","enum":["call","email","demo","meeting","note"],"title":"AMActivityType"},"AMCommissionResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"account_manager_id":{"type":"string","format":"uuid","title":"Account Manager Id"},"company_id":{"type":"string","format":"uuid","title":"Company Id"},"company_name":{"type":"string","title":"Company Name","default":""},"period_month":{"type":"integer","title":"Period Month"},"period_year":{"type":"integer","title":"Period Year"},"gross_mrr_pence":{"type":"integer","title":"Gross Mrr Pence"},"stripe_fees_pence":{"type":"integer","title":"Stripe Fees Pence"},"net_mrr_pence":{"type":"integer","title":"Net Mrr Pence"},"commission_rate":{"type":"number","title":"Commission Rate"},"commission_pence":{"type":"integer","title":"Commission Pence"},"hold_until":{"type":"string","format":"date","title":"Hold Until"},"status":{"$ref":"#/components/schemas/AMCommissionStatus"},"stripe_transfer_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Stripe Transfer Id"},"paid_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Paid At"},"approved_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Approved At"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"created_at":{"type":"string","format":"date-time","title":"Created At"}},"type":"object","required":["id","account_manager_id","company_id","period_month","period_year","gross_mrr_pence","stripe_fees_pence","net_mrr_pence","commission_rate","commission_pence","hold_until","status","stripe_transfer_id","paid_at","approved_at","notes","created_at"],"title":"AMCommissionResponse"},"AMCommissionStatus":{"type":"string","enum":["pending","approved","paid","voided"],"title":"AMCommissionStatus"},"AMCommissionVoidRequest":{"properties":{"notes":{"type":"string","title":"Notes"}},"type":"object","required":["notes"],"title":"AMCommissionVoidRequest"},"AMDashboardStats":{"properties":{"active_clients":{"type":"integer","title":"Active Clients"},"mrr_attributed_pence":{"type":"integer","title":"Mrr Attributed Pence"},"commission_this_month_pence":{"type":"integer","title":"Commission This Month Pence"},"pending_commission_pence":{"type":"integer","title":"Pending Commission Pence"},"approved_commission_pence":{"type":"integer","title":"Approved Commission Pence"},"paid_commission_pence":{"type":"integer","title":"Paid Commission Pence"},"lifetime_earnings_pence":{"type":"integer","title":"Lifetime Earnings Pence"},"current_tier":{"type":"integer","title":"Current Tier"},"current_rate_percentage":{"type":"number","title":"Current Rate Percentage"},"follow_ups_due_today":{"type":"integer","title":"Follow Ups Due Today"}},"type":"object","required":["active_clients","mrr_attributed_pence","commission_this_month_pence","pending_commission_pence","approved_commission_pence","paid_commission_pence","lifetime_earnings_pence","current_tier","current_rate_percentage","follow_ups_due_today"],"title":"AMDashboardStats"},"AMEmailSendCreate":{"properties":{"to_email":{"type":"string","format":"email","title":"To Email"},"to_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"To Name"},"prospect_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Prospect Id"}},"type":"object","required":["to_email"],"title":"AMEmailSendCreate"},"AMEmailSendResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"account_manager_id":{"type":"string","format":"uuid","title":"Account Manager Id"},"prospect_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Prospect Id"},"to_email":{"type":"string","title":"To Email"},"to_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"To Name"},"tracking_token":{"type":"string","title":"Tracking Token"},"sent_at":{"type":"string","format":"date-time","title":"Sent At"},"opened_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Opened At"},"clicked_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Clicked At"},"converted_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Converted At"},"converted_company_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Converted Company Id"},"created_at":{"type":"string","format":"date-time","title":"Created At"}},"type":"object","required":["id","account_manager_id","prospect_id","to_email","to_name","tracking_token","sent_at","opened_at","clicked_at","converted_at","converted_company_id","created_at"],"title":"AMEmailSendResponse"},"AMProspectCreate":{"properties":{"company_name":{"type":"string","title":"Company Name"},"contact_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Contact Name"},"contact_email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Contact Email"},"contact_phone":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Contact Phone"},"stage":{"$ref":"#/components/schemas/AMProspectStage","default":"lead"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"follow_up_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Follow Up Date"}},"type":"object","required":["company_name"],"title":"AMProspectCreate"},"AMProspectResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"account_manager_id":{"type":"string","format":"uuid","title":"Account Manager Id"},"company_name":{"type":"string","title":"Company Name"},"contact_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Contact Name"},"contact_email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Contact Email"},"contact_phone":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Contact Phone"},"stage":{"$ref":"#/components/schemas/AMProspectStage"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"follow_up_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Follow Up Date"},"converted_company_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Converted Company Id"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"}},"type":"object","required":["id","account_manager_id","company_name","contact_name","contact_email","contact_phone","stage","notes","follow_up_date","converted_company_id","created_at","updated_at"],"title":"AMProspectResponse"},"AMProspectStage":{"type":"string","enum":["lead","qualified","demo_booked","trial","converted","lost"],"title":"AMProspectStage"},"AMProspectUpdate":{"properties":{"company_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Company Name"},"contact_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Contact Name"},"contact_email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Contact Email"},"contact_phone":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Contact Phone"},"stage":{"anyOf":[{"$ref":"#/components/schemas/AMProspectStage"},{"type":"null"}]},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"follow_up_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Follow Up Date"}},"type":"object","title":"AMProspectUpdate"},"APIAppCreate":{"properties":{"name":{"type":"string","title":"Name"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"developer_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Developer Name"},"developer_email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Developer Email"},"logo_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Logo Url"},"website_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Website Url"},"category":{"type":"string","title":"Category","default":"other"},"is_published":{"type":"boolean","title":"Is Published","default":false}},"type":"object","required":["name"],"title":"APIAppCreate"},"APIAppResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"name":{"type":"string","title":"Name"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"developer_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Developer Name"},"developer_email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Developer Email"},"logo_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Logo Url"},"website_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Website Url"},"category":{"type":"string","title":"Category"},"is_published":{"type":"boolean","title":"Is Published"},"install_count":{"type":"integer","title":"Install Count"},"rating":{"type":"number","title":"Rating"},"created_at":{"type":"string","format":"date-time","title":"Created At"}},"type":"object","required":["id","name","description","developer_name","developer_email","logo_url","website_url","category","is_published","install_count","rating","created_at"],"title":"APIAppResponse"},"APIAppUpdate":{"properties":{"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"developer_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Developer Name"},"developer_email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Developer Email"},"logo_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Logo Url"},"website_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Website Url"},"category":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Category"},"is_published":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Published"}},"type":"object","title":"APIAppUpdate"},"APIKeyCreate":{"properties":{"name":{"type":"string","title":"Name"},"scopes":{"items":{"type":"string"},"type":"array","title":"Scopes","default":["read"]},"expires_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Expires At"}},"type":"object","required":["name"],"title":"APIKeyCreate"},"APIKeyCreateResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"company_id":{"type":"string","format":"uuid","title":"Company Id"},"name":{"type":"string","title":"Name"},"key_prefix":{"type":"string","title":"Key Prefix"},"scopes":{"items":{"type":"string"},"type":"array","title":"Scopes"},"last_used_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Used At"},"expires_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Expires At"},"is_active":{"type":"boolean","title":"Is Active"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"full_key":{"type":"string","title":"Full Key"}},"type":"object","required":["id","company_id","name","key_prefix","scopes","last_used_at","expires_at","is_active","created_at","full_key"],"title":"APIKeyCreateResponse","description":"Returned only on creation — includes the full key (shown once)."},"APIKeyResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"company_id":{"type":"string","format":"uuid","title":"Company Id"},"name":{"type":"string","title":"Name"},"key_prefix":{"type":"string","title":"Key Prefix"},"scopes":{"items":{"type":"string"},"type":"array","title":"Scopes"},"last_used_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Used At"},"expires_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Expires At"},"is_active":{"type":"boolean","title":"Is Active"},"created_at":{"type":"string","format":"date-time","title":"Created At"}},"type":"object","required":["id","company_id","name","key_prefix","scopes","last_used_at","expires_at","is_active","created_at"],"title":"APIKeyResponse"},"APIKeyUpdate":{"properties":{"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name"},"scopes":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Scopes"},"is_active":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Active"}},"type":"object","title":"APIKeyUpdate"},"AcceptInviteRequest":{"properties":{"token":{"type":"string","title":"Token"},"password":{"type":"string","title":"Password"},"first_name":{"type":"string","title":"First Name"},"last_name":{"type":"string","title":"Last Name"}},"type":"object","required":["token","password","first_name","last_name"],"title":"AcceptInviteRequest"},"AccidentIn":{"properties":{"job_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Job Id"},"incident_type":{"$ref":"#/components/schemas/IncidentType"},"severity":{"$ref":"#/components/schemas/IncidentSeverity"},"incident_date":{"type":"string","format":"date","title":"Incident Date"},"location":{"type":"string","title":"Location"},"description":{"type":"string","title":"Description"},"injured_person":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Injured Person"},"injuries":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Injuries"},"immediate_action":{"type":"string","title":"Immediate Action"},"corrective_action":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Corrective Action"},"witnesses":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Witnesses"},"is_riddor":{"type":"boolean","title":"Is Riddor","default":false}},"type":"object","required":["incident_type","severity","incident_date","location","description","immediate_action"],"title":"AccidentIn"},"AccidentPatch":{"properties":{"incident_type":{"anyOf":[{"$ref":"#/components/schemas/IncidentType"},{"type":"null"}]},"severity":{"anyOf":[{"$ref":"#/components/schemas/IncidentSeverity"},{"type":"null"}]},"incident_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Incident Date"},"location":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Location"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"injured_person":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Injured Person"},"injuries":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Injuries"},"immediate_action":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Immediate Action"},"corrective_action":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Corrective Action"},"witnesses":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Witnesses"},"is_riddor":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Riddor"},"riddor_reported_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Riddor Reported At"}},"type":"object","title":"AccidentPatch"},"AccountManagerResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"user_id":{"type":"string","format":"uuid","title":"User Id"},"referral_code":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Referral Code"},"status":{"$ref":"#/components/schemas/AccountManagerStatus"},"stripe_connect_account_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Stripe Connect Account Id"},"stripe_connect_onboarded":{"type":"boolean","title":"Stripe Connect Onboarded"},"payout_hold_days":{"type":"integer","title":"Payout Hold Days"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"approved_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Approved At"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"email":{"type":"string","title":"Email","default":""},"first_name":{"type":"string","title":"First Name","default":""},"last_name":{"type":"string","title":"Last Name","default":""},"active_clients":{"type":"integer","title":"Active Clients","default":0},"mrr_attributed_pence":{"type":"integer","title":"Mrr Attributed Pence","default":0},"pending_commission_pence":{"type":"integer","title":"Pending Commission Pence","default":0}},"type":"object","required":["id","user_id","referral_code","status","stripe_connect_account_id","stripe_connect_onboarded","payout_hold_days","notes","approved_at","created_at"],"title":"AccountManagerResponse"},"AccountManagerStatus":{"type":"string","enum":["pending","approved","active","suspended"],"title":"AccountManagerStatus"},"AccountManagerUpdate":{"properties":{"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"payout_hold_days":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Payout Hold Days"},"status":{"anyOf":[{"$ref":"#/components/schemas/AccountManagerStatus"},{"type":"null"}]}},"type":"object","title":"AccountManagerUpdate"},"AccountingProvider":{"type":"string","enum":["xero","quickbooks","freshbooks","sage","hubspot","pipedrive"],"title":"AccountingProvider","description":"Third-party connections stored in `accounting_connections`.\n\nThe CRM providers live here too. The table is really \"connected third-party account\",\nand the CRM routes were already writing to it — but the database enum had no label for\nthem, so every CRM query raised InvalidTextRepresentation before it could run."},"AccreditationDetails":{"properties":{"constructionline_level":{"type":"string","title":"Constructionline Level","default":"none"},"chas_level":{"type":"string","title":"Chas Level","default":"none"},"safe_contractor":{"type":"boolean","title":"Safe Contractor","default":false},"cscs_card_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cscs Card Type"},"iso_9001":{"type":"boolean","title":"Iso 9001","default":false},"iso_14001":{"type":"boolean","title":"Iso 14001","default":false},"iso_45001":{"type":"boolean","title":"Iso 45001","default":false},"gas_safe":{"type":"boolean","title":"Gas Safe","default":false},"niceic":{"type":"boolean","title":"Niceic","default":false},"napit":{"type":"boolean","title":"Napit","default":false},"other_accreditations":{"items":{"type":"string"},"type":"array","title":"Other Accreditations","default":[]}},"type":"object","title":"AccreditationDetails"},"AccreditationIn":{"properties":{"entity_type":{"type":"string","title":"Entity Type","default":"company"},"entity_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Entity Id"},"scheme":{"type":"string","title":"Scheme"},"reference_number":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Reference Number"},"status":{"type":"string","title":"Status","default":"active"},"awarded_date":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Awarded Date"},"expiry_date":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Expiry Date"},"document_path":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Document Path"},"is_verified":{"type":"boolean","title":"Is Verified","default":false},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"}},"type":"object","required":["scheme"],"title":"AccreditationIn"},"AccreditationPatch":{"properties":{"scheme":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Scheme"},"reference_number":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Reference Number"},"status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Status"},"awarded_date":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Awarded Date"},"expiry_date":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Expiry Date"},"document_path":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Document Path"},"is_verified":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Verified"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"}},"type":"object","title":"AccreditationPatch"},"AcknowledgeDisclaimerRequest":{"properties":{"acknowledged":{"type":"boolean","title":"Acknowledged","default":true}},"type":"object","title":"AcknowledgeDisclaimerRequest"},"AcknowledgementStatusResponse":{"properties":{"employee_id":{"type":"string","format":"uuid","title":"Employee Id"},"employee_number":{"type":"string","title":"Employee Number"},"full_name":{"type":"string","title":"Full Name"},"acknowledged_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Acknowledged At"}},"type":"object","required":["employee_id","employee_number","full_name","acknowledged_at"],"title":"AcknowledgementStatusResponse"},"ActiveShowcaseResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"profile_id":{"type":"string","format":"uuid","title":"Profile Id"},"title":{"type":"string","title":"Title"},"tagline":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Tagline"},"image_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Image Url"},"ends_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Ends At"},"display_name":{"type":"string","title":"Display Name","default":""},"trades":{"items":{"type":"string"},"type":"array","title":"Trades","default":[]},"avg_rating":{"type":"number","title":"Avg Rating","default":0.0},"postcode":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Postcode"},"is_verified_estimark":{"type":"boolean","title":"Is Verified Estimark","default":false}},"type":"object","required":["id","profile_id","title","tagline","image_url","ends_at"],"title":"ActiveShowcaseResponse"},"ActualPriceAggregateResponse":{"properties":{"avg_price":{"type":"number","title":"Avg Price"},"min_price":{"type":"number","title":"Min Price"},"max_price":{"type":"number","title":"Max Price"},"sample_count":{"type":"integer","title":"Sample Count"}},"type":"object","required":["avg_price","min_price","max_price","sample_count"],"title":"ActualPriceAggregateResponse"},"ActualPriceCreate":{"properties":{"price_paid":{"type":"number","minimum":0.01,"title":"Price Paid"},"quantity":{"type":"number","minimum":0.01,"title":"Quantity","default":1.0},"supplier_key":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Supplier Key"},"region":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Region"},"purchased_at":{"type":"string","format":"date","title":"Purchased At"},"notes":{"anyOf":[{"type":"string","maxLength":500},{"type":"null"}],"title":"Notes"}},"type":"object","required":["price_paid","purchased_at"],"title":"ActualPriceCreate"},"AddPaymentMethodRequest":{"properties":{"payment_method_id":{"type":"string","title":"Payment Method Id"}},"type":"object","required":["payment_method_id"],"title":"AddPaymentMethodRequest"},"Admin2FADisableRequest":{"properties":{"code":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Code"},"backup_code":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Backup Code"}},"type":"object","title":"Admin2FADisableRequest"},"Admin2FAEnableResponse":{"properties":{"backup_codes":{"items":{"type":"string"},"type":"array","title":"Backup Codes"}},"type":"object","required":["backup_codes"],"title":"Admin2FAEnableResponse"},"Admin2FALoginVerifyRequest":{"properties":{"temp_token":{"type":"string","title":"Temp Token"},"code":{"type":"string","title":"Code"}},"type":"object","required":["temp_token","code"],"title":"Admin2FALoginVerifyRequest"},"Admin2FASetupResponse":{"properties":{"secret":{"type":"string","title":"Secret"},"otpauth_uri":{"type":"string","title":"Otpauth Uri"},"qr_data":{"type":"string","title":"Qr Data"}},"type":"object","required":["secret","otpauth_uri","qr_data"],"title":"Admin2FASetupResponse"},"Admin2FAVerifyRequest":{"properties":{"secret":{"type":"string","title":"Secret"},"code":{"type":"string","title":"Code"}},"type":"object","required":["secret","code"],"title":"Admin2FAVerifyRequest"},"AdminAMCreate":{"properties":{"email":{"type":"string","format":"email","title":"Email"},"first_name":{"type":"string","title":"First Name"},"last_name":{"type":"string","title":"Last Name"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"payout_hold_days":{"type":"integer","title":"Payout Hold Days","default":30},"temp_password":{"type":"string","title":"Temp Password"}},"type":"object","required":["email","first_name","last_name","temp_password"],"title":"AdminAMCreate"},"AdminCreditEntryResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"entry_type":{"$ref":"#/components/schemas/CreditEntryType"},"amount":{"type":"string","title":"Amount"},"currency":{"type":"string","title":"Currency"},"reason":{"$ref":"#/components/schemas/CreditReason"},"note":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Note"},"expires_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Expires At"},"invoice_reference":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Invoice Reference"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"internal_note":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Internal Note"},"created_by_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Created By Id"}},"type":"object","required":["id","entry_type","amount","currency","reason","note","expires_at","invoice_reference","created_at","internal_note","created_by_id"],"title":"AdminCreditEntryResponse","description":"Adds the fields only staff should see."},"AnalysisStatus":{"type":"string","enum":["pending","analysing","awaiting_answers","complete","error"],"title":"AnalysisStatus"},"AnnouncementBody":{"properties":{"title":{"type":"string","title":"Title"},"body":{"type":"string","title":"Body"},"type":{"type":"string","title":"Type","default":"info"},"is_active":{"type":"boolean","title":"Is Active","default":true},"starts_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Starts At"},"ends_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Ends At"}},"type":"object","required":["title","body"],"title":"AnnouncementBody"},"AnswerQuestionRequest":{"properties":{"answer":{"type":"string","minLength":1,"title":"Answer"}},"type":"object","required":["answer"],"title":"AnswerQuestionRequest"},"ApplicationCreate":{"properties":{"appraisal_id":{"type":"string","format":"uuid","title":"Appraisal Id"},"lender_id":{"type":"string","format":"uuid","title":"Lender Id"},"developer_name":{"type":"string","maxLength":255,"title":"Developer Name"},"exit_strategy":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Exit Strategy"}},"type":"object","required":["appraisal_id","lender_id","developer_name"],"title":"ApplicationCreate"},"ApplicationCreateRequest":{"properties":{"site_address":{"type":"string","title":"Site Address"},"postcode":{"type":"string","title":"Postcode"},"application_type":{"type":"string","title":"Application Type","default":"householder"},"uprn":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Uprn"},"title_number":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Title Number"},"site_area":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Site Area"},"lpa":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Lpa"},"lpa_code":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Lpa Code"},"proposal_desc":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Proposal Desc"},"existing_use":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Existing Use"},"proposed_use":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Proposed Use"},"unit_count":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Unit Count"},"storeys":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Storeys"},"gia_total":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Gia Total"},"access_desc":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Desc"},"parking_count":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Parking Count"},"conservation_area":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Conservation Area"},"conservation_area_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Conservation Area Name"},"flood_zone":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Flood Zone"},"listed_buildings":{"anyOf":[{"type":"object"},{"type":"null"}],"title":"Listed Buildings"},"green_belt":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Green Belt"},"sssi":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Sssi"},"tpo_trees":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Tpo Trees"},"article4":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Article4"},"local_plan_policies":{"anyOf":[{"type":"object"},{"type":"null"}],"title":"Local Plan Policies"},"planning_history":{"anyOf":[{"type":"object"},{"type":"null"}],"title":"Planning History"}},"type":"object","required":["site_address","postcode"],"title":"ApplicationCreateRequest"},"ApplicationStatusUpdate":{"properties":{"status":{"type":"string","title":"Status"},"agreed_loan":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Agreed Loan"},"agreed_rate":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Agreed Rate"},"agreed_term":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Agreed Term"}},"type":"object","required":["status"],"title":"ApplicationStatusUpdate"},"ApplicationUpdateRequest":{"properties":{"site_address":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Site Address"},"postcode":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Postcode"},"application_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Application Type"},"uprn":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Uprn"},"title_number":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Title Number"},"site_area":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Site Area"},"lpa":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Lpa"},"lpa_code":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Lpa Code"},"proposal_desc":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Proposal Desc"},"existing_use":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Existing Use"},"proposed_use":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Proposed Use"},"unit_count":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Unit Count"},"storeys":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Storeys"},"gia_total":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Gia Total"},"access_desc":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Desc"},"parking_count":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Parking Count"},"conservation_area":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Conservation Area"},"conservation_area_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Conservation Area Name"},"flood_zone":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Flood Zone"},"listed_buildings":{"anyOf":[{"type":"object"},{"type":"null"}],"title":"Listed Buildings"},"green_belt":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Green Belt"},"sssi":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Sssi"},"tpo_trees":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Tpo Trees"},"article4":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Article4"},"local_plan_policies":{"anyOf":[{"type":"object"},{"type":"null"}],"title":"Local Plan Policies"},"planning_history":{"anyOf":[{"type":"object"},{"type":"null"}],"title":"Planning History"},"status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Status"},"risk_assessment":{"anyOf":[{"type":"object"},{"type":"null"}],"title":"Risk Assessment"},"risk_level":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Risk Level"}},"type":"object","title":"ApplicationUpdateRequest"},"ApplyInterestResponse":{"properties":{"invoice_id":{"type":"string","format":"uuid","title":"Invoice Id"},"days_overdue":{"type":"integer","title":"Days Overdue"},"interest_rate":{"type":"number","title":"Interest Rate"},"interest_amount":{"type":"number","title":"Interest Amount"},"interest_accrued_total":{"type":"number","title":"Interest Accrued Total"},"new_amount_due":{"type":"number","title":"New Amount Due"}},"type":"object","required":["invoice_id","days_overdue","interest_rate","interest_amount","interest_accrued_total","new_amount_due"],"title":"ApplyInterestResponse"},"AppointmentCreate":{"properties":{"repair_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Repair Id"},"job_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Job Id"},"property_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Property Id"},"client_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Client Id"},"operative_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Operative Id"},"contractor_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Contractor Id"},"scheduled_date":{"type":"string","format":"date","title":"Scheduled Date"},"slot":{"$ref":"#/components/schemas/AppointmentSlot","default":"am"},"start_time":{"anyOf":[{"type":"string","format":"time"},{"type":"null"}],"title":"Start Time"},"end_time":{"anyOf":[{"type":"string","format":"time"},{"type":"null"}],"title":"End Time"},"duration_minutes":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Duration Minutes"},"contact_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Contact Name"},"contact_phone":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Contact Phone"},"access_notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Notes"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"}},"type":"object","required":["scheduled_date"],"title":"AppointmentCreate"},"AppointmentResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"company_id":{"type":"string","format":"uuid","title":"Company Id"},"repair_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Repair Id"},"job_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Job Id"},"property_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Property Id"},"client_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Client Id"},"operative_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Operative Id"},"contractor_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Contractor Id"},"scheduled_date":{"type":"string","format":"date","title":"Scheduled Date"},"slot":{"$ref":"#/components/schemas/AppointmentSlot"},"start_time":{"anyOf":[{"type":"string","format":"time"},{"type":"null"}],"title":"Start Time"},"end_time":{"anyOf":[{"type":"string","format":"time"},{"type":"null"}],"title":"End Time"},"duration_minutes":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Duration Minutes"},"status":{"$ref":"#/components/schemas/AppointmentStatus"},"confirmed_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Confirmed At"},"en_route_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"En Route At"},"arrived_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Arrived At"},"completed_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Completed At"},"no_access_reason":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"No Access Reason"},"no_access_evidence_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"No Access Evidence Url"},"contact_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Contact Name"},"contact_phone":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Contact Phone"},"access_notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Notes"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"window_label":{"type":"string","title":"Window Label","default":""},"created_at":{"type":"string","format":"date-time","title":"Created At"}},"type":"object","required":["id","company_id","repair_id","job_id","property_id","client_id","operative_id","contractor_id","scheduled_date","slot","start_time","end_time","duration_minutes","status","confirmed_at","en_route_at","arrived_at","completed_at","no_access_reason","no_access_evidence_url","contact_name","contact_phone","access_notes","notes","created_at"],"title":"AppointmentResponse"},"AppointmentSlot":{"type":"string","enum":["am","pm","all_day","avoid_school_run","timed"],"title":"AppointmentSlot","description":"Housing clients book by window, not by exact time."},"AppointmentStatus":{"type":"string","enum":["proposed","confirmed","en_route","arrived","completed","no_access","cancelled","rescheduled"],"title":"AppointmentStatus"},"AppointmentUpdate":{"properties":{"client_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Client Id"},"operative_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Operative Id"},"contractor_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Contractor Id"},"scheduled_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Scheduled Date"},"slot":{"anyOf":[{"$ref":"#/components/schemas/AppointmentSlot"},{"type":"null"}]},"start_time":{"anyOf":[{"type":"string","format":"time"},{"type":"null"}],"title":"Start Time"},"end_time":{"anyOf":[{"type":"string","format":"time"},{"type":"null"}],"title":"End Time"},"duration_minutes":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Duration Minutes"},"contact_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Contact Name"},"contact_phone":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Contact Phone"},"access_notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Notes"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"}},"type":"object","title":"AppointmentUpdate"},"AppraisalCreate":{"properties":{"name":{"type":"string","maxLength":255,"title":"Name"},"land_purchase_price":{"type":"integer","title":"Land Purchase Price","default":0},"sdlt":{"type":"integer","title":"Sdlt","default":0},"legal_fees_purchase":{"type":"integer","title":"Legal Fees Purchase","default":0},"survey_fees":{"type":"integer","title":"Survey Fees","default":0},"construction_cost":{"type":"integer","title":"Construction Cost","default":0},"professional_fees":{"type":"integer","title":"Professional Fees","default":0},"planning_costs":{"type":"integer","title":"Planning Costs","default":0},"contingency_pct":{"type":"number","title":"Contingency Pct","default":0.1},"loan_required":{"type":"integer","title":"Loan Required","default":0},"interest_rate":{"type":"number","title":"Interest Rate","default":0.0},"loan_term_months":{"type":"integer","title":"Loan Term Months","default":12},"arrangement_fee_pct":{"type":"number","title":"Arrangement Fee Pct","default":0.02},"gdv_total":{"type":"integer","title":"Gdv Total","default":0},"agent_fee_pct":{"type":"number","title":"Agent Fee Pct","default":0.015},"legal_fees_sale":{"type":"integer","title":"Legal Fees Sale","default":0},"marketing_costs":{"type":"integer","title":"Marketing Costs","default":0},"gdv_scenario":{"type":"string","title":"Gdv Scenario","default":"base"},"construction_cost_imported":{"type":"boolean","title":"Construction Cost Imported","default":false},"gdv_imported":{"type":"boolean","title":"Gdv Imported","default":false},"programme_imported":{"type":"boolean","title":"Programme Imported","default":false}},"type":"object","required":["name"],"title":"AppraisalCreate"},"AppraisalUpdate":{"properties":{"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name"},"land_purchase_price":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Land Purchase Price"},"sdlt":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Sdlt"},"legal_fees_purchase":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Legal Fees Purchase"},"survey_fees":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Survey Fees"},"construction_cost":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Construction Cost"},"professional_fees":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Professional Fees"},"planning_costs":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Planning Costs"},"contingency_pct":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Contingency Pct"},"loan_required":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Loan Required"},"interest_rate":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Interest Rate"},"loan_term_months":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Loan Term Months"},"arrangement_fee_pct":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Arrangement Fee Pct"},"gdv_total":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Gdv Total"},"agent_fee_pct":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Agent Fee Pct"},"legal_fees_sale":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Legal Fees Sale"},"marketing_costs":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Marketing Costs"},"gdv_scenario":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Gdv Scenario"},"status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Status"},"construction_cost_imported":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Construction Cost Imported"},"gdv_imported":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Gdv Imported"},"programme_imported":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Programme Imported"}},"type":"object","title":"AppraisalUpdate"},"AsbestosCreate":{"properties":{"property_address":{"type":"string","title":"Property Address"},"specific_location":{"type":"string","title":"Specific Location"},"survey_date":{"type":"string","format":"date","title":"Survey Date"},"surveyor":{"type":"string","title":"Surveyor"},"asbestos_type":{"type":"string","title":"Asbestos Type","default":"none_found"},"condition":{"type":"string","title":"Condition","default":"good"},"action_required":{"type":"string","title":"Action Required","default":"no_action"},"is_present":{"type":"boolean","title":"Is Present","default":true},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"job_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Job Id"}},"type":"object","required":["property_address","specific_location","survey_date","surveyor"],"title":"AsbestosCreate"},"AsbestosUpdate":{"properties":{"property_address":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Property Address"},"specific_location":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Specific Location"},"survey_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Survey Date"},"surveyor":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Surveyor"},"asbestos_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Asbestos Type"},"condition":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Condition"},"action_required":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Action Required"},"is_present":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Present"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"}},"type":"object","title":"AsbestosUpdate"},"AttendanceClockOut":{"properties":{"clock_out_at":{"type":"string","format":"date-time","title":"Clock Out At"},"break_minutes":{"type":"integer","minimum":0.0,"title":"Break Minutes","default":0},"latitude_out":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Latitude Out"},"longitude_out":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Longitude Out"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"}},"type":"object","required":["clock_out_at"],"title":"AttendanceClockOut"},"AttendanceRecordCreate":{"properties":{"worker_id":{"type":"string","format":"uuid","title":"Worker Id"},"job_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Job Id"},"clock_in_at":{"type":"string","format":"date-time","title":"Clock In At"},"latitude_in":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Latitude In"},"longitude_in":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Longitude In"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"}},"type":"object","required":["worker_id","clock_in_at"],"title":"AttendanceRecordCreate"},"AttendanceRecordResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"company_id":{"type":"string","format":"uuid","title":"Company Id"},"worker_id":{"type":"string","format":"uuid","title":"Worker Id"},"worker_name":{"type":"string","title":"Worker Name"},"job_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Job Id"},"job_number":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Job Number"},"clock_in_at":{"type":"string","format":"date-time","title":"Clock In At"},"clock_out_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Clock Out At"},"break_minutes":{"type":"integer","title":"Break Minutes"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"duration_minutes":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Duration Minutes"},"latitude_in":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Latitude In"},"longitude_in":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Longitude In"},"latitude_out":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Latitude Out"},"longitude_out":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Longitude Out"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"}},"type":"object","required":["id","company_id","worker_id","worker_name","job_id","job_number","clock_in_at","clock_out_at","break_minutes","notes","duration_minutes","latitude_in","longitude_in","latitude_out","longitude_out","created_at","updated_at"],"title":"AttendanceRecordResponse"},"AttendanceSummaryResponse":{"properties":{"worker_id":{"type":"string","format":"uuid","title":"Worker Id"},"worker_name":{"type":"string","title":"Worker Name"},"total_records":{"type":"integer","title":"Total Records"},"total_hours":{"type":"number","title":"Total Hours"},"records_this_week":{"type":"integer","title":"Records This Week"}},"type":"object","required":["worker_id","worker_name","total_records","total_hours","records_this_week"],"title":"AttendanceSummaryResponse"},"AuditLogResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"action":{"type":"string","title":"Action"},"resource_type":{"type":"string","title":"Resource Type"},"resource_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Resource Id"},"changes":{"anyOf":[{"type":"object"},{"type":"null"}],"title":"Changes"},"user_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"User Id"},"user_email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"User Email"},"created_at":{"type":"string","format":"date-time","title":"Created At"}},"type":"object","required":["id","action","resource_type","created_at"],"title":"AuditLogResponse"},"AvailabilityGridUpdate":{"properties":{"blocked_dates":{"items":{"type":"string","format":"date"},"type":"array","title":"Blocked Dates"}},"type":"object","required":["blocked_dates"],"title":"AvailabilityGridUpdate"},"BOMItemCreate":{"properties":{"description":{"type":"string","title":"Description"},"category":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Category"},"quantity":{"type":"number","title":"Quantity","default":1.0},"unit":{"type":"string","title":"Unit","default":"each"},"unit_price":{"type":"number","title":"Unit Price","default":0.0},"supplier_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Supplier Id"},"sort_order":{"type":"integer","title":"Sort Order","default":0}},"type":"object","required":["description"],"title":"BOMItemCreate"},"BOMItemUpdate":{"properties":{"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"category":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Category"},"quantity":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Quantity"},"unit":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Unit"},"unit_price":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Unit Price"},"supplier_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Supplier Id"},"is_ordered":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Ordered"},"sort_order":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Sort Order"}},"type":"object","title":"BOMItemUpdate"},"BadgeResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"scheme":{"type":"string","title":"Scheme"},"reference_number":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Reference Number"},"status":{"type":"string","title":"Status"},"awarded_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Awarded Date"},"expiry_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Expiry Date"},"is_verified":{"type":"boolean","title":"Is Verified"}},"type":"object","required":["id","scheme","reference_number","status","awarded_date","expiry_date","is_verified"],"title":"BadgeResponse"},"BidAnalyticsResponse":{"properties":{"total_bids":{"type":"integer","title":"Total Bids"},"bids_won":{"type":"integer","title":"Bids Won"},"pending_bids":{"type":"integer","title":"Pending Bids","default":0},"win_rate_pct":{"type":"number","title":"Win Rate Pct"},"avg_bid_amount":{"type":"number","title":"Avg Bid Amount"},"avg_winning_amount":{"type":"number","title":"Avg Winning Amount"},"by_trade":{"items":{"type":"object"},"type":"array","title":"By Trade"},"monthly_trend":{"items":{"type":"object"},"type":"array","title":"Monthly Trend"}},"type":"object","required":["total_bids","bids_won","win_rate_pct","avg_bid_amount","avg_winning_amount","by_trade","monthly_trend"],"title":"BidAnalyticsResponse"},"BidPreviewItem":{"properties":{"bid_id":{"type":"string","format":"uuid","title":"Bid Id"},"profile_id":{"type":"string","format":"uuid","title":"Profile Id"},"display_name":{"type":"string","title":"Display Name"},"trades":{"items":{"type":"string"},"type":"array","title":"Trades"},"avg_rating":{"type":"number","title":"Avg Rating"},"is_verified_estimark":{"type":"boolean","title":"Is Verified Estimark"},"is_boosted":{"type":"boolean","title":"Is Boosted"},"amount":{"type":"number","title":"Amount"},"status":{"type":"string","title":"Status"},"created_at":{"type":"string","format":"date-time","title":"Created At"}},"type":"object","required":["bid_id","profile_id","display_name","trades","avg_rating","is_verified_estimark","is_boosted","amount","status","created_at"],"title":"BidPreviewItem","description":"Bid summary shown to the job poster on the listing detail page."},"BidScoreBody":{"properties":{"criteria":{"anyOf":[{"items":{"type":"object"},"type":"array"},{"type":"null"}],"title":"Criteria"},"decision":{"type":"string","title":"Decision","default":"review"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"}},"type":"object","title":"BidScoreBody"},"Body_admin_reply_ticket_api_v1_admin_support_tickets__ticket_id__reply_post":{"properties":{"body":{"type":"string","title":"Body"},"file":{"anyOf":[{"type":"string","format":"binary"},{"type":"null"}],"title":"File"}},"type":"object","required":["body"],"title":"Body_admin_reply_ticket_api_v1_admin_support_tickets__ticket_id__reply_post"},"Body_admin_upload_favicon_api_v1_cms_admin_settings_favicon_post":{"properties":{"file":{"type":"string","format":"binary","title":"File"}},"type":"object","required":["file"],"title":"Body_admin_upload_favicon_api_v1_cms_admin_settings_favicon_post"},"Body_admin_upload_logo_api_v1_cms_admin_settings_logo_post":{"properties":{"file":{"type":"string","format":"binary","title":"File"}},"type":"object","required":["file"],"title":"Body_admin_upload_logo_api_v1_cms_admin_settings_logo_post"},"Body_admin_upload_media_api_v1_cms_admin_media_post":{"properties":{"file":{"type":"string","format":"binary","title":"File"}},"type":"object","required":["file"],"title":"Body_admin_upload_media_api_v1_cms_admin_media_post"},"Body_ai_generate_quote_api_v1_quotes_ai_generate_post":{"properties":{"text":{"type":"string","title":"Text"},"trade":{"type":"string","title":"Trade","default":"general"},"file":{"type":"string","format":"binary","title":"File"}},"type":"object","title":"Body_ai_generate_quote_api_v1_quotes_ai_generate_post"},"Body_contract_clause_analysis_api_v1_analytics_contract_analysis_post":{"properties":{"text":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Text"},"files":{"items":{"type":"string","format":"binary"},"type":"array","title":"Files","default":[]}},"type":"object","title":"Body_contract_clause_analysis_api_v1_analytics_contract_analysis_post"},"Body_create_support_ticket_api_v1_users_support_tickets_post":{"properties":{"subject":{"type":"string","title":"Subject"},"body":{"type":"string","title":"Body"},"priority":{"type":"string","title":"Priority","default":"medium"},"file":{"anyOf":[{"type":"string","format":"binary"},{"type":"null"}],"title":"File"}},"type":"object","required":["subject","body"],"title":"Body_create_support_ticket_api_v1_users_support_tickets_post"},"Body_google_drive_upload_api_v1_storage_google_drive_upload__job_id__post":{"properties":{"file":{"type":"string","format":"binary","title":"File"}},"type":"object","required":["file"],"title":"Body_google_drive_upload_api_v1_storage_google_drive_upload__job_id__post"},"Body_import_clients_api_v1_import_clients_post":{"properties":{"file":{"type":"string","format":"binary","title":"File"},"dry_run":{"type":"boolean","title":"Dry Run","default":true}},"type":"object","required":["file"],"title":"Body_import_clients_api_v1_import_clients_post"},"Body_import_jobs_api_v1_import_jobs_post":{"properties":{"file":{"type":"string","format":"binary","title":"File"},"dry_run":{"type":"boolean","title":"Dry Run","default":true}},"type":"object","required":["file"],"title":"Body_import_jobs_api_v1_import_jobs_post"},"Body_import_price_book_csv_api_v1_price_book_import_post":{"properties":{"file":{"type":"string","format":"binary","title":"File"}},"type":"object","required":["file"],"title":"Body_import_price_book_csv_api_v1_price_book_import_post"},"Body_import_sor_items_api_v1_sor_schedules__schedule_id__import_post":{"properties":{"file":{"type":"string","format":"binary","title":"File"}},"type":"object","required":["file"],"title":"Body_import_sor_items_api_v1_sor_schedules__schedule_id__import_post"},"Body_onedrive_upload_api_v1_storage_onedrive_upload__job_id__post":{"properties":{"file":{"type":"string","format":"binary","title":"File"}},"type":"object","required":["file"],"title":"Body_onedrive_upload_api_v1_storage_onedrive_upload__job_id__post"},"Body_reply_to_my_ticket_api_v1_users_support_tickets__ticket_id__reply_post":{"properties":{"body":{"type":"string","title":"Body"},"file":{"anyOf":[{"type":"string","format":"binary"},{"type":"null"}],"title":"File"}},"type":"object","required":["body"],"title":"Body_reply_to_my_ticket_api_v1_users_support_tickets__ticket_id__reply_post"},"Body_upload_attachment_api_v1_correspondence__entry_id__attachments_post":{"properties":{"file":{"type":"string","format":"binary","title":"File"}},"type":"object","required":["file"],"title":"Body_upload_attachment_api_v1_correspondence__entry_id__attachments_post"},"Body_upload_avatar_api_v1_auth_me_avatar_post":{"properties":{"file":{"type":"string","format":"binary","title":"File"}},"type":"object","required":["file"],"title":"Body_upload_avatar_api_v1_auth_me_avatar_post"},"Body_upload_company_logo_api_v1_companies_me_logo_post":{"properties":{"file":{"type":"string","format":"binary","title":"File"}},"type":"object","required":["file"],"title":"Body_upload_company_logo_api_v1_companies_me_logo_post"},"Body_upload_defect_photo_api_v1_defects_photo_post":{"properties":{"file":{"type":"string","format":"binary","title":"File"}},"type":"object","required":["file"],"title":"Body_upload_defect_photo_api_v1_defects_photo_post"},"Body_upload_document_api_v1_documents_upload_post":{"properties":{"file":{"type":"string","format":"binary","title":"File"},"related_type":{"type":"string","title":"Related Type"},"related_id":{"type":"string","title":"Related Id"}},"type":"object","required":["file","related_type","related_id"],"title":"Body_upload_document_api_v1_documents_upload_post"},"Body_upload_employee_document_api_v1_hr_employees__employee_id__documents_post":{"properties":{"file":{"type":"string","format":"binary","title":"File"}},"type":"object","required":["file"],"title":"Body_upload_employee_document_api_v1_hr_employees__employee_id__documents_post"},"Body_upload_employee_photo_api_v1_hr_employees__employee_id__photo_post":{"properties":{"file":{"type":"string","format":"binary","title":"File"}},"type":"object","required":["file"],"title":"Body_upload_employee_photo_api_v1_hr_employees__employee_id__photo_post"},"Body_upload_item_photo_api_v1_qa_checklists__checklist_id__items__item_id__photo_post":{"properties":{"file":{"type":"string","format":"binary","title":"File"}},"type":"object","required":["file"],"title":"Body_upload_item_photo_api_v1_qa_checklists__checklist_id__items__item_id__photo_post"},"Body_upload_photo_api_v1_photos_post":{"properties":{"job_id":{"type":"string","format":"uuid","title":"Job Id"},"file":{"type":"string","format":"binary","title":"File"},"caption":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Caption"},"location":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Location"},"trade":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Trade"},"taken_at":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Taken At"},"album_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Album Id"},"before_after":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Before After"},"comparison_group":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Comparison Group"},"is_client_visible":{"type":"boolean","title":"Is Client Visible","default":false}},"type":"object","required":["job_id","file"],"title":"Body_upload_photo_api_v1_photos_post"},"Body_upload_qualification_document_api_v1_training_qualifications__qual_id__document_post":{"properties":{"file":{"type":"string","format":"binary","title":"File"}},"type":"object","required":["file"],"title":"Body_upload_qualification_document_api_v1_training_qualifications__qual_id__document_post"},"Body_upload_receipt_api_v1_expenses_receipts_post":{"properties":{"file":{"type":"string","format":"binary","title":"File"}},"type":"object","required":["file"],"title":"Body_upload_receipt_api_v1_expenses_receipts_post"},"Body_upload_revision_api_v1_drawings__drawing_id__revisions_post":{"properties":{"file":{"type":"string","format":"binary","title":"File"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"issue_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Issue Date"},"reason_for_issue":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Reason For Issue"}},"type":"object","required":["file"],"title":"Body_upload_revision_api_v1_drawings__drawing_id__revisions_post"},"Body_upload_rfi_attachment_api_v1_rfis__rfi_id__attachments_post":{"properties":{"file":{"type":"string","format":"binary","title":"File"}},"type":"object","required":["file"],"title":"Body_upload_rfi_attachment_api_v1_rfis__rfi_id__attachments_post"},"Body_upload_screenshot_api_v1_help_admin_articles__article_id__screenshots_post":{"properties":{"file":{"type":"string","format":"binary","title":"File"},"caption":{"type":"string","title":"Caption","default":""}},"type":"object","required":["file"],"title":"Body_upload_screenshot_api_v1_help_admin_articles__article_id__screenshots_post"},"Body_upload_tender_document_api_v1_tender_intelligence__tender_id__documents_post":{"properties":{"file":{"type":"string","format":"binary","title":"File"}},"type":"object","required":["file"],"title":"Body_upload_tender_document_api_v1_tender_intelligence__tender_id__documents_post"},"BudgetStatus":{"type":"string","enum":["draft","active","superseded"],"title":"BudgetStatus"},"BulkAssignIn":{"properties":{"ids":{"items":{"type":"string","format":"uuid"},"type":"array","title":"Ids"},"assigned_to":{"type":"string","title":"Assigned To"}},"type":"object","required":["ids","assigned_to"],"title":"BulkAssignIn"},"BulkClientMergeIn":{"properties":{"keep_id":{"type":"string","format":"uuid","title":"Keep Id"},"merge_ids":{"items":{"type":"string","format":"uuid"},"type":"array","title":"Merge Ids"}},"type":"object","required":["keep_id","merge_ids"],"title":"BulkClientMergeIn"},"BulkCompanyActionBody":{"properties":{"company_ids":{"items":{"type":"string"},"type":"array","title":"Company Ids"},"action":{"type":"string","title":"Action"}},"type":"object","required":["company_ids","action"],"title":"BulkCompanyActionBody"},"BulkIdsIn":{"properties":{"ids":{"items":{"type":"string","format":"uuid"},"type":"array","title":"Ids"}},"type":"object","required":["ids"],"title":"BulkIdsIn"},"BulkListingActionBody":{"properties":{"listing_ids":{"items":{"type":"string"},"type":"array","title":"Listing Ids"},"action":{"type":"string","title":"Action"}},"type":"object","required":["listing_ids","action"],"title":"BulkListingActionBody"},"BulkModuleBody":{"properties":{"company_ids":{"items":{"type":"string"},"type":"array","title":"Company Ids"},"module_key":{"type":"string","title":"Module Key"},"action":{"type":"string","title":"Action"}},"type":"object","required":["company_ids","module_key","action"],"title":"BulkModuleBody"},"BulkRejectIn":{"properties":{"ids":{"items":{"type":"string","format":"uuid"},"type":"array","title":"Ids"},"reason":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Reason"}},"type":"object","required":["ids"],"title":"BulkRejectIn"},"BulkRequest":{"properties":{"action":{"type":"string","title":"Action"},"ids":{"items":{"type":"string","format":"uuid"},"type":"array","title":"Ids"},"payload":{"anyOf":[{"type":"object"},{"type":"null"}],"title":"Payload"}},"type":"object","required":["action","ids"],"title":"BulkRequest"},"BulkUserActionBody":{"properties":{"user_ids":{"items":{"type":"string"},"type":"array","title":"User Ids"},"action":{"type":"string","title":"Action"},"source":{"type":"string","title":"Source","default":"estimark"}},"type":"object","required":["user_ids","action"],"title":"BulkUserActionBody"},"CDMProjectCreate":{"properties":{"title":{"type":"string","title":"Title"},"job_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Job Id"},"f10_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"F10 Id"},"is_notifiable":{"type":"boolean","title":"Is Notifiable","default":false},"project_description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Project Description"},"project_start":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Project Start"},"project_end":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Project End"},"construction_start":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Construction Start"},"principal_designer_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Principal Designer Name"},"principal_designer_company":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Principal Designer Company"},"principal_contractor_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Principal Contractor Name"},"principal_contractor_company":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Principal Contractor Company"},"estimated_duration_weeks":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Estimated Duration Weeks"},"max_workers":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Max Workers"}},"type":"object","required":["title"],"title":"CDMProjectCreate"},"CDMProjectResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"company_id":{"type":"string","format":"uuid","title":"Company Id"},"job_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Job Id"},"f10_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"F10 Id"},"title":{"type":"string","title":"Title"},"is_notifiable":{"type":"boolean","title":"Is Notifiable"},"project_description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Project Description"},"project_start":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Project Start"},"project_end":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Project End"},"construction_start":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Construction Start"},"principal_designer_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Principal Designer Name"},"principal_designer_company":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Principal Designer Company"},"principal_contractor_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Principal Contractor Name"},"principal_contractor_company":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Principal Contractor Company"},"estimated_duration_weeks":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Estimated Duration Weeks"},"max_workers":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Max Workers"},"pre_construction_info":{"type":"object","title":"Pre Construction Info"},"construction_phase_plan":{"type":"object","title":"Construction Phase Plan"},"hs_file":{"type":"object","title":"Hs File"},"status":{"type":"string","title":"Status"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"}},"type":"object","required":["id","company_id","job_id","f10_id","title","is_notifiable","project_description","project_start","project_end","construction_start","principal_designer_name","principal_designer_company","principal_contractor_name","principal_contractor_company","estimated_duration_weeks","max_workers","pre_construction_info","construction_phase_plan","hs_file","status","created_at","updated_at"],"title":"CDMProjectResponse"},"CDMProjectUpdate":{"properties":{"title":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Title"},"job_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Job Id"},"f10_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"F10 Id"},"is_notifiable":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Notifiable"},"project_description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Project Description"},"project_start":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Project Start"},"project_end":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Project End"},"construction_start":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Construction Start"},"principal_designer_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Principal Designer Name"},"principal_designer_company":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Principal Designer Company"},"principal_contractor_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Principal Contractor Name"},"principal_contractor_company":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Principal Contractor Company"},"estimated_duration_weeks":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Estimated Duration Weeks"},"max_workers":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Max Workers"},"status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Status"}},"type":"object","title":"CDMProjectUpdate"},"CDMSectionUpdate":{"properties":{"data":{"type":"object","title":"Data"}},"type":"object","required":["data"],"title":"CDMSectionUpdate"},"CISDeductionCreate":{"properties":{"subcontractor_id":{"type":"string","format":"uuid","title":"Subcontractor Id"},"purchase_order_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Purchase Order Id"},"period_month":{"anyOf":[{"type":"integer","maximum":12.0,"minimum":1.0},{"type":"null"}],"title":"Period Month"},"period_year":{"anyOf":[{"type":"integer","minimum":2000.0},{"type":"null"}],"title":"Period Year"},"payment_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Payment Date"},"gross_payment":{"type":"number","exclusiveMinimum":0.0,"title":"Gross Payment","description":"The whole payment, before any deduction."},"materials_cost":{"type":"number","minimum":0.0,"title":"Materials Cost","default":0.0},"vat_amount":{"type":"number","minimum":0.0,"title":"Vat Amount","default":0.0},"plant_hire_cost":{"type":"number","minimum":0.0,"title":"Plant Hire Cost","default":0.0},"other_excluded":{"type":"number","minimum":0.0,"title":"Other Excluded","description":"CITB levy, fuel and other allowable exclusions.","default":0.0},"deduction_rate":{"type":"number","maximum":100.0,"minimum":0.0,"title":"Deduction Rate"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"}},"type":"object","required":["subcontractor_id","gross_payment","deduction_rate"],"title":"CISDeductionCreate"},"CISDeductionResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"company_id":{"type":"string","format":"uuid","title":"Company Id"},"monthly_return_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Monthly Return Id"},"purchase_order_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Purchase Order Id"},"subcontractor_id":{"type":"string","format":"uuid","title":"Subcontractor Id"},"subcontractor_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Subcontractor Name"},"period_month":{"type":"integer","title":"Period Month"},"period_year":{"type":"integer","title":"Period Year"},"payment_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Payment Date"},"period_label":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Period Label"},"gross_payment":{"type":"number","title":"Gross Payment"},"materials_cost":{"type":"number","title":"Materials Cost","default":0.0},"vat_amount":{"type":"number","title":"Vat Amount","default":0.0},"plant_hire_cost":{"type":"number","title":"Plant Hire Cost","default":0.0},"other_excluded":{"type":"number","title":"Other Excluded","default":0.0},"labour_amount":{"type":"number","title":"Labour Amount","default":0.0},"deduction_rate":{"type":"number","title":"Deduction Rate"},"deduction_amount":{"type":"number","title":"Deduction Amount"},"net_payment":{"type":"number","title":"Net Payment"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"}},"type":"object","required":["id","company_id","monthly_return_id","purchase_order_id","subcontractor_id","period_month","period_year","gross_payment","deduction_rate","deduction_amount","net_payment","description","created_at","updated_at"],"title":"CISDeductionResponse"},"CISMonthlyReturnDetail":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"company_id":{"type":"string","format":"uuid","title":"Company Id"},"tax_month":{"type":"integer","title":"Tax Month"},"tax_year":{"type":"integer","title":"Tax Year"},"status":{"type":"string","title":"Status"},"total_gross":{"type":"number","title":"Total Gross"},"total_materials":{"type":"number","title":"Total Materials","default":0.0},"total_deductions":{"type":"number","title":"Total Deductions"},"submitted_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Submitted At"},"hmrc_reference":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Hmrc Reference"},"employment_status_declared":{"type":"boolean","title":"Employment Status Declared","default":false},"verification_declared":{"type":"boolean","title":"Verification Declared","default":false},"is_nil_return":{"type":"boolean","title":"Is Nil Return","default":false},"inactivity_declared":{"type":"boolean","title":"Inactivity Declared","default":false},"submission_method":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Submission Method"},"period_label":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Period Label"},"due_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Due Date"},"is_overdue":{"type":"boolean","title":"Is Overdue","default":false},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"},"deductions":{"items":{"$ref":"#/components/schemas/CISDeductionResponse"},"type":"array","title":"Deductions","default":[]}},"type":"object","required":["id","company_id","tax_month","tax_year","status","total_gross","total_deductions","submitted_at","hmrc_reference","created_at","updated_at"],"title":"CISMonthlyReturnDetail"},"CISMonthlyReturnSummary":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"company_id":{"type":"string","format":"uuid","title":"Company Id"},"tax_month":{"type":"integer","title":"Tax Month"},"tax_year":{"type":"integer","title":"Tax Year"},"status":{"type":"string","title":"Status"},"total_gross":{"type":"number","title":"Total Gross"},"total_materials":{"type":"number","title":"Total Materials","default":0.0},"total_deductions":{"type":"number","title":"Total Deductions"},"submitted_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Submitted At"},"hmrc_reference":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Hmrc Reference"},"employment_status_declared":{"type":"boolean","title":"Employment Status Declared","default":false},"verification_declared":{"type":"boolean","title":"Verification Declared","default":false},"is_nil_return":{"type":"boolean","title":"Is Nil Return","default":false},"inactivity_declared":{"type":"boolean","title":"Inactivity Declared","default":false},"submission_method":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Submission Method"},"period_label":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Period Label"},"due_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Due Date"},"is_overdue":{"type":"boolean","title":"Is Overdue","default":false},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"}},"type":"object","required":["id","company_id","tax_month","tax_year","status","total_gross","total_deductions","submitted_at","hmrc_reference","created_at","updated_at"],"title":"CISMonthlyReturnSummary"},"CISSettingsResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"company_id":{"type":"string","format":"uuid","title":"Company Id"},"cis_enabled":{"type":"boolean","title":"Cis Enabled"},"contractor_utr":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Contractor Utr"},"hmrc_client_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Hmrc Client Id"},"hmrc_environment":{"type":"string","title":"Hmrc Environment"},"standard_deduction_rate":{"type":"number","title":"Standard Deduction Rate"},"higher_deduction_rate":{"type":"number","title":"Higher Deduction Rate"},"hmrc_token_expires_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Hmrc Token Expires At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"}},"type":"object","required":["id","company_id","cis_enabled","contractor_utr","hmrc_client_id","hmrc_environment","standard_deduction_rate","higher_deduction_rate","hmrc_token_expires_at","updated_at"],"title":"CISSettingsResponse"},"CISSettingsUpdate":{"properties":{"cis_enabled":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Cis Enabled"},"contractor_utr":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Contractor Utr"},"hmrc_client_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Hmrc Client Id"},"hmrc_client_secret":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Hmrc Client Secret"},"hmrc_environment":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Hmrc Environment"},"standard_deduction_rate":{"anyOf":[{"type":"number","maximum":100.0,"minimum":0.0},{"type":"null"}],"title":"Standard Deduction Rate"},"higher_deduction_rate":{"anyOf":[{"type":"number","maximum":100.0,"minimum":0.0},{"type":"null"}],"title":"Higher Deduction Rate"}},"type":"object","title":"CISSettingsUpdate"},"CISSubcontractorResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"name":{"type":"string","title":"Name"},"trade":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Trade"},"email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Email"},"cis_registered":{"type":"boolean","title":"Cis Registered"},"cis_utr":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cis Utr"},"cis_verification_number":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cis Verification Number"},"cis_verification_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Cis Verification Date"},"cis_tax_treatment":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cis Tax Treatment"},"cis_hmrc_verified":{"type":"boolean","title":"Cis Hmrc Verified"}},"type":"object","required":["id","name","trade","email","cis_registered","cis_utr","cis_verification_number","cis_verification_date","cis_tax_treatment","cis_hmrc_verified"],"title":"CISSubcontractorResponse"},"CISSubcontractorUpdate":{"properties":{"cis_registered":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Cis Registered"},"cis_utr":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cis Utr"},"cis_verification_number":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cis Verification Number"},"cis_verification_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Cis Verification Date"},"cis_tax_treatment":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cis Tax Treatment"},"cis_hmrc_verified":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Cis Hmrc Verified"}},"type":"object","title":"CISSubcontractorUpdate"},"CISVerifyRequest":{"properties":{"contractor_utr":{"type":"string","maxLength":10,"minLength":10,"title":"Contractor Utr"}},"type":"object","required":["contractor_utr"],"title":"CISVerifyRequest"},"CMSGlobalSettingsResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"site_name":{"type":"string","title":"Site Name"},"tagline":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Tagline"},"primary_color":{"type":"string","title":"Primary Color"},"secondary_color":{"type":"string","title":"Secondary Color"},"accent_color":{"type":"string","title":"Accent Color"},"background_color":{"type":"string","title":"Background Color"},"font_family_heading":{"type":"string","title":"Font Family Heading"},"font_family_body":{"type":"string","title":"Font Family Body"},"logo_storage_path":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Logo Storage Path"},"favicon_storage_path":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Favicon Storage Path"},"nav_links":{"items":{"type":"object"},"type":"array","title":"Nav Links"},"footer_columns":{"items":{"type":"object"},"type":"array","title":"Footer Columns"},"social_links":{"type":"object","title":"Social Links"},"analytics_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Analytics Id"},"custom_head_html":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Custom Head Html"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"},"logo_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Logo Url"},"favicon_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Favicon Url"}},"type":"object","required":["id","site_name","tagline","primary_color","secondary_color","accent_color","background_color","font_family_heading","font_family_body","logo_storage_path","favicon_storage_path","nav_links","footer_columns","social_links","analytics_id","custom_head_html","updated_at"],"title":"CMSGlobalSettingsResponse"},"CMSGlobalSettingsUpdate":{"properties":{"site_name":{"anyOf":[{"type":"string","maxLength":200},{"type":"null"}],"title":"Site Name"},"tagline":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Tagline"},"primary_color":{"anyOf":[{"type":"string","maxLength":20},{"type":"null"}],"title":"Primary Color"},"secondary_color":{"anyOf":[{"type":"string","maxLength":20},{"type":"null"}],"title":"Secondary Color"},"accent_color":{"anyOf":[{"type":"string","maxLength":20},{"type":"null"}],"title":"Accent Color"},"background_color":{"anyOf":[{"type":"string","maxLength":20},{"type":"null"}],"title":"Background Color"},"font_family_heading":{"anyOf":[{"type":"string","maxLength":100},{"type":"null"}],"title":"Font Family Heading"},"font_family_body":{"anyOf":[{"type":"string","maxLength":100},{"type":"null"}],"title":"Font Family Body"},"nav_links":{"anyOf":[{"items":{"type":"object"},"type":"array"},{"type":"null"}],"title":"Nav Links"},"footer_columns":{"anyOf":[{"items":{"type":"object"},"type":"array"},{"type":"null"}],"title":"Footer Columns"},"social_links":{"anyOf":[{"type":"object"},{"type":"null"}],"title":"Social Links"},"analytics_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Analytics Id"},"custom_head_html":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Custom Head Html"}},"type":"object","title":"CMSGlobalSettingsUpdate"},"CMSMediaResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"filename":{"type":"string","title":"Filename"},"storage_path":{"type":"string","title":"Storage Path"},"mime_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Mime Type"},"size_bytes":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Size Bytes"},"width":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Width"},"height":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Height"},"alt_text":{"type":"string","title":"Alt Text"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"url":{"type":"string","title":"Url","default":""}},"type":"object","required":["id","filename","storage_path","mime_type","size_bytes","width","height","alt_text","created_at"],"title":"CMSMediaResponse"},"CMSPageCreate":{"properties":{"title":{"type":"string","maxLength":200,"minLength":1,"title":"Title"},"slug":{"type":"string","maxLength":200,"minLength":1,"title":"Slug"},"page_type":{"type":"string","title":"Page Type","default":"page"},"content":{"items":{},"type":"array","title":"Content","default":[]},"meta_title":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Meta Title"},"meta_description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Meta Description"},"excerpt":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Excerpt"},"author":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Author"},"published_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Published At"},"hero_image_path":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Hero Image Path"},"tags":{"items":{"type":"string"},"type":"array","title":"Tags","default":[]},"canonical_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Canonical Url"},"noindex":{"type":"boolean","title":"Noindex","default":false},"faqs":{"items":{},"type":"array","title":"Faqs","default":[]}},"type":"object","required":["title","slug"],"title":"CMSPageCreate"},"CMSPageDetail":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"title":{"type":"string","title":"Title"},"slug":{"type":"string","title":"Slug"},"meta_title":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Meta Title"},"is_published":{"type":"boolean","title":"Is Published"},"is_home":{"type":"boolean","title":"Is Home"},"page_type":{"type":"string","title":"Page Type"},"excerpt":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Excerpt"},"author":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Author"},"published_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Published At"},"hero_image_path":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Hero Image Path"},"tags":{"items":{"type":"string"},"type":"array","title":"Tags","default":[]},"noindex":{"type":"boolean","title":"Noindex","default":false},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"},"meta_description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Meta Description"},"content":{"items":{},"type":"array","title":"Content"},"canonical_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Canonical Url"},"faqs":{"items":{},"type":"array","title":"Faqs","default":[]}},"type":"object","required":["id","title","slug","meta_title","is_published","is_home","page_type","created_at","updated_at","meta_description","content"],"title":"CMSPageDetail"},"CMSPageSummary":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"title":{"type":"string","title":"Title"},"slug":{"type":"string","title":"Slug"},"meta_title":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Meta Title"},"is_published":{"type":"boolean","title":"Is Published"},"is_home":{"type":"boolean","title":"Is Home"},"page_type":{"type":"string","title":"Page Type"},"excerpt":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Excerpt"},"author":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Author"},"published_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Published At"},"hero_image_path":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Hero Image Path"},"tags":{"items":{"type":"string"},"type":"array","title":"Tags","default":[]},"noindex":{"type":"boolean","title":"Noindex","default":false},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"}},"type":"object","required":["id","title","slug","meta_title","is_published","is_home","page_type","created_at","updated_at"],"title":"CMSPageSummary"},"CMSPageUpdate":{"properties":{"title":{"anyOf":[{"type":"string","maxLength":200,"minLength":1},{"type":"null"}],"title":"Title"},"slug":{"anyOf":[{"type":"string","maxLength":200,"minLength":1},{"type":"null"}],"title":"Slug"},"meta_title":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Meta Title"},"meta_description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Meta Description"},"is_published":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Published"},"is_home":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Home"},"page_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Page Type"},"content":{"anyOf":[{"items":{},"type":"array"},{"type":"null"}],"title":"Content"},"excerpt":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Excerpt"},"author":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Author"},"published_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Published At"},"hero_image_path":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Hero Image Path"},"tags":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Tags"},"canonical_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Canonical Url"},"noindex":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Noindex"},"faqs":{"anyOf":[{"items":{},"type":"array"},{"type":"null"}],"title":"Faqs"}},"type":"object","title":"CMSPageUpdate"},"COSHHIn":{"properties":{"job_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Job Id"},"substance_name":{"type":"string","title":"Substance Name"},"manufacturer":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Manufacturer"},"cas_number":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cas Number"},"hazard_classification":{"type":"string","title":"Hazard Classification"},"risk_level":{"$ref":"#/components/schemas/COSHHRisk","default":"low"},"control_measures":{"type":"string","title":"Control Measures"},"ppe_required":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Ppe Required"},"sds_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Sds Url"},"review_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Review Date"}},"type":"object","required":["substance_name","hazard_classification","control_measures"],"title":"COSHHIn"},"COSHHPatch":{"properties":{"substance_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Substance Name"},"manufacturer":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Manufacturer"},"cas_number":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cas Number"},"hazard_classification":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Hazard Classification"},"risk_level":{"anyOf":[{"$ref":"#/components/schemas/COSHHRisk"},{"type":"null"}]},"control_measures":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Control Measures"},"ppe_required":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Ppe Required"},"sds_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Sds Url"},"review_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Review Date"},"is_active":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Active"}},"type":"object","title":"COSHHPatch"},"COSHHRisk":{"type":"string","enum":["low","medium","high"],"title":"COSHHRisk"},"CSCSVerifyRequest":{"properties":{"date_of_birth":{"type":"string","title":"Date Of Birth"}},"type":"object","required":["date_of_birth"],"title":"CSCSVerifyRequest"},"CVRReportResponse":{"properties":{"job_id":{"type":"string","format":"uuid","title":"Job Id"},"job_number":{"type":"string","title":"Job Number"},"title":{"type":"string","title":"Title"},"period_end":{"type":"string","format":"date","title":"Period End"},"contract_value":{"type":"number","title":"Contract Value"},"approved_variations":{"type":"number","title":"Approved Variations"},"revised_contract_value":{"type":"number","title":"Revised Contract Value"},"value_certified":{"type":"number","title":"Value Certified"},"value_to_complete":{"type":"number","title":"Value To Complete"},"actual_cost":{"type":"number","title":"Actual Cost"},"committed_cost":{"type":"number","title":"Committed Cost"},"cost_to_complete":{"type":"number","title":"Cost To Complete"},"forecast_final_cost":{"type":"number","title":"Forecast Final Cost"},"budget":{"type":"number","title":"Budget"},"budget_source":{"type":"string","title":"Budget Source"},"variance_to_budget":{"type":"number","title":"Variance To Budget"},"margin_to_date":{"type":"number","title":"Margin To Date"},"margin_to_date_pct":{"type":"number","title":"Margin To Date Pct"},"forecast_margin":{"type":"number","title":"Forecast Margin"},"forecast_margin_pct":{"type":"number","title":"Forecast Margin Pct"},"cost_by_category":{"additionalProperties":{"type":"number"},"type":"object","title":"Cost By Category","default":{}}},"type":"object","required":["job_id","job_number","title","period_end","contract_value","approved_variations","revised_contract_value","value_certified","value_to_complete","actual_cost","committed_cost","cost_to_complete","forecast_final_cost","budget","budget_source","variance_to_budget","margin_to_date","margin_to_date_pct","forecast_margin","forecast_margin_pct"],"title":"CVRReportResponse","description":"Cost value reconciliation for one job at a point in time."},"CalendarJobResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"title":{"type":"string","title":"Title"},"job_number":{"type":"string","title":"Job Number"},"status":{"$ref":"#/components/schemas/JobStatus"},"start_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Start Date"},"end_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"End Date"}},"type":"object","required":["id","title","job_number","status","start_date","end_date"],"title":"CalendarJobResponse"},"CarbonEntryIn":{"properties":{"scope":{"type":"integer","title":"Scope"},"category":{"type":"string","title":"Category"},"description":{"type":"string","title":"Description"},"quantity":{"type":"number","title":"Quantity"},"unit":{"type":"string","title":"Unit"},"emission_factor":{"type":"number","title":"Emission Factor"}},"type":"object","required":["scope","category","description","quantity","unit","emission_factor"],"title":"CarbonEntryIn"},"CarbonEntryPatch":{"properties":{"scope":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Scope"},"category":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Category"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"quantity":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Quantity"},"unit":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Unit"},"emission_factor":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Emission Factor"}},"type":"object","title":"CarbonEntryPatch"},"CarbonProjectIn":{"properties":{"job_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Job Id"},"title":{"type":"string","title":"Title"},"reporting_period_start":{"type":"string","title":"Reporting Period Start"},"reporting_period_end":{"type":"string","title":"Reporting Period End"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"}},"type":"object","required":["title","reporting_period_start","reporting_period_end"],"title":"CarbonProjectIn"},"CarbonProjectPatch":{"properties":{"title":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Title"},"reporting_period_start":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Reporting Period Start"},"reporting_period_end":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Reporting Period End"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"}},"type":"object","title":"CarbonProjectPatch"},"CashFlowForecastCreate":{"properties":{"job_id":{"type":"string","format":"uuid","title":"Job Id"},"distribution_type":{"type":"string","title":"Distribution Type","default":"s_curve"}},"type":"object","required":["job_id"],"title":"CashFlowForecastCreate"},"CashFlowForecastDetail":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"job_id":{"type":"string","format":"uuid","title":"Job Id"},"distribution_type":{"type":"string","title":"Distribution Type"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"periods":{"items":{"$ref":"#/components/schemas/CashFlowPeriodResponse"},"type":"array","title":"Periods"},"job_number":{"type":"string","title":"Job Number"},"job_title":{"type":"string","title":"Job Title"},"contract_value":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Contract Value"},"start_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Start Date"},"end_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"End Date"},"created_at":{"type":"string","format":"date-time","title":"Created At"}},"type":"object","required":["id","job_id","distribution_type","notes","periods","job_number","job_title","contract_value","start_date","end_date","created_at"],"title":"CashFlowForecastDetail"},"CashFlowForecastSummary":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"job_id":{"type":"string","format":"uuid","title":"Job Id"},"distribution_type":{"type":"string","title":"Distribution Type"},"job_number":{"type":"string","title":"Job Number"},"job_title":{"type":"string","title":"Job Title"},"contract_value":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Contract Value"},"period_count":{"type":"integer","title":"Period Count"},"created_at":{"type":"string","format":"date-time","title":"Created At"}},"type":"object","required":["id","job_id","distribution_type","job_number","job_title","contract_value","period_count","created_at"],"title":"CashFlowForecastSummary"},"CashFlowPeriodResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"forecast_id":{"type":"string","format":"uuid","title":"Forecast Id"},"period_month":{"type":"string","format":"date","title":"Period Month"},"forecast_income":{"type":"string","title":"Forecast Income"},"forecast_cost":{"type":"string","title":"Forecast Cost"},"actual_income":{"type":"number","title":"Actual Income"},"actual_cost":{"type":"number","title":"Actual Cost"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"}},"type":"object","required":["id","forecast_id","period_month","forecast_income","forecast_cost","actual_income","actual_cost","notes"],"title":"CashFlowPeriodResponse"},"CashFlowPeriodUpdate":{"properties":{"forecast_income":{"anyOf":[{"type":"number"},{"type":"string"},{"type":"null"}],"title":"Forecast Income"},"forecast_cost":{"anyOf":[{"type":"number"},{"type":"string"},{"type":"null"}],"title":"Forecast Cost"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"}},"type":"object","title":"CashFlowPeriodUpdate"},"CategoryCountResponse":{"properties":{"category":{"type":"string","title":"Category"},"count":{"type":"integer","title":"Count"}},"type":"object","required":["category","count"],"title":"CategoryCountResponse"},"CertTypeEnum":{"type":"string","enum":["eic","eicr","meiwc","cp12","gas_soundness","pat","other"],"title":"CertTypeEnum"},"CertificateCreate":{"properties":{"cert_type":{"$ref":"#/components/schemas/CertTypeEnum"},"cert_number":{"type":"string","title":"Cert Number"},"issued_date":{"type":"string","format":"date","title":"Issued Date"},"expiry_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Expiry Date"},"property_address":{"type":"string","title":"Property Address"},"issued_by":{"type":"string","title":"Issued By"},"is_satisfactory":{"type":"boolean","title":"Is Satisfactory","default":true},"test_results":{"type":"object","title":"Test Results","default":{}},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"job_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Job Id"}},"type":"object","required":["cert_type","cert_number","issued_date","property_address","issued_by"],"title":"CertificateCreate"},"CertificateUpdate":{"properties":{"cert_number":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cert Number"},"issued_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Issued Date"},"expiry_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Expiry Date"},"property_address":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Property Address"},"issued_by":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Issued By"},"is_satisfactory":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Satisfactory"},"test_results":{"anyOf":[{"type":"object"},{"type":"null"}],"title":"Test Results"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"}},"type":"object","title":"CertificateUpdate"},"CertifyRequest":{"properties":{"certified_amount":{"type":"number","minimum":0.0,"title":"Certified Amount"},"certified_date":{"type":"string","format":"date","title":"Certified Date"},"certified_by":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Certified By"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"}},"type":"object","required":["certified_amount","certified_date"],"title":"CertifyRequest"},"ChangePlanRequest":{"properties":{"plan":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Plan"},"billing_interval":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Billing Interval"}},"type":"object","title":"ChangePlanRequest"},"ChannelCreate":{"properties":{"name":{"type":"string","title":"Name"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"job_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Job Id"}},"type":"object","required":["name"],"title":"ChannelCreate"},"ChannelResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"company_id":{"type":"string","format":"uuid","title":"Company Id"},"job_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Job Id"},"name":{"type":"string","title":"Name"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"is_general":{"type":"boolean","title":"Is General"},"archived_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Archived At"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"last_message_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Message At"},"last_message_preview":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Last Message Preview"}},"type":"object","required":["id","company_id","job_id","name","description","is_general","archived_at","created_at"],"title":"ChannelResponse"},"ChannelUpdate":{"properties":{"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"archived":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Archived"}},"type":"object","title":"ChannelUpdate"},"ChatContext":{"properties":{"job_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Job Id"},"quote_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Quote Id"}},"type":"object","title":"ChatContext"},"ChatMessageIn":{"properties":{"message":{"type":"string","title":"Message"},"context":{"$ref":"#/components/schemas/ChatContext","default":{}}},"type":"object","required":["message"],"title":"ChatMessageIn"},"ClientContactCreate":{"properties":{"name":{"type":"string","maxLength":255,"minLength":1,"title":"Name"},"role":{"anyOf":[{"type":"string","maxLength":100},{"type":"null"}],"title":"Role"},"email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Email"},"phone":{"anyOf":[{"type":"string","maxLength":50},{"type":"null"}],"title":"Phone"},"is_primary":{"type":"boolean","title":"Is Primary","default":false},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"}},"type":"object","required":["name"],"title":"ClientContactCreate"},"ClientContactResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"client_id":{"type":"string","format":"uuid","title":"Client Id"},"name":{"type":"string","title":"Name"},"role":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Role"},"email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Email"},"phone":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Phone"},"is_primary":{"type":"boolean","title":"Is Primary"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"}},"type":"object","required":["id","client_id","name","role","email","phone","is_primary","notes","created_at","updated_at"],"title":"ClientContactResponse"},"ClientContactUpdate":{"properties":{"name":{"anyOf":[{"type":"string","maxLength":255,"minLength":1},{"type":"null"}],"title":"Name"},"role":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Role"},"email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Email"},"phone":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Phone"},"is_primary":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Primary"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"}},"type":"object","title":"ClientContactUpdate"},"ClientCreateRequest":{"properties":{"name":{"type":"string","maxLength":255,"minLength":1,"title":"Name"},"email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Email"},"phone":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Phone"},"address":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Address"},"city":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"City"},"state":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"State"},"postcode":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Postcode"},"client_type":{"$ref":"#/components/schemas/ClientType","default":"residential"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"company_number":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Company Number"},"companies_house_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Companies House Name"},"vat_number":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Vat Number"},"vat_reverse_charge":{"type":"boolean","title":"Vat Reverse Charge","default":false},"payment_terms_days":{"anyOf":[{"type":"integer","maximum":365.0,"minimum":0.0},{"type":"null"}],"title":"Payment Terms Days"},"credit_limit":{"anyOf":[{"type":"number","minimum":0.0},{"type":"null"}],"title":"Credit Limit"},"po_number_required":{"type":"boolean","title":"Po Number Required","default":false},"billing_address":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Billing Address"}},"type":"object","required":["name"],"title":"ClientCreateRequest"},"ClientInteractionCreate":{"properties":{"type":{"type":"string","enum":["call","email","meeting","note","site_visit"],"title":"Type"},"subject":{"anyOf":[{"type":"string","maxLength":500},{"type":"null"}],"title":"Subject"},"body":{"type":"string","minLength":1,"title":"Body"},"occurred_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Occurred At"}},"type":"object","required":["type","body"],"title":"ClientInteractionCreate"},"ClientInteractionResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"client_id":{"type":"string","format":"uuid","title":"Client Id"},"created_by_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Created By Id"},"type":{"type":"string","title":"Type"},"subject":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Subject"},"body":{"type":"string","title":"Body"},"occurred_at":{"type":"string","format":"date-time","title":"Occurred At"},"created_at":{"type":"string","format":"date-time","title":"Created At"}},"type":"object","required":["id","client_id","created_by_id","type","subject","body","occurred_at","created_at"],"title":"ClientInteractionResponse"},"ClientQuoteRequestIn":{"properties":{"client_name":{"type":"string","title":"Client Name"},"client_email":{"type":"string","format":"email","title":"Client Email"},"client_phone":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Client Phone"},"project_type":{"type":"string","title":"Project Type"},"description":{"type":"string","title":"Description"},"location":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Location"},"budget_range":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Budget Range"},"preferred_start":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Preferred Start"}},"type":"object","required":["client_name","client_email","project_type","description"],"title":"ClientQuoteRequestIn"},"ClientQuoteRequestPatch":{"properties":{"status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Status"},"quote_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Quote Id"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"}},"type":"object","title":"ClientQuoteRequestPatch"},"ClientResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"company_id":{"type":"string","format":"uuid","title":"Company Id"},"name":{"type":"string","title":"Name"},"email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Email"},"phone":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Phone"},"address":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Address"},"city":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"City"},"state":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"State"},"postcode":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Postcode"},"client_type":{"$ref":"#/components/schemas/ClientType"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"is_archived":{"type":"boolean","title":"Is Archived"},"company_number":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Company Number"},"companies_house_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Companies House Name"},"vat_number":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Vat Number"},"vat_reverse_charge":{"type":"boolean","title":"Vat Reverse Charge","default":false},"payment_terms_days":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Payment Terms Days"},"credit_limit":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Credit Limit"},"po_number_required":{"type":"boolean","title":"Po Number Required","default":false},"billing_address":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Billing Address"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"}},"type":"object","required":["id","company_id","name","email","phone","address","city","state","postcode","client_type","notes","is_archived","created_at","updated_at"],"title":"ClientResponse"},"ClientSignIn":{"properties":{"client_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Client Name"}},"type":"object","title":"ClientSignIn"},"ClientSiteCreate":{"properties":{"name":{"type":"string","maxLength":255,"minLength":1,"title":"Name"},"address_line1":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Address Line1"},"address_line2":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Address Line2"},"city":{"anyOf":[{"type":"string","maxLength":100},{"type":"null"}],"title":"City"},"county":{"anyOf":[{"type":"string","maxLength":100},{"type":"null"}],"title":"County"},"postcode":{"anyOf":[{"type":"string","maxLength":20},{"type":"null"}],"title":"Postcode"},"lat":{"anyOf":[{"type":"number","maximum":90.0,"minimum":-90.0},{"type":"null"}],"title":"Lat"},"lon":{"anyOf":[{"type":"number","maximum":180.0,"minimum":-180.0},{"type":"null"}],"title":"Lon"},"access_notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Notes"},"site_contact_name":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Site Contact Name"},"site_contact_phone":{"anyOf":[{"type":"string","maxLength":50},{"type":"null"}],"title":"Site Contact Phone"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"is_active":{"type":"boolean","title":"Is Active","default":true}},"type":"object","required":["name"],"title":"ClientSiteCreate"},"ClientSiteJobSummary":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"job_number":{"type":"string","title":"Job Number"},"title":{"type":"string","title":"Title"},"status":{"type":"string","title":"Status"},"contract_value":{"type":"number","title":"Contract Value"},"start_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Start Date"},"end_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"End Date"}},"type":"object","required":["id","job_number","title","status","contract_value","start_date","end_date"],"title":"ClientSiteJobSummary","description":"A job at this site — the \"all work at one address\" view."},"ClientSiteResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"company_id":{"type":"string","format":"uuid","title":"Company Id"},"client_id":{"type":"string","format":"uuid","title":"Client Id"},"name":{"type":"string","title":"Name"},"address_line1":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Address Line1"},"address_line2":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Address Line2"},"city":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"City"},"county":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"County"},"postcode":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Postcode"},"lat":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Lat"},"lon":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Lon"},"access_notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Notes"},"site_contact_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Site Contact Name"},"site_contact_phone":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Site Contact Phone"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"is_active":{"type":"boolean","title":"Is Active"},"full_address":{"type":"string","title":"Full Address"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"}},"type":"object","required":["id","company_id","client_id","name","address_line1","address_line2","city","county","postcode","lat","lon","access_notes","site_contact_name","site_contact_phone","notes","is_active","full_address","created_at","updated_at"],"title":"ClientSiteResponse"},"ClientSiteUpdate":{"properties":{"name":{"anyOf":[{"type":"string","maxLength":255,"minLength":1},{"type":"null"}],"title":"Name"},"address_line1":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Address Line1"},"address_line2":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Address Line2"},"city":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"City"},"county":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"County"},"postcode":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Postcode"},"lat":{"anyOf":[{"type":"number","maximum":90.0,"minimum":-90.0},{"type":"null"}],"title":"Lat"},"lon":{"anyOf":[{"type":"number","maximum":180.0,"minimum":-180.0},{"type":"null"}],"title":"Lon"},"access_notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Notes"},"site_contact_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Site Contact Name"},"site_contact_phone":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Site Contact Phone"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"is_active":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Active"}},"type":"object","title":"ClientSiteUpdate"},"ClientSorAgreementCreate":{"properties":{"client_id":{"type":"string","format":"uuid","title":"Client Id"},"schedule_id":{"type":"string","format":"uuid","title":"Schedule Id"},"uplift_percent":{"type":"number","title":"Uplift Percent","default":0.0},"contract_reference":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Contract Reference"},"is_default":{"type":"boolean","title":"Is Default","default":true}},"type":"object","required":["client_id","schedule_id"],"title":"ClientSorAgreementCreate"},"ClientSorAgreementResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"client_id":{"type":"string","format":"uuid","title":"Client Id"},"schedule_id":{"type":"string","format":"uuid","title":"Schedule Id"},"uplift_percent":{"type":"number","title":"Uplift Percent"},"contract_reference":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Contract Reference"},"is_default":{"type":"boolean","title":"Is Default"}},"type":"object","required":["id","client_id","schedule_id","uplift_percent","contract_reference","is_default"],"title":"ClientSorAgreementResponse"},"ClientType":{"type":"string","enum":["residential","commercial"],"title":"ClientType"},"ClientUpdateRequest":{"properties":{"name":{"anyOf":[{"type":"string","maxLength":255,"minLength":1},{"type":"null"}],"title":"Name"},"email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Email"},"phone":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Phone"},"address":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Address"},"city":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"City"},"state":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"State"},"postcode":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Postcode"},"client_type":{"anyOf":[{"$ref":"#/components/schemas/ClientType"},{"type":"null"}]},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"company_number":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Company Number"},"companies_house_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Companies House Name"},"vat_number":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Vat Number"},"vat_reverse_charge":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Vat Reverse Charge"},"payment_terms_days":{"anyOf":[{"type":"integer","maximum":365.0,"minimum":0.0},{"type":"null"}],"title":"Payment Terms Days"},"credit_limit":{"anyOf":[{"type":"number","minimum":0.0},{"type":"null"}],"title":"Credit Limit"},"po_number_required":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Po Number Required"},"billing_address":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Billing Address"}},"type":"object","title":"ClientUpdateRequest"},"CollectRequest":{"properties":{"invoice_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Invoice Id"},"amount_pence":{"anyOf":[{"type":"integer","exclusiveMinimum":0.0},{"type":"null"}],"title":"Amount Pence"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"}},"type":"object","title":"CollectRequest"},"CommentCreate":{"properties":{"entity_type":{"type":"string","enum":["job","quote","tender"],"title":"Entity Type"},"entity_id":{"type":"string","format":"uuid","title":"Entity Id"},"body":{"type":"string","maxLength":5000,"minLength":1,"title":"Body"}},"type":"object","required":["entity_type","entity_id","body"],"title":"CommentCreate"},"CommentResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"entity_type":{"type":"string","title":"Entity Type"},"entity_id":{"type":"string","format":"uuid","title":"Entity Id"},"author_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Author Id"},"author_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Author Name"},"body":{"type":"string","title":"Body"},"is_deleted":{"type":"boolean","title":"Is Deleted"},"edited_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Edited At"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"}},"type":"object","required":["id","entity_type","entity_id","author_id","author_name","body","is_deleted","edited_at","created_at","updated_at"],"title":"CommentResponse"},"CommentUpdate":{"properties":{"body":{"type":"string","maxLength":5000,"minLength":1,"title":"Body"}},"type":"object","required":["body"],"title":"CommentUpdate"},"CommissionTierUpdate":{"properties":{"min_clients":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Min Clients"},"max_clients":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Max Clients"},"rate_percentage":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Rate Percentage"}},"type":"object","title":"CommissionTierUpdate"},"CompanyCreateRequest":{"properties":{"name":{"type":"string","maxLength":255,"minLength":1,"title":"Name"},"company_number":{"anyOf":[{"type":"string","maxLength":20},{"type":"null"}],"title":"Company Number"},"address":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Address"},"city":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"City"},"state":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"State"},"postcode":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Postcode"},"country":{"type":"string","title":"Country","default":"United Kingdom"},"phone":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Phone"},"website":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Website"},"tax_rate":{"type":"number","maximum":100.0,"minimum":0.0,"title":"Tax Rate","default":20.0},"currency":{"type":"string","title":"Currency","default":"GBP"},"referral_code":{"anyOf":[{"type":"string","maxLength":20},{"type":"null"}],"title":"Referral Code"},"tracking_token":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Tracking Token"}},"type":"object","required":["name"],"title":"CompanyCreateRequest"},"CompanyDetails":{"properties":{"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name"},"type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Type"},"ch_number":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Ch Number"},"vat_number":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Vat Number"},"address":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Address"},"phone":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Phone"},"email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Email"},"website":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Website"}},"type":"object","title":"CompanyDetails"},"CompanyEnvironmentalSummary":{"properties":{"total_waste_generated_kg":{"type":"number","title":"Total Waste Generated Kg"},"total_waste_recycled_kg":{"type":"number","title":"Total Waste Recycled Kg"},"overall_recycling_rate":{"type":"number","title":"Overall Recycling Rate"},"total_carbon_kg_co2e":{"type":"number","title":"Total Carbon Kg Co2E"},"active_job_count":{"type":"integer","title":"Active Job Count"}},"type":"object","required":["total_waste_generated_kg","total_waste_recycled_kg","overall_recycling_rate","total_carbon_kg_co2e","active_job_count"],"title":"CompanyEnvironmentalSummary"},"CompanyResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"name":{"type":"string","title":"Name"},"company_number":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Company Number"},"address":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Address"},"city":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"City"},"state":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"State"},"postcode":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Postcode"},"country":{"type":"string","title":"Country"},"phone":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Phone"},"email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Email"},"website":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Website"},"logo_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Logo Url"},"tax_rate":{"type":"number","title":"Tax Rate"},"currency":{"type":"string","title":"Currency"},"onboarding_completed":{"type":"boolean","title":"Onboarding Completed"},"onboarding_step":{"type":"integer","title":"Onboarding Step"},"late_payment_interest_rate":{"type":"number","title":"Late Payment Interest Rate"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"default_quote_terms":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Default Quote Terms"},"default_invoice_terms":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Default Invoice Terms"},"quote_prefix":{"type":"string","title":"Quote Prefix","default":"QTE-"},"quote_next_number":{"type":"string","title":"Quote Next Number","default":"001"},"invoice_prefix":{"type":"string","title":"Invoice Prefix","default":"INV-"},"invoice_next_number":{"type":"string","title":"Invoice Next Number","default":"001"},"pdf_logo_position":{"type":"string","title":"Pdf Logo Position","default":"left"},"pdf_accent_colour":{"type":"string","title":"Pdf Accent Colour","default":"#0A0F1A"},"company_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Company Type"},"companies_house_number":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Companies House Number"},"vat_number":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Vat Number"},"trading_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Trading Name"},"founded_year":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Founded Year"},"employee_count":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Employee Count"},"trade_categories":{"items":{"type":"string"},"type":"array","title":"Trade Categories","default":[]},"primary_trade":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Primary Trade"},"project_types":{"items":{"type":"string"},"type":"array","title":"Project Types","default":[]},"typical_project_value":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Typical Project Value"},"typical_project_duration":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Typical Project Duration"},"max_project_value":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Max Project Value"},"operating_regions":{"items":{"type":"string"},"type":"array","title":"Operating Regions","default":[]},"base_postcode":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Base Postcode"},"travel_radius":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Travel Radius"},"has_public_liability":{"type":"boolean","title":"Has Public Liability","default":false},"public_liability_value":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Public Liability Value"},"has_employers_liability":{"type":"boolean","title":"Has Employers Liability","default":false},"cis":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cis"},"cis_number":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cis Number"},"accreditations":{"items":{"type":"string"},"type":"array","title":"Accreditations","default":[]},"tender_alerts_enabled":{"type":"boolean","title":"Tender Alerts Enabled","default":false},"tender_min_value":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Tender Min Value"},"tender_max_value":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Tender Max Value"},"tender_alert_frequency":{"type":"string","title":"Tender Alert Frequency","default":"daily"},"profile_score":{"type":"integer","title":"Profile Score","default":0},"onboarding_completed_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Onboarding Completed At"},"referral_source":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Referral Source"}},"type":"object","required":["id","name","company_number","address","city","state","postcode","country","phone","website","logo_url","tax_rate","currency","onboarding_completed","onboarding_step","late_payment_interest_rate","created_at"],"title":"CompanyResponse"},"CompanyUpdateRequest":{"properties":{"name":{"anyOf":[{"type":"string","maxLength":255,"minLength":1},{"type":"null"}],"title":"Name"},"company_number":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Company Number"},"address":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Address"},"city":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"City"},"state":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"State"},"postcode":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Postcode"},"country":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Country"},"phone":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Phone"},"email":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Email"},"website":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Website"},"tax_rate":{"anyOf":[{"type":"number","maximum":100.0,"minimum":0.0},{"type":"null"}],"title":"Tax Rate"},"currency":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Currency"},"late_payment_interest_rate":{"anyOf":[{"type":"number","maximum":100.0,"minimum":0.0},{"type":"null"}],"title":"Late Payment Interest Rate"},"default_quote_terms":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Default Quote Terms"},"default_invoice_terms":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Default Invoice Terms"},"quote_prefix":{"anyOf":[{"type":"string","maxLength":10},{"type":"null"}],"title":"Quote Prefix"},"quote_next_number":{"anyOf":[{"type":"string","maxLength":10},{"type":"null"}],"title":"Quote Next Number"},"invoice_prefix":{"anyOf":[{"type":"string","maxLength":10},{"type":"null"}],"title":"Invoice Prefix"},"invoice_next_number":{"anyOf":[{"type":"string","maxLength":10},{"type":"null"}],"title":"Invoice Next Number"},"pdf_logo_position":{"anyOf":[{"type":"string","pattern":"^(left|centre)$"},{"type":"null"}],"title":"Pdf Logo Position"},"pdf_accent_colour":{"anyOf":[{"type":"string","maxLength":9},{"type":"null"}],"title":"Pdf Accent Colour"},"company_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Company Type"},"companies_house_number":{"anyOf":[{"type":"string","maxLength":20},{"type":"null"}],"title":"Companies House Number"},"vat_number":{"anyOf":[{"type":"string","maxLength":20},{"type":"null"}],"title":"Vat Number"},"trading_name":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Trading Name"},"founded_year":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Founded Year"},"employee_count":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Employee Count"},"trade_categories":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Trade Categories"},"primary_trade":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Primary Trade"},"project_types":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Project Types"},"typical_project_value":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Typical Project Value"},"typical_project_duration":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Typical Project Duration"},"max_project_value":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Max Project Value"},"operating_regions":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Operating Regions"},"base_postcode":{"anyOf":[{"type":"string","maxLength":10},{"type":"null"}],"title":"Base Postcode"},"travel_radius":{"anyOf":[{"type":"integer","maximum":200.0,"minimum":10.0},{"type":"null"}],"title":"Travel Radius"},"has_public_liability":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Has Public Liability"},"public_liability_value":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Public Liability Value"},"has_employers_liability":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Has Employers Liability"},"cis":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cis"},"cis_number":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cis Number"},"accreditations":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Accreditations"},"tender_alerts_enabled":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Tender Alerts Enabled"},"tender_min_value":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Tender Min Value"},"tender_max_value":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Tender Max Value"},"tender_regions":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Tender Regions"},"tender_categories":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Tender Categories"},"tender_alert_frequency":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Tender Alert Frequency"},"referral_source":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Referral Source"},"referral_detail":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Referral Detail"}},"type":"object","title":"CompanyUpdateRequest"},"CompanyUserRole":{"type":"string","enum":["OWNER","ADMIN","MANAGER","MEMBER","FIELD_WORKER","VIEWER"],"title":"CompanyUserRole"},"CompleteOnboardingRequest":{"properties":{"company":{"anyOf":[{"$ref":"#/components/schemas/CompanyDetails"},{"type":"null"}]},"work":{"anyOf":[{"$ref":"#/components/schemas/WorkDetails"},{"type":"null"}]},"compliance":{"anyOf":[{"$ref":"#/components/schemas/ComplianceDetails"},{"type":"null"}]},"accreditations":{"anyOf":[{"$ref":"#/components/schemas/AccreditationDetails"},{"type":"null"}]},"tender_preferences":{"anyOf":[{"$ref":"#/components/schemas/TenderPreferences"},{"type":"null"}]},"current_tools":{"anyOf":[{"$ref":"#/components/schemas/CurrentTools"},{"type":"null"}]},"selected_plan":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Selected Plan"},"billing_period":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Billing Period"},"payment_method":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Payment Method"}},"type":"object","title":"CompleteOnboardingRequest"},"ComplianceCreate":{"properties":{"property_id":{"type":"string","format":"uuid","title":"Property Id"},"compliance_type":{"$ref":"#/components/schemas/ComplianceType"},"interval_months":{"anyOf":[{"type":"integer","maximum":240.0,"minimum":1.0},{"type":"null"}],"title":"Interval Months"},"last_inspection_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Last Inspection Date"},"next_due_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Next Due Date"},"certificate_reference":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Certificate Reference"},"inspector_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Inspector Name"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"}},"type":"object","required":["property_id","compliance_type"],"title":"ComplianceCreate"},"ComplianceDetails":{"properties":{"cis_registered":{"type":"boolean","title":"Cis Registered","default":false},"cis_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cis Type"},"utr_number":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Utr Number"},"public_liability":{"type":"boolean","title":"Public Liability","default":false},"pl_coverage":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Pl Coverage"},"pl_expiry":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Pl Expiry"},"employers_liability":{"type":"boolean","title":"Employers Liability","default":false},"el_coverage":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"El Coverage"},"el_expiry":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"El Expiry"},"professional_indemnity":{"type":"boolean","title":"Professional Indemnity","default":false},"pi_coverage":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Pi Coverage"},"pi_expiry":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Pi Expiry"},"car_insurance":{"type":"boolean","title":"Car Insurance","default":false}},"type":"object","title":"ComplianceDetails"},"ComplianceRecordResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"property_id":{"type":"string","format":"uuid","title":"Property Id"},"compliance_type":{"$ref":"#/components/schemas/ComplianceType"},"status":{"$ref":"#/components/schemas/ComplianceStatus"},"interval_months":{"type":"integer","title":"Interval Months"},"last_inspection_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Last Inspection Date"},"next_due_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Next Due Date"},"certificate_reference":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Certificate Reference"},"certificate_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Certificate Url"},"inspector_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Inspector Name"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"is_active":{"type":"boolean","title":"Is Active"},"property_reference":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Property Reference"},"property_address":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Property Address"}},"type":"object","required":["id","property_id","compliance_type","status","interval_months","last_inspection_date","next_due_date","certificate_reference","certificate_url","inspector_name","notes","is_active"],"title":"ComplianceRecordResponse"},"ComplianceRegister":{"properties":{"total_records":{"type":"integer","title":"Total Records"},"compliant":{"type":"integer","title":"Compliant"},"overdue":{"type":"integer","title":"Overdue"},"due_soon":{"type":"integer","title":"Due Soon"},"no_access":{"type":"integer","title":"No Access"},"compliance_rate":{"type":"number","title":"Compliance Rate"},"by_type":{"additionalProperties":{"type":"object"},"type":"object","title":"By Type"},"worst_overdue_days":{"type":"integer","title":"Worst Overdue Days"}},"type":"object","required":["total_records","compliant","overdue","due_soon","no_access","compliance_rate","by_type","worst_overdue_days"],"title":"ComplianceRegister","description":"Board-level compliance summary."},"ComplianceStatus":{"type":"string","enum":["compliant","due_soon","overdue","no_access","not_applicable"],"title":"ComplianceStatus"},"ComplianceType":{"type":"string","enum":["gas_lgsr","electrical_eicr","fire_risk","legionella","asbestos","lift","smoke_co_alarm","epc"],"title":"ComplianceType"},"ComplianceUpdate":{"properties":{"interval_months":{"anyOf":[{"type":"integer","maximum":240.0,"minimum":1.0},{"type":"null"}],"title":"Interval Months"},"next_due_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Next Due Date"},"status":{"anyOf":[{"$ref":"#/components/schemas/ComplianceStatus"},{"type":"null"}]},"certificate_reference":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Certificate Reference"},"certificate_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Certificate Url"},"inspector_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Inspector Name"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"is_active":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Active"}},"type":"object","title":"ComplianceUpdate"},"ComponentState":{"type":"string","enum":["operational","degraded","down"],"title":"ComponentState"},"ComponentStatus":{"properties":{"name":{"type":"string","title":"Name"},"description":{"type":"string","title":"Description"},"state":{"$ref":"#/components/schemas/ComponentState"},"latency_ms":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Latency Ms"}},"type":"object","required":["name","description","state"],"title":"ComponentStatus"},"ConditionIn":{"properties":{"condition_number":{"type":"integer","minimum":1.0,"title":"Condition Number","default":1},"text":{"type":"string","minLength":1,"title":"Text"},"condition_type":{"type":"string","title":"Condition Type","default":"compliance"},"due_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Due Date"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"}},"type":"object","required":["text"],"title":"ConditionIn"},"ConditionOut":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"condition_number":{"type":"integer","title":"Condition Number"},"text":{"type":"string","title":"Text"},"condition_type":{"type":"string","title":"Condition Type"},"status":{"type":"string","title":"Status"},"due_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Due Date"},"submitted_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Submitted Date"},"discharged_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Discharged Date"},"discharge_reference":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Discharge Reference"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"blocks_start_on_site":{"type":"boolean","title":"Blocks Start On Site","default":false}},"type":"object","required":["id","condition_number","text","condition_type","status"],"title":"ConditionOut"},"ConfidenceLevel":{"type":"string","enum":["high","medium","low"],"title":"ConfidenceLevel"},"ConsentRequest":{"properties":{"session_id":{"type":"string","title":"Session Id"},"analytics":{"type":"boolean","title":"Analytics","default":false},"advertising":{"type":"boolean","title":"Advertising","default":false},"functional":{"type":"boolean","title":"Functional","default":false},"version":{"type":"string","title":"Version","default":"1.0"},"product":{"type":"string","title":"Product","default":"estimark"}},"type":"object","required":["session_id"],"title":"ConsentRequest"},"ConstraintCheckRequest":{"properties":{"lat":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Lat"},"lng":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Lng"},"postcode":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Postcode"}},"type":"object","title":"ConstraintCheckRequest"},"ConstraintCheckResponse":{"properties":{"conservation_area":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Conservation Area","default":false},"conservation_area_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Conservation Area Name"},"flood_zone":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Flood Zone"},"green_belt":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Green Belt","default":false},"sssi":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Sssi","default":false},"listed_buildings":{"anyOf":[{"items":{"type":"object"},"type":"array"},{"type":"null"}],"title":"Listed Buildings"},"tpo_trees":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Tpo Trees","default":false},"article4":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Article4","default":false},"constraints":{"items":{"type":"object"},"type":"array","title":"Constraints","default":[]}},"type":"object","title":"ConstraintCheckResponse"},"ContractCreate":{"properties":{"template_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Template Id"},"contract_html":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Contract Html"}},"type":"object","title":"ContractCreate"},"ContractDueItem":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"title":{"type":"string","title":"Title"},"service_type":{"type":"string","title":"Service Type"},"client_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Client Name"},"next_visit_date":{"type":"string","format":"date","title":"Next Visit Date"},"days_until":{"type":"integer","title":"Days Until"},"auto_invoice":{"type":"boolean","title":"Auto Invoice"},"price_pence":{"type":"integer","title":"Price Pence"}},"type":"object","required":["id","title","service_type","client_name","next_visit_date","days_until","auto_invoice","price_pence"],"title":"ContractDueItem","description":"A contract with a visit falling due — the \"what's coming\" list."},"ContractPublicResponse":{"properties":{"contract_html":{"type":"string","title":"Contract Html"},"signer_name_hint":{"type":"string","title":"Signer Name Hint"},"employee_id":{"type":"string","format":"uuid","title":"Employee Id"}},"type":"object","required":["contract_html","signer_name_hint","employee_id"],"title":"ContractPublicResponse","description":"Returned by the public GET /hr/sign/{token} endpoint."},"ContractResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"employee_id":{"type":"string","format":"uuid","title":"Employee Id"},"company_id":{"type":"string","format":"uuid","title":"Company Id"},"template_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Template Id"},"version":{"type":"integer","title":"Version"},"status":{"type":"string","title":"Status"},"sent_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Sent At"},"signed_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Signed At"},"expires_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Expires At"},"sign_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Sign Url"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"}},"type":"object","required":["id","employee_id","company_id","template_id","version","status","sent_at","signed_at","expires_at","created_at","updated_at"],"title":"ContractResponse"},"ContractSignRequest":{"properties":{"signer_name":{"type":"string","title":"Signer Name"},"signature_data":{"type":"string","title":"Signature Data"}},"type":"object","required":["signer_name","signature_data"],"title":"ContractSignRequest"},"ConversationMessage":{"properties":{"role":{"type":"string","pattern":"^(user|assistant)$","title":"Role"},"content":{"type":"string","title":"Content"}},"type":"object","required":["role","content"],"title":"ConversationMessage"},"CorrespondenceCreate":{"properties":{"correspondence_type":{"type":"string","title":"Correspondence Type"},"correspondence_date":{"type":"string","format":"date","title":"Correspondence Date"},"sender":{"type":"string","maxLength":255,"minLength":1,"title":"Sender"},"recipient":{"type":"string","maxLength":255,"minLength":1,"title":"Recipient"},"subject":{"type":"string","maxLength":500,"minLength":1,"title":"Subject"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"is_inbound":{"type":"boolean","title":"Is Inbound","default":false},"job_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Job Id"},"tender_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Tender Id"},"tags":{"items":{"type":"string"},"type":"array","title":"Tags","default":[]}},"type":"object","required":["correspondence_type","correspondence_date","sender","recipient","subject"],"title":"CorrespondenceCreate"},"CorrespondenceDetail":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"company_id":{"type":"string","format":"uuid","title":"Company Id"},"job_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Job Id"},"tender_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Tender Id"},"correspondence_type":{"type":"string","title":"Correspondence Type"},"correspondence_date":{"type":"string","format":"date","title":"Correspondence Date"},"sender":{"type":"string","title":"Sender"},"recipient":{"type":"string","title":"Recipient"},"subject":{"type":"string","title":"Subject"},"is_inbound":{"type":"boolean","title":"Is Inbound"},"tags":{"items":{"type":"string"},"type":"array","title":"Tags","default":[]},"attachment_count":{"type":"integer","title":"Attachment Count","default":0},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"attachments":{"items":{"type":"object"},"type":"array","title":"Attachments","default":[]},"job_number":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Job Number"},"job_title":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Job Title"},"tender_reference":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Tender Reference"}},"type":"object","required":["id","company_id","job_id","tender_id","correspondence_type","correspondence_date","sender","recipient","subject","is_inbound","created_at","updated_at","description"],"title":"CorrespondenceDetail"},"CorrespondenceSummary":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"company_id":{"type":"string","format":"uuid","title":"Company Id"},"job_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Job Id"},"tender_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Tender Id"},"correspondence_type":{"type":"string","title":"Correspondence Type"},"correspondence_date":{"type":"string","format":"date","title":"Correspondence Date"},"sender":{"type":"string","title":"Sender"},"recipient":{"type":"string","title":"Recipient"},"subject":{"type":"string","title":"Subject"},"is_inbound":{"type":"boolean","title":"Is Inbound"},"tags":{"items":{"type":"string"},"type":"array","title":"Tags","default":[]},"attachment_count":{"type":"integer","title":"Attachment Count","default":0},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"}},"type":"object","required":["id","company_id","job_id","tender_id","correspondence_type","correspondence_date","sender","recipient","subject","is_inbound","created_at","updated_at"],"title":"CorrespondenceSummary"},"CorrespondenceUpdate":{"properties":{"correspondence_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Correspondence Type"},"correspondence_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Correspondence Date"},"sender":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Sender"},"recipient":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Recipient"},"subject":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Subject"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"is_inbound":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Inbound"},"job_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Job Id"},"tender_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Tender Id"},"tags":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Tags"}},"type":"object","title":"CorrespondenceUpdate"},"CostBreakdown":{"properties":{"labour":{"type":"number","title":"Labour","default":0.0},"material":{"type":"number","title":"Material","default":0.0},"plant":{"type":"number","title":"Plant","default":0.0},"subcontractor":{"type":"number","title":"Subcontractor","default":0.0},"other":{"type":"number","title":"Other","default":0.0},"total":{"type":"number","title":"Total","default":0.0}},"type":"object","title":"CostBreakdown"},"CostCategory":{"type":"string","enum":["labour","material","plant","subcontractor","preliminaries","other"],"title":"CostCategory"},"CostCodeCreate":{"properties":{"code":{"type":"string","maxLength":30,"minLength":1,"title":"Code"},"name":{"type":"string","maxLength":200,"minLength":1,"title":"Name"},"category":{"$ref":"#/components/schemas/CostCategory","default":"other"},"parent_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Parent Id"},"sort_order":{"type":"integer","title":"Sort Order","default":0}},"type":"object","required":["code","name"],"title":"CostCodeCreate"},"CostCodeResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"code":{"type":"string","title":"Code"},"name":{"type":"string","title":"Name"},"category":{"$ref":"#/components/schemas/CostCategory"},"parent_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Parent Id"},"is_active":{"type":"boolean","title":"Is Active"},"sort_order":{"type":"integer","title":"Sort Order"}},"type":"object","required":["id","code","name","category","parent_id","is_active","sort_order"],"title":"CostCodeResponse"},"CostCodeUpdate":{"properties":{"code":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Code"},"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name"},"category":{"anyOf":[{"$ref":"#/components/schemas/CostCategory"},{"type":"null"}]},"parent_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Parent Id"},"is_active":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Active"},"sort_order":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Sort Order"}},"type":"object","title":"CostCodeUpdate"},"CreatePaymentPlanRequest":{"properties":{"installments":{"items":{"$ref":"#/components/schemas/InstallmentInput"},"type":"array","minItems":2,"title":"Installments"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"}},"type":"object","required":["installments"],"title":"CreatePaymentPlanRequest"},"CreateTicketBody":{"properties":{"subject":{"type":"string","title":"Subject"},"body":{"type":"string","title":"Body"},"priority":{"type":"string","title":"Priority","default":"medium"}},"type":"object","required":["subject","body"],"title":"CreateTicketBody"},"CreditEntryType":{"type":"string","enum":["issued","consumed","expired","revoked"],"title":"CreditEntryType"},"CreditNoteCreate":{"properties":{"amount_net":{"type":"number","exclusiveMinimum":0.0,"title":"Amount Net"},"tax_rate":{"type":"number","maximum":100.0,"minimum":0.0,"title":"Tax Rate","default":20.0},"reason":{"$ref":"#/components/schemas/CreditNoteReason","default":"error"},"reason_detail":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Reason Detail"},"issue_now":{"type":"boolean","title":"Issue Now","default":true}},"type":"object","required":["amount_net"],"title":"CreditNoteCreate"},"CreditNoteReason":{"type":"string","enum":["error","goodwill","work_not_done","duplicate","overpayment","other"],"title":"CreditNoteReason"},"CreditNoteResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"invoice_id":{"type":"string","format":"uuid","title":"Invoice Id"},"credit_note_number":{"type":"string","title":"Credit Note Number"},"amount_net":{"type":"number","title":"Amount Net"},"tax_rate":{"type":"number","title":"Tax Rate"},"amount_tax":{"type":"number","title":"Amount Tax"},"amount_total":{"type":"number","title":"Amount Total"},"reason":{"$ref":"#/components/schemas/CreditNoteReason"},"reason_detail":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Reason Detail"},"status":{"$ref":"#/components/schemas/CreditNoteStatus"},"issue_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Issue Date"},"refunded_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Refunded At"},"refund_reference":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Refund Reference"},"created_at":{"type":"string","format":"date-time","title":"Created At"}},"type":"object","required":["id","invoice_id","credit_note_number","amount_net","tax_rate","amount_tax","amount_total","reason","reason_detail","status","issue_date","refunded_at","refund_reference","created_at"],"title":"CreditNoteResponse"},"CreditNoteStatus":{"type":"string","enum":["draft","issued","applied","refunded","void"],"title":"CreditNoteStatus"},"CreditReason":{"type":"string","enum":["goodwill","service_issue","outage","billing_error","negotiated","referral","other"],"title":"CreditReason"},"CurrentTools":{"properties":{"estimating_tool":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Estimating Tool"},"job_management_tool":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Job Management Tool"},"invoicing_tool":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Invoicing Tool"},"hs_tool":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Hs Tool"},"wants_data_import":{"type":"boolean","title":"Wants Data Import","default":false}},"type":"object","title":"CurrentTools"},"CustomFieldDefinitionCreateRequest":{"properties":{"entity_type":{"$ref":"#/components/schemas/EntityType"},"name":{"type":"string","title":"Name"},"field_type":{"$ref":"#/components/schemas/FieldType"},"options":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Options"},"sort_order":{"type":"integer","title":"Sort Order","default":0}},"type":"object","required":["entity_type","name","field_type"],"title":"CustomFieldDefinitionCreateRequest"},"CustomFieldDefinitionResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"company_id":{"type":"string","format":"uuid","title":"Company Id"},"entity_type":{"$ref":"#/components/schemas/EntityType"},"name":{"type":"string","title":"Name"},"field_type":{"$ref":"#/components/schemas/FieldType"},"options":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Options"},"sort_order":{"type":"integer","title":"Sort Order"}},"type":"object","required":["id","company_id","entity_type","name","field_type","sort_order"],"title":"CustomFieldDefinitionResponse"},"CustomFieldDefinitionUpdateRequest":{"properties":{"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name"},"options":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Options"},"sort_order":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Sort Order"}},"type":"object","title":"CustomFieldDefinitionUpdateRequest"},"CustomReportCreate":{"properties":{"name":{"type":"string","title":"Name"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"entity_type":{"type":"string","title":"Entity Type"},"columns":{"items":{"type":"string"},"type":"array","title":"Columns","default":[]},"filters":{"items":{"type":"object"},"type":"array","title":"Filters","default":[]},"sort_by":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Sort By"},"sort_dir":{"type":"string","title":"Sort Dir","default":"asc"},"chart_type":{"type":"string","title":"Chart Type","default":"table"},"is_shared":{"type":"boolean","title":"Is Shared","default":false}},"type":"object","required":["name","entity_type"],"title":"CustomReportCreate"},"CustomReportResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"company_id":{"type":"string","format":"uuid","title":"Company Id"},"name":{"type":"string","title":"Name"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"entity_type":{"type":"string","title":"Entity Type"},"columns":{"items":{"type":"string"},"type":"array","title":"Columns"},"filters":{"items":{"type":"object"},"type":"array","title":"Filters"},"sort_by":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Sort By"},"sort_dir":{"type":"string","title":"Sort Dir"},"chart_type":{"type":"string","title":"Chart Type"},"is_shared":{"type":"boolean","title":"Is Shared"},"created_by":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Created By"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"}},"type":"object","required":["id","company_id","name","description","entity_type","columns","filters","sort_by","sort_dir","chart_type","is_shared","created_by","created_at","updated_at"],"title":"CustomReportResponse"},"CustomReportUpdate":{"properties":{"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"columns":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Columns"},"filters":{"anyOf":[{"items":{"type":"object"},"type":"array"},{"type":"null"}],"title":"Filters"},"sort_by":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Sort By"},"sort_dir":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Sort Dir"},"chart_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Chart Type"},"is_shared":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Shared"}},"type":"object","title":"CustomReportUpdate"},"CustomerMessageResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"appointment_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Appointment Id"},"channel":{"$ref":"#/components/schemas/MessageChannel"},"kind":{"$ref":"#/components/schemas/MessageKind"},"recipient":{"type":"string","title":"Recipient"},"body":{"type":"string","title":"Body"},"sent_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Sent At"},"delivered":{"type":"boolean","title":"Delivered"},"error":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error"},"created_at":{"type":"string","format":"date-time","title":"Created At"}},"type":"object","required":["id","appointment_id","channel","kind","recipient","body","sent_at","delivered","error","created_at"],"title":"CustomerMessageResponse"},"CustomerSignature":{"properties":{"customer_name":{"type":"string","maxLength":255,"minLength":1,"title":"Customer Name"},"signature_data_url":{"type":"string","minLength":1,"title":"Signature Data Url"}},"type":"object","required":["customer_name","signature_data_url"],"title":"CustomerSignature","description":"The recipient's acknowledgement, captured on the engineer's device."},"DailyCheckCreate":{"properties":{"check_date":{"type":"string","format":"date","title":"Check Date"},"driver_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Driver Name"},"oil_ok":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Oil Ok"},"water_ok":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Water Ok"},"tyres_ok":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Tyres Ok"},"lights_ok":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Lights Ok"},"brakes_ok":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Brakes Ok"},"overall_pass":{"type":"boolean","title":"Overall Pass","default":true},"defects_noted":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Defects Noted"}},"type":"object","required":["check_date"],"title":"DailyCheckCreate"},"DailyCheckResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"vehicle_id":{"type":"string","format":"uuid","title":"Vehicle Id"},"check_date":{"type":"string","format":"date","title":"Check Date"},"driver_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Driver Name"},"oil_ok":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Oil Ok"},"water_ok":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Water Ok"},"tyres_ok":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Tyres Ok"},"lights_ok":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Lights Ok"},"brakes_ok":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Brakes Ok"},"overall_pass":{"type":"boolean","title":"Overall Pass"},"defects_noted":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Defects Noted"},"created_at":{"type":"string","format":"date-time","title":"Created At"}},"type":"object","required":["id","vehicle_id","check_date","driver_name","oil_ok","water_ok","tyres_ok","lights_ok","brakes_ok","overall_pass","defects_noted","created_at"],"title":"DailyCheckResponse"},"DashboardData":{"properties":{"monthly_revenue":{"items":{"$ref":"#/components/schemas/MonthlyRevenue"},"type":"array","title":"Monthly Revenue"},"quote_pipeline":{"items":{"$ref":"#/components/schemas/PipelineItem"},"type":"array","title":"Quote Pipeline"},"job_summary":{"items":{"$ref":"#/components/schemas/PipelineItem"},"type":"array","title":"Job Summary"},"kpis":{"$ref":"#/components/schemas/KPIs"}},"type":"object","required":["monthly_revenue","quote_pipeline","job_summary","kpis"],"title":"DashboardData"},"DayworkSheetIn":{"properties":{"job_id":{"type":"string","format":"uuid","title":"Job Id"},"sheet_date":{"type":"string","title":"Sheet Date"},"reference":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Reference"},"description":{"type":"string","title":"Description"},"location":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Location"},"weather":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Weather"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"labour_entries":{"items":{"$ref":"#/components/schemas/LabourEntryIn"},"type":"array","title":"Labour Entries","default":[]},"material_entries":{"items":{"$ref":"#/components/schemas/MaterialEntryIn"},"type":"array","title":"Material Entries","default":[]},"plant_entries":{"items":{"$ref":"#/components/schemas/PlantEntryIn"},"type":"array","title":"Plant Entries","default":[]}},"type":"object","required":["job_id","sheet_date","description"],"title":"DayworkSheetIn"},"DayworkSheetPatch":{"properties":{"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"location":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Location"},"weather":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Weather"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"labour_entries":{"anyOf":[{"items":{"$ref":"#/components/schemas/LabourEntryIn"},"type":"array"},{"type":"null"}],"title":"Labour Entries"},"material_entries":{"anyOf":[{"items":{"$ref":"#/components/schemas/MaterialEntryIn"},"type":"array"},{"type":"null"}],"title":"Material Entries"},"plant_entries":{"anyOf":[{"items":{"$ref":"#/components/schemas/PlantEntryIn"},"type":"array"},{"type":"null"}],"title":"Plant Entries"}},"type":"object","title":"DayworkSheetPatch"},"DecisionRequest":{"properties":{"decision":{"type":"string","title":"Decision","description":"granted | refused | withdrawn | split_decision"},"decision_date":{"type":"string","format":"date","title":"Decision Date"}},"type":"object","required":["decision","decision_date"],"title":"DecisionRequest"},"DefectCreate":{"properties":{"job_id":{"type":"string","format":"uuid","title":"Job Id"},"title":{"type":"string","maxLength":500,"minLength":1,"title":"Title"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"location":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Location"},"trade":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Trade"},"assigned_to_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Assigned To Id"},"assigned_to":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Assigned To"},"priority":{"$ref":"#/components/schemas/DefectPriority","default":"medium"},"raised_date":{"type":"string","format":"date","title":"Raised Date"},"due_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Due Date"},"photo_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Photo Url"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"punch_list_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Punch List Id"},"room_label":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Room Label"},"floor_level":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Floor Level"}},"type":"object","required":["job_id","title","raised_date"],"title":"DefectCreate"},"DefectPriority":{"type":"string","enum":["low","medium","high"],"title":"DefectPriority"},"DefectResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"job_id":{"type":"string","format":"uuid","title":"Job Id"},"job_title":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Job Title"},"job_number":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Job Number"},"defect_number":{"type":"string","title":"Defect Number"},"title":{"type":"string","title":"Title"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"location":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Location"},"trade":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Trade"},"assigned_to_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Assigned To Id"},"assigned_to":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Assigned To"},"status":{"$ref":"#/components/schemas/DefectStatus"},"priority":{"$ref":"#/components/schemas/DefectPriority"},"raised_date":{"type":"string","format":"date","title":"Raised Date"},"due_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Due Date"},"rectified_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Rectified Date"},"signed_off_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Signed Off Date"},"signed_off_by":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Signed Off By"},"photo_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Photo Url"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"punch_list_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Punch List Id"},"room_label":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Room Label"},"floor_level":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Floor Level"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"}},"type":"object","required":["id","job_id","defect_number","title","description","location","trade","assigned_to","status","priority","raised_date","due_date","rectified_date","signed_off_date","signed_off_by","photo_url","notes","created_at","updated_at"],"title":"DefectResponse"},"DefectSignOff":{"properties":{"signed_off_by":{"type":"string","minLength":1,"title":"Signed Off By"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"}},"type":"object","required":["signed_off_by"],"title":"DefectSignOff"},"DefectStatus":{"type":"string","enum":["open","in_progress","rectified","signed_off"],"title":"DefectStatus"},"DefectSummary":{"properties":{"job_id":{"type":"string","format":"uuid","title":"Job Id"},"total":{"type":"integer","title":"Total"},"open":{"type":"integer","title":"Open"},"in_progress":{"type":"integer","title":"In Progress"},"rectified":{"type":"integer","title":"Rectified"},"signed_off":{"type":"integer","title":"Signed Off"}},"type":"object","required":["job_id","total","open","in_progress","rectified","signed_off"],"title":"DefectSummary"},"DefectUpdate":{"properties":{"title":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Title"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"location":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Location"},"trade":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Trade"},"assigned_to_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Assigned To Id"},"assigned_to":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Assigned To"},"status":{"anyOf":[{"$ref":"#/components/schemas/DefectStatus"},{"type":"null"}]},"priority":{"anyOf":[{"$ref":"#/components/schemas/DefectPriority"},{"type":"null"}]},"raised_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Raised Date"},"due_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Due Date"},"rectified_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Rectified Date"},"photo_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Photo Url"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"punch_list_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Punch List Id"},"room_label":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Room Label"},"floor_level":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Floor Level"}},"type":"object","title":"DefectUpdate"},"DeletionRequestResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"company_id":{"type":"string","format":"uuid","title":"Company Id"},"scheduled_for":{"type":"string","format":"date-time","title":"Scheduled For"},"cancelled_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Cancelled At"},"executed_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Executed At"},"created_at":{"type":"string","format":"date-time","title":"Created At"}},"type":"object","required":["id","company_id","scheduled_for","created_at"],"title":"DeletionRequestResponse"},"DeliveryLineItemResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"description":{"type":"string","title":"Description"},"quantity":{"type":"number","title":"Quantity"},"unit":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Unit"},"quantity_received":{"type":"number","title":"Quantity Received"},"received_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Received At"}},"type":"object","required":["id","description","quantity","unit","quantity_received","received_at"],"title":"DeliveryLineItemResponse"},"DeliveryResponse":{"properties":{"po_id":{"type":"string","format":"uuid","title":"Po Id"},"po_number":{"type":"string","title":"Po Number"},"supplier_name":{"type":"string","title":"Supplier Name"},"job_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Job Id"},"job_number":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Job Number"},"status":{"$ref":"#/components/schemas/POStatus"},"expected_delivery":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Expected Delivery"},"is_overdue":{"type":"boolean","title":"Is Overdue"},"total_quantity_ordered":{"type":"number","title":"Total Quantity Ordered"},"total_quantity_received":{"type":"number","title":"Total Quantity Received"},"line_items":{"items":{"$ref":"#/components/schemas/DeliveryLineItemResponse"},"type":"array","title":"Line Items"}},"type":"object","required":["po_id","po_number","supplier_name","job_id","job_number","status","expected_delivery","is_overdue","total_quantity_ordered","total_quantity_received","line_items"],"title":"DeliveryResponse"},"DeliverySummaryResponse":{"properties":{"pending_count":{"type":"integer","title":"Pending Count"},"partial_count":{"type":"integer","title":"Partial Count"},"received_count":{"type":"integer","title":"Received Count"},"overdue_count":{"type":"integer","title":"Overdue Count"},"total_value_pending":{"type":"number","title":"Total Value Pending"}},"type":"object","required":["pending_count","partial_count","received_count","overdue_count","total_value_pending"],"title":"DeliverySummaryResponse"},"DepartmentCreate":{"properties":{"name":{"type":"string","maxLength":100,"minLength":1,"title":"Name"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"parent_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Parent Id"},"color":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Color"},"sort_order":{"type":"integer","title":"Sort Order","default":0}},"type":"object","required":["name"],"title":"DepartmentCreate"},"DepartmentResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"company_id":{"type":"string","format":"uuid","title":"Company Id"},"name":{"type":"string","title":"Name"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"parent_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Parent Id"},"color":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Color"},"sort_order":{"type":"integer","title":"Sort Order"},"employee_count":{"type":"integer","title":"Employee Count","default":0},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"}},"type":"object","required":["id","company_id","name","description","parent_id","color","sort_order","created_at","updated_at"],"title":"DepartmentResponse"},"DepartmentUpdate":{"properties":{"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"parent_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Parent Id"},"color":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Color"},"sort_order":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Sort Order"}},"type":"object","title":"DepartmentUpdate"},"DepositInvoiceResponse":{"properties":{"invoice_id":{"type":"string","format":"uuid","title":"Invoice Id"},"invoice_number":{"type":"string","title":"Invoice Number"},"subtotal":{"type":"number","title":"Subtotal"},"vat_amount":{"type":"number","title":"Vat Amount"},"amount_total":{"type":"number","title":"Amount Total"},"currency":{"type":"string","title":"Currency"}},"type":"object","required":["invoice_id","invoice_number","subtotal","vat_amount","amount_total","currency"],"title":"DepositInvoiceResponse"},"DetailedHealthResponse":{"properties":{"status":{"type":"string","title":"Status"},"version":{"type":"string","title":"Version"},"environment":{"type":"string","title":"Environment"},"uptime_seconds":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Uptime Seconds"},"services":{"items":{"$ref":"#/components/schemas/ServiceStatus"},"type":"array","title":"Services"}},"type":"object","required":["status","version","environment","services"],"title":"DetailedHealthResponse"},"DevelopmentCreate":{"properties":{"name":{"type":"string","maxLength":255,"title":"Name"},"slug":{"type":"string","maxLength":255,"title":"Slug"},"tagline":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Tagline"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"address":{"type":"string","title":"Address"},"postcode":{"type":"string","maxLength":10,"title":"Postcode"},"lat":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Lat"},"lng":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Lng"},"planning_ref":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Planning Ref"},"total_units":{"type":"integer","title":"Total Units","default":0},"unit_types":{"anyOf":[{"additionalProperties":{"type":"integer"},"type":"object"},{"type":"null"}],"title":"Unit Types"},"price_from":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Price From"},"price_to":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Price To"},"completion_date":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Completion Date"},"completion_status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Completion Status"},"hero_image_s3_key":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Hero Image S3 Key"},"image_s3_keys":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Image S3 Keys"},"brochure_s3_key":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Brochure S3 Key"},"microsite_live":{"type":"boolean","title":"Microsite Live","default":false},"custom_domain":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Custom Domain"},"primary_color":{"type":"string","title":"Primary Color","default":"#534AB7"},"rightmove_account_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Rightmove Account Id"},"rightmove_feed_enabled":{"type":"boolean","title":"Rightmove Feed Enabled","default":false},"zoopla_supplier_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Zoopla Supplier Id"},"zoopla_feed_enabled":{"type":"boolean","title":"Zoopla Feed Enabled","default":false},"otm_account_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Otm Account Id"},"otm_feed_enabled":{"type":"boolean","title":"Otm Feed Enabled","default":false},"developer_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Developer Name"},"developer_phone":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Developer Phone"},"developer_email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Developer Email"},"status":{"type":"string","title":"Status","default":"draft"}},"type":"object","required":["name","slug","address","postcode"],"title":"DevelopmentCreate"},"DevelopmentUpdate":{"properties":{"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name"},"slug":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Slug"},"tagline":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Tagline"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"address":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Address"},"postcode":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Postcode"},"lat":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Lat"},"lng":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Lng"},"planning_ref":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Planning Ref"},"total_units":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Total Units"},"unit_types":{"anyOf":[{"additionalProperties":{"type":"integer"},"type":"object"},{"type":"null"}],"title":"Unit Types"},"price_from":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Price From"},"price_to":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Price To"},"completion_date":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Completion Date"},"completion_status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Completion Status"},"hero_image_s3_key":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Hero Image S3 Key"},"image_s3_keys":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Image S3 Keys"},"brochure_s3_key":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Brochure S3 Key"},"microsite_live":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Microsite Live"},"custom_domain":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Custom Domain"},"primary_color":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Primary Color"},"rightmove_account_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Rightmove Account Id"},"rightmove_feed_enabled":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Rightmove Feed Enabled"},"zoopla_supplier_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Zoopla Supplier Id"},"zoopla_feed_enabled":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Zoopla Feed Enabled"},"otm_account_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Otm Account Id"},"otm_feed_enabled":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Otm Feed Enabled"},"developer_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Developer Name"},"developer_phone":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Developer Phone"},"developer_email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Developer Email"},"status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Status"}},"type":"object","title":"DevelopmentUpdate"},"DiaryDay":{"properties":{"day":{"type":"string","format":"date","title":"Day"},"appointment_count":{"type":"integer","title":"Appointment Count"},"booked_minutes":{"type":"integer","title":"Booked Minutes"},"appointments":{"items":{"$ref":"#/components/schemas/AppointmentResponse"},"type":"array","title":"Appointments"}},"type":"object","required":["day","appointment_count","booked_minutes","appointments"],"title":"DiaryDay"},"Dimensions":{"properties":{"length":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Length"},"width":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Width"},"height":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Height"}},"type":"object","title":"Dimensions"},"DisciplinaryRecordCreate":{"properties":{"employee_id":{"type":"string","format":"uuid","title":"Employee Id"},"record_type":{"type":"string","maxLength":30,"minLength":1,"title":"Record Type"},"incident_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Incident Date"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"outcome":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Outcome"},"issued_by":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Issued By"},"expiry_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Expiry Date"}},"type":"object","required":["employee_id","record_type"],"title":"DisciplinaryRecordCreate"},"DisciplinaryRecordResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"employee_id":{"type":"string","format":"uuid","title":"Employee Id"},"company_id":{"type":"string","format":"uuid","title":"Company Id"},"record_type":{"type":"string","title":"Record Type"},"incident_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Incident Date"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"outcome":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Outcome"},"issued_by":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Issued By"},"expiry_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Expiry Date"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"}},"type":"object","required":["id","employee_id","company_id","record_type","incident_date","description","outcome","issued_by","expiry_date","created_at","updated_at"],"title":"DisciplinaryRecordResponse"},"DisciplinaryRecordUpdate":{"properties":{"record_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Record Type"},"incident_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Incident Date"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"outcome":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Outcome"},"issued_by":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Issued By"},"expiry_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Expiry Date"}},"type":"object","title":"DisciplinaryRecordUpdate"},"DisposalMethod":{"type":"string","enum":["recycled","landfill","reused","incinerated","other"],"title":"DisposalMethod"},"DocumentRenderRequest":{"properties":{"context":{"type":"object","title":"Context"}},"type":"object","title":"DocumentRenderRequest","description":"Merge field context for rendering a document template to PDF."},"DocumentSignDetailResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"document_title":{"type":"string","title":"Document Title"},"document_type":{"type":"string","title":"Document Type"},"signer_email":{"type":"string","title":"Signer Email"},"status":{"type":"string","title":"Status"},"signed_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Signed At"},"signer_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Signer Name"},"sign_url":{"type":"string","title":"Sign Url"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"ip_address":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Ip Address"},"user_agent":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"User Agent"},"document_hash":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Document Hash"},"evidence_hash":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Evidence Hash"},"expires_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Expires At"},"reminder_sent_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Reminder Sent At"},"reminder_count":{"type":"integer","title":"Reminder Count","default":0},"signature_data":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Signature Data"},"events":{"items":{"$ref":"#/components/schemas/DocumentSignEventResponse"},"type":"array","title":"Events","default":[]}},"type":"object","required":["id","document_title","document_type","signer_email","status","signed_at","signer_name","sign_url","created_at"],"title":"DocumentSignDetailResponse","description":"A single request with its full audit trail and the captured signature image."},"DocumentSignEventResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"event_type":{"type":"string","title":"Event Type"},"ip_address":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Ip Address"},"user_agent":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"User Agent"},"detail":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Detail"},"created_at":{"type":"string","format":"date-time","title":"Created At"}},"type":"object","required":["id","event_type","ip_address","user_agent","detail","created_at"],"title":"DocumentSignEventResponse"},"DocumentSignRequestCreate":{"properties":{"document_title":{"type":"string","title":"Document Title"},"document_type":{"type":"string","title":"Document Type","default":"other"},"document_html":{"type":"string","title":"Document Html"},"signer_email":{"type":"string","format":"email","title":"Signer Email"},"expires_in_days":{"type":"integer","maximum":365.0,"minimum":1.0,"title":"Expires In Days","default":30}},"type":"object","required":["document_title","document_html","signer_email"],"title":"DocumentSignRequestCreate"},"DocumentSignResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"document_title":{"type":"string","title":"Document Title"},"document_type":{"type":"string","title":"Document Type"},"signer_email":{"type":"string","title":"Signer Email"},"status":{"type":"string","title":"Status"},"signed_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Signed At"},"signer_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Signer Name"},"sign_url":{"type":"string","title":"Sign Url"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"ip_address":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Ip Address"},"user_agent":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"User Agent"},"document_hash":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Document Hash"},"evidence_hash":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Evidence Hash"},"expires_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Expires At"},"reminder_sent_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Reminder Sent At"},"reminder_count":{"type":"integer","title":"Reminder Count","default":0}},"type":"object","required":["id","document_title","document_type","signer_email","status","signed_at","signer_name","sign_url","created_at"],"title":"DocumentSignResponse"},"DocumentTemplateCreate":{"properties":{"name":{"type":"string","maxLength":100,"minLength":1,"title":"Name"},"doc_type":{"type":"string","title":"Doc Type"},"body_html":{"type":"string","title":"Body Html","default":""}},"type":"object","required":["name","doc_type"],"title":"DocumentTemplateCreate"},"DocumentTemplateResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"company_id":{"type":"string","format":"uuid","title":"Company Id"},"name":{"type":"string","title":"Name"},"doc_type":{"type":"string","title":"Doc Type"},"body_html":{"type":"string","title":"Body Html"},"is_active":{"type":"boolean","title":"Is Active"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"}},"type":"object","required":["id","company_id","name","doc_type","body_html","is_active","created_at","updated_at"],"title":"DocumentTemplateResponse"},"DocumentTemplateUpdate":{"properties":{"name":{"anyOf":[{"type":"string","maxLength":100,"minLength":1},{"type":"null"}],"title":"Name"},"doc_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Doc Type"},"body_html":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Body Html"},"is_active":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Active"}},"type":"object","title":"DocumentTemplateUpdate"},"DocumentUpdateRequest":{"properties":{"edited_content":{"type":"string","title":"Edited Content"}},"type":"object","required":["edited_content"],"title":"DocumentUpdateRequest"},"DrawingCreate":{"properties":{"related_type":{"type":"string","enum":["job","tender"],"title":"Related Type"},"related_id":{"type":"string","format":"uuid","title":"Related Id"},"drawing_number":{"type":"string","maxLength":100,"minLength":1,"title":"Drawing Number"},"title":{"type":"string","maxLength":500,"minLength":1,"title":"Title"},"discipline":{"type":"string","enum":["architectural","structural","mep","civil","survey","spec","other"],"title":"Discipline"},"status":{"type":"string","enum":["preliminary","for_approval","approved","superseded"],"title":"Status","default":"preliminary"}},"type":"object","required":["related_type","related_id","drawing_number","title","discipline"],"title":"DrawingCreate"},"DrawingDetailResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"company_id":{"type":"string","format":"uuid","title":"Company Id"},"related_type":{"type":"string","title":"Related Type"},"related_id":{"type":"string","format":"uuid","title":"Related Id"},"drawing_number":{"type":"string","title":"Drawing Number"},"title":{"type":"string","title":"Title"},"discipline":{"type":"string","title":"Discipline"},"status":{"type":"string","title":"Status"},"is_archived":{"type":"boolean","title":"Is Archived"},"revision_count":{"type":"integer","title":"Revision Count"},"latest_revision":{"anyOf":[{"$ref":"#/components/schemas/DrawingRevisionResponse"},{"type":"null"}]},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"},"revisions":{"items":{"$ref":"#/components/schemas/DrawingRevisionResponse"},"type":"array","title":"Revisions","default":[]}},"type":"object","required":["id","company_id","related_type","related_id","drawing_number","title","discipline","status","is_archived","revision_count","latest_revision","created_at","updated_at"],"title":"DrawingDetailResponse"},"DrawingResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"company_id":{"type":"string","format":"uuid","title":"Company Id"},"related_type":{"type":"string","title":"Related Type"},"related_id":{"type":"string","format":"uuid","title":"Related Id"},"drawing_number":{"type":"string","title":"Drawing Number"},"title":{"type":"string","title":"Title"},"discipline":{"type":"string","title":"Discipline"},"status":{"type":"string","title":"Status"},"is_archived":{"type":"boolean","title":"Is Archived"},"revision_count":{"type":"integer","title":"Revision Count"},"latest_revision":{"anyOf":[{"$ref":"#/components/schemas/DrawingRevisionResponse"},{"type":"null"}]},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"}},"type":"object","required":["id","company_id","related_type","related_id","drawing_number","title","discipline","status","is_archived","revision_count","latest_revision","created_at","updated_at"],"title":"DrawingResponse"},"DrawingRevisionResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"drawing_id":{"type":"string","format":"uuid","title":"Drawing Id"},"document_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Document Id"},"revision_code":{"type":"string","title":"Revision Code"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"uploaded_by_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Uploaded By Id"},"issue_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Issue Date"},"reason_for_issue":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Reason For Issue"},"is_current":{"type":"boolean","title":"Is Current","default":true},"superseded_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Superseded At"},"superseded_by_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Superseded By Id"},"created_at":{"type":"string","format":"date-time","title":"Created At"}},"type":"object","required":["id","drawing_id","document_id","revision_code","description","uploaded_by_id","created_at"],"title":"DrawingRevisionResponse"},"DrawingUpdate":{"properties":{"title":{"anyOf":[{"type":"string","maxLength":500,"minLength":1},{"type":"null"}],"title":"Title"},"discipline":{"anyOf":[{"type":"string","enum":["architectural","structural","mep","civil","survey","spec","other"]},{"type":"null"}],"title":"Discipline"},"status":{"anyOf":[{"type":"string","enum":["preliminary","for_approval","approved","superseded"]},{"type":"null"}],"title":"Status"}},"type":"object","title":"DrawingUpdate"},"EmergencyContactCreate":{"properties":{"name":{"type":"string","maxLength":255,"minLength":1,"title":"Name"},"contact_relationship":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Contact Relationship"},"phone":{"type":"string","maxLength":30,"minLength":1,"title":"Phone"},"email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Email"},"is_primary":{"type":"boolean","title":"Is Primary","default":false}},"type":"object","required":["name","phone"],"title":"EmergencyContactCreate"},"EmergencyContactResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"employee_id":{"type":"string","format":"uuid","title":"Employee Id"},"name":{"type":"string","title":"Name"},"contact_relationship":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Contact Relationship"},"phone":{"type":"string","title":"Phone"},"email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Email"},"is_primary":{"type":"boolean","title":"Is Primary"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"}},"type":"object","required":["id","employee_id","name","contact_relationship","phone","email","is_primary","created_at","updated_at"],"title":"EmergencyContactResponse"},"EmergencyContactUpdate":{"properties":{"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name"},"contact_relationship":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Contact Relationship"},"phone":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Phone"},"email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Email"},"is_primary":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Primary"}},"type":"object","title":"EmergencyContactUpdate"},"EmployeeCreate":{"properties":{"first_name":{"type":"string","maxLength":100,"minLength":1,"title":"First Name"},"last_name":{"type":"string","maxLength":100,"minLength":1,"title":"Last Name"},"preferred_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Preferred Name"},"department_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Department Id"},"reporting_to_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Reporting To Id"},"user_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"User Id"},"email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Email"},"personal_email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Personal Email"},"phone":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Phone"},"mobile":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Mobile"},"date_of_birth":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Date Of Birth"},"gender":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Gender"},"nationality":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Nationality"},"address":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Address"},"city":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"City"},"postcode":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Postcode"},"country":{"type":"string","title":"Country","default":"United Kingdom"},"national_insurance_number":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"National Insurance Number"},"employment_type":{"$ref":"#/components/schemas/EmploymentType","default":"paye"},"employment_status":{"$ref":"#/components/schemas/EmploymentStatus","default":"probation"},"start_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Start Date"},"end_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"End Date"},"probation_end_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Probation End Date"},"job_title":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Job Title"},"job_description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Job Description"},"pay_type":{"$ref":"#/components/schemas/PayType","default":"hourly"},"pay_rate":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Pay Rate"},"pay_frequency":{"anyOf":[{"$ref":"#/components/schemas/PayFrequency"},{"type":"null"}]},"tax_code":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Tax Code"},"ni_category":{"type":"string","title":"Ni Category","default":"A"},"bank_account_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Bank Account Name"},"bank_sort_code":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Bank Sort Code"},"bank_account_number":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Bank Account Number"},"pension_enrolled":{"type":"boolean","title":"Pension Enrolled","default":false},"pension_reference":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Pension Reference"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"send_onboarding":{"type":"boolean","title":"Send Onboarding","default":false}},"type":"object","required":["first_name","last_name"],"title":"EmployeeCreate"},"EmployeeDocumentResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"employee_id":{"type":"string","format":"uuid","title":"Employee Id"},"company_id":{"type":"string","format":"uuid","title":"Company Id"},"doc_type":{"type":"string","title":"Doc Type"},"name":{"type":"string","title":"Name"},"file_path":{"type":"string","title":"File Path"},"expiry_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Expiry Date"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"}},"type":"object","required":["id","employee_id","company_id","doc_type","name","file_path","expiry_date","notes","created_at","updated_at"],"title":"EmployeeDocumentResponse"},"EmployeeListItem":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"employee_number":{"type":"string","title":"Employee Number"},"full_name":{"type":"string","title":"Full Name"},"job_title":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Job Title"},"department_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Department Name"},"employment_status":{"type":"string","title":"Employment Status"},"employment_type":{"type":"string","title":"Employment Type"},"photo_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Photo Url"},"is_active":{"type":"boolean","title":"Is Active"}},"type":"object","required":["id","employee_number","full_name","job_title","department_name","employment_status","employment_type","photo_url","is_active"],"title":"EmployeeListItem"},"EmployeeQualificationsResponse":{"properties":{"worker_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Worker Id"},"worker_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Worker Name"},"qualifications":{"items":{"$ref":"#/components/schemas/QualificationResponse"},"type":"array","title":"Qualifications","default":[]}},"type":"object","title":"EmployeeQualificationsResponse","description":"A worker's cards surfaced on their employee record."},"EmployeeResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"company_id":{"type":"string","format":"uuid","title":"Company Id"},"user_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"User Id"},"department_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Department Id"},"reporting_to_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Reporting To Id"},"employee_number":{"type":"string","title":"Employee Number"},"first_name":{"type":"string","title":"First Name"},"last_name":{"type":"string","title":"Last Name"},"full_name":{"type":"string","title":"Full Name"},"preferred_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Preferred Name"},"email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Email"},"personal_email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Personal Email"},"phone":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Phone"},"mobile":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Mobile"},"date_of_birth":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Date Of Birth"},"gender":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Gender"},"nationality":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Nationality"},"address":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Address"},"city":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"City"},"postcode":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Postcode"},"country":{"type":"string","title":"Country"},"national_insurance_number":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"National Insurance Number"},"employment_type":{"type":"string","title":"Employment Type"},"employment_status":{"type":"string","title":"Employment Status"},"start_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Start Date"},"end_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"End Date"},"probation_end_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Probation End Date"},"job_title":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Job Title"},"job_description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Job Description"},"pay_type":{"type":"string","title":"Pay Type"},"pay_rate":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Pay Rate"},"pay_frequency":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Pay Frequency"},"tax_code":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Tax Code"},"ni_category":{"type":"string","title":"Ni Category"},"bank_account_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Bank Account Name"},"bank_sort_code":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Bank Sort Code"},"bank_account_number":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Bank Account Number"},"pension_enrolled":{"type":"boolean","title":"Pension Enrolled"},"pension_reference":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Pension Reference"},"photo_path":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Photo Path"},"photo_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Photo Url"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"is_active":{"type":"boolean","title":"Is Active"},"department":{"anyOf":[{"$ref":"#/components/schemas/DepartmentResponse"},{"type":"null"}]},"emergency_contacts":{"items":{"$ref":"#/components/schemas/EmergencyContactResponse"},"type":"array","title":"Emergency Contacts","default":[]},"documents":{"items":{"$ref":"#/components/schemas/EmployeeDocumentResponse"},"type":"array","title":"Documents","default":[]},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"}},"type":"object","required":["id","company_id","user_id","department_id","reporting_to_id","employee_number","first_name","last_name","full_name","preferred_name","email","personal_email","phone","mobile","date_of_birth","gender","nationality","address","city","postcode","country","national_insurance_number","employment_type","employment_status","start_date","end_date","probation_end_date","job_title","job_description","pay_type","pay_rate","pay_frequency","tax_code","ni_category","bank_account_name","bank_sort_code","bank_account_number","pension_enrolled","pension_reference","photo_path","notes","is_active","created_at","updated_at"],"title":"EmployeeResponse"},"EmployeeUpdate":{"properties":{"first_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"First Name"},"last_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Last Name"},"preferred_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Preferred Name"},"department_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Department Id"},"reporting_to_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Reporting To Id"},"user_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"User Id"},"email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Email"},"personal_email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Personal Email"},"phone":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Phone"},"mobile":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Mobile"},"date_of_birth":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Date Of Birth"},"gender":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Gender"},"nationality":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Nationality"},"address":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Address"},"city":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"City"},"postcode":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Postcode"},"country":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Country"},"national_insurance_number":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"National Insurance Number"},"employment_type":{"anyOf":[{"$ref":"#/components/schemas/EmploymentType"},{"type":"null"}]},"employment_status":{"anyOf":[{"$ref":"#/components/schemas/EmploymentStatus"},{"type":"null"}]},"start_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Start Date"},"end_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"End Date"},"probation_end_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Probation End Date"},"job_title":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Job Title"},"job_description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Job Description"},"pay_type":{"anyOf":[{"$ref":"#/components/schemas/PayType"},{"type":"null"}]},"pay_rate":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Pay Rate"},"pay_frequency":{"anyOf":[{"$ref":"#/components/schemas/PayFrequency"},{"type":"null"}]},"tax_code":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Tax Code"},"ni_category":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Ni Category"},"bank_account_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Bank Account Name"},"bank_sort_code":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Bank Sort Code"},"bank_account_number":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Bank Account Number"},"pension_enrolled":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Pension Enrolled"},"pension_reference":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Pension Reference"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"is_active":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Active"}},"type":"object","title":"EmployeeUpdate"},"EmploymentStatus":{"type":"string","enum":["active","probation","notice","terminated"],"title":"EmploymentStatus"},"EmploymentType":{"type":"string","enum":["paye","self_employed","contractor"],"title":"EmploymentType"},"EnquiryCreate":{"properties":{"development_id":{"type":"string","title":"Development Id"},"unit_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Unit Id"},"first_name":{"type":"string","maxLength":100,"title":"First Name"},"last_name":{"type":"string","maxLength":100,"title":"Last Name"},"email":{"type":"string","maxLength":255,"title":"Email"},"phone":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Phone"},"source":{"type":"string","title":"Source","default":"website"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"}},"type":"object","required":["development_id","first_name","last_name","email"],"title":"EnquiryCreate","description":"Public enquiry submission — no auth required (microsite / portal)."},"EnquiryUpdate":{"properties":{"status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Status"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"phone":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Phone"},"source":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source"}},"type":"object","title":"EnquiryUpdate"},"EntitySchema":{"properties":{"entity":{"type":"string","title":"Entity"},"fields":{"items":{"$ref":"#/components/schemas/FieldDefinition"},"type":"array","title":"Fields"}},"type":"object","required":["entity","fields"],"title":"EntitySchema"},"EntityType":{"type":"string","enum":["tender","quote","job"],"title":"EntityType"},"EnvironmentalRecordCreate":{"properties":{"job_id":{"type":"string","format":"uuid","title":"Job Id"},"record_date":{"type":"string","format":"date","title":"Record Date"},"waste_generated_kg":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Waste Generated Kg"},"waste_recycled_kg":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Waste Recycled Kg"},"waste_to_landfill_kg":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Waste To Landfill Kg"},"carbon_kg_co2e":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Carbon Kg Co2E"},"water_usage_litres":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Water Usage Litres"},"fuel_usage_litres":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Fuel Usage Litres"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"created_by_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Created By Name"},"waste_items":{"items":{"$ref":"#/components/schemas/WasteItemCreate"},"type":"array","title":"Waste Items","default":[]}},"type":"object","required":["job_id","record_date"],"title":"EnvironmentalRecordCreate"},"EnvironmentalRecordResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"job_id":{"type":"string","format":"uuid","title":"Job Id"},"record_date":{"type":"string","format":"date","title":"Record Date"},"waste_generated_kg":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Waste Generated Kg"},"waste_recycled_kg":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Waste Recycled Kg"},"waste_to_landfill_kg":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Waste To Landfill Kg"},"recycling_rate":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Recycling Rate"},"carbon_kg_co2e":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Carbon Kg Co2E"},"water_usage_litres":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Water Usage Litres"},"fuel_usage_litres":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Fuel Usage Litres"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"created_by_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Created By Name"},"waste_items":{"items":{"$ref":"#/components/schemas/WasteItemResponse"},"type":"array","title":"Waste Items","default":[]},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"}},"type":"object","required":["id","job_id","record_date","waste_generated_kg","waste_recycled_kg","waste_to_landfill_kg","recycling_rate","carbon_kg_co2e","water_usage_litres","fuel_usage_litres","notes","created_by_name","created_at","updated_at"],"title":"EnvironmentalRecordResponse"},"EnvironmentalRecordUpdate":{"properties":{"record_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Record Date"},"waste_generated_kg":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Waste Generated Kg"},"waste_recycled_kg":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Waste Recycled Kg"},"waste_to_landfill_kg":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Waste To Landfill Kg"},"carbon_kg_co2e":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Carbon Kg Co2E"},"water_usage_litres":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Water Usage Litres"},"fuel_usage_litres":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Fuel Usage Litres"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"created_by_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Created By Name"}},"type":"object","title":"EnvironmentalRecordUpdate"},"EnvironmentalSummary":{"properties":{"job_id":{"type":"string","format":"uuid","title":"Job Id"},"total_waste_generated_kg":{"type":"number","title":"Total Waste Generated Kg"},"total_waste_recycled_kg":{"type":"number","title":"Total Waste Recycled Kg"},"total_waste_to_landfill_kg":{"type":"number","title":"Total Waste To Landfill Kg"},"overall_recycling_rate":{"type":"number","title":"Overall Recycling Rate"},"total_carbon_kg_co2e":{"type":"number","title":"Total Carbon Kg Co2E"},"total_water_usage_litres":{"type":"number","title":"Total Water Usage Litres"},"total_fuel_usage_litres":{"type":"number","title":"Total Fuel Usage Litres"},"record_count":{"type":"integer","title":"Record Count"}},"type":"object","required":["job_id","total_waste_generated_kg","total_waste_recycled_kg","total_waste_to_landfill_kg","overall_recycling_rate","total_carbon_kg_co2e","total_water_usage_litres","total_fuel_usage_litres","record_count"],"title":"EnvironmentalSummary"},"EscrowCreateRequest":{"properties":{"listing_id":{"type":"string","format":"uuid","title":"Listing Id"},"payee_id":{"type":"string","format":"uuid","title":"Payee Id"},"amount_pence":{"type":"integer","title":"Amount Pence"},"milestone_title":{"type":"string","title":"Milestone Title"}},"type":"object","required":["listing_id","payee_id","amount_pence","milestone_title"],"title":"EscrowCreateRequest"},"EscrowDisputeRequest":{"properties":{"reason":{"type":"string","title":"Reason"}},"type":"object","required":["reason"],"title":"EscrowDisputeRequest"},"EscrowResolveRequest":{"properties":{"release_to":{"type":"string","enum":["payer","payee"],"title":"Release To"},"notes":{"type":"string","title":"Notes"}},"type":"object","required":["release_to","notes"],"title":"EscrowResolveRequest"},"EscrowResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"listing_id":{"type":"string","format":"uuid","title":"Listing Id"},"payer_profile_id":{"type":"string","format":"uuid","title":"Payer Profile Id"},"payee_id":{"type":"string","format":"uuid","title":"Payee Id"},"amount_pence":{"type":"integer","title":"Amount Pence"},"milestone_title":{"type":"string","title":"Milestone Title"},"status":{"type":"string","title":"Status"},"created_at":{"type":"string","title":"Created At"},"released_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Released At"},"dispute_reason":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Dispute Reason"},"resolve_notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Resolve Notes"}},"type":"object","required":["id","listing_id","payer_profile_id","payee_id","amount_pence","milestone_title","status","created_at"],"title":"EscrowResponse"},"EstijobAccreditationCreate":{"properties":{"name":{"type":"string","maxLength":100,"minLength":1,"title":"Name"},"cert_number":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cert Number"},"body":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Body"},"issued_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Issued Date"},"expiry_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Expiry Date"},"document_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Document Url"}},"type":"object","required":["name"],"title":"EstijobAccreditationCreate"},"EstijobAccreditationResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"profile_id":{"type":"string","format":"uuid","title":"Profile Id"},"name":{"type":"string","title":"Name"},"cert_number":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cert Number"},"body":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Body"},"issued_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Issued Date"},"expiry_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Expiry Date"},"document_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Document Url"},"is_verified":{"type":"boolean","title":"Is Verified"},"source":{"type":"string","title":"Source"},"is_expired":{"type":"boolean","title":"Is Expired","default":false},"created_at":{"type":"string","format":"date-time","title":"Created At"}},"type":"object","required":["id","profile_id","name","cert_number","body","issued_date","expiry_date","document_url","is_verified","source","created_at"],"title":"EstijobAccreditationResponse"},"EstijobAdminStatsResponse":{"properties":{"total_listings_open":{"type":"integer","title":"Total Listings Open"},"total_listings":{"type":"integer","title":"Total Listings"},"total_bids":{"type":"integer","title":"Total Bids"},"total_profiles":{"type":"integer","title":"Total Profiles"},"total_estijob_users":{"type":"integer","title":"Total Estijob Users"}},"type":"object","required":["total_listings_open","total_listings","total_bids","total_profiles","total_estijob_users"],"title":"EstijobAdminStatsResponse"},"EstijobAlertCreate":{"properties":{"postcode_prefix":{"type":"string","maxLength":10,"minLength":2,"title":"Postcode Prefix"},"category_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Category Id"},"radius_miles":{"type":"integer","maximum":200.0,"minimum":1.0,"title":"Radius Miles","default":25}},"type":"object","required":["postcode_prefix"],"title":"EstijobAlertCreate"},"EstijobAlertResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"profile_id":{"type":"string","format":"uuid","title":"Profile Id"},"category_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Category Id"},"postcode_prefix":{"type":"string","title":"Postcode Prefix"},"radius_miles":{"type":"integer","title":"Radius Miles"},"is_active":{"type":"boolean","title":"Is Active"},"created_at":{"type":"string","format":"date-time","title":"Created At"}},"type":"object","required":["id","profile_id","category_id","postcode_prefix","radius_miles","is_active","created_at"],"title":"EstijobAlertResponse"},"EstijobBidCreateRequest":{"properties":{"listing_id":{"type":"string","format":"uuid","title":"Listing Id"},"amount":{"type":"number","exclusiveMinimum":0.0,"title":"Amount"},"message":{"type":"string","minLength":1,"title":"Message"},"is_estimark_generated":{"type":"boolean","title":"Is Estimark Generated","default":false},"quote_snapshot":{"anyOf":[{"type":"object"},{"type":"null"}],"title":"Quote Snapshot"}},"type":"object","required":["listing_id","amount","message"],"title":"EstijobBidCreateRequest"},"EstijobBidResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"listing_id":{"type":"string","format":"uuid","title":"Listing Id"},"profile_id":{"type":"string","format":"uuid","title":"Profile Id"},"amount":{"type":"number","title":"Amount"},"message":{"type":"string","title":"Message"},"status":{"type":"string","title":"Status"},"is_estimark_generated":{"type":"boolean","title":"Is Estimark Generated"},"quote_snapshot":{"anyOf":[{"type":"object"},{"type":"null"}],"title":"Quote Snapshot"},"contact_revealed":{"type":"boolean","title":"Contact Revealed"},"estimark_quote_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Estimark Quote Id"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"listing_title":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Listing Title"}},"type":"object","required":["id","listing_id","profile_id","amount","message","status","is_estimark_generated","quote_snapshot","contact_revealed","estimark_quote_id","created_at"],"title":"EstijobBidResponse"},"EstijobBidUpdateRequest":{"properties":{"amount":{"type":"number","exclusiveMinimum":0.0,"title":"Amount"},"message":{"type":"string","minLength":1,"title":"Message"},"quote_snapshot":{"anyOf":[{"type":"object"},{"type":"null"}],"title":"Quote Snapshot"}},"type":"object","required":["amount","message"],"title":"EstijobBidUpdateRequest"},"EstijobInviteCreate":{"properties":{"profile_id":{"type":"string","format":"uuid","title":"Profile Id"},"message":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Message"}},"type":"object","required":["profile_id"],"title":"EstijobInviteCreate"},"EstijobInviteResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"listing_id":{"type":"string","format":"uuid","title":"Listing Id"},"profile_id":{"type":"string","format":"uuid","title":"Profile Id"},"status":{"type":"string","title":"Status"},"message":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Message"},"created_at":{"type":"string","format":"date-time","title":"Created At"}},"type":"object","required":["id","listing_id","profile_id","status","message","created_at"],"title":"EstijobInviteResponse"},"EstijobLeadListingSnippet":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"title":{"type":"string","title":"Title"},"postcode":{"type":"string","title":"Postcode"},"budget_min":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Budget Min"},"budget_max":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Budget Max"}},"type":"object","required":["id","title","postcode","budget_min","budget_max"],"title":"EstijobLeadListingSnippet"},"EstijobLeadResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"listing_id":{"type":"string","format":"uuid","title":"Listing Id"},"listing":{"$ref":"#/components/schemas/EstijobLeadListingSnippet"},"amount":{"type":"number","title":"Amount"},"status":{"type":"string","title":"Status"},"estimark_quote_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Estimark Quote Id"},"created_at":{"type":"string","format":"date-time","title":"Created At"}},"type":"object","required":["id","listing_id","listing","amount","status","estimark_quote_id","created_at"],"title":"EstijobLeadResponse"},"EstijobListingCreateRequest":{"properties":{"title":{"type":"string","maxLength":500,"minLength":1,"title":"Title"},"description":{"type":"string","minLength":10,"title":"Description"},"category_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Category Id"},"postcode":{"type":"string","minLength":2,"title":"Postcode"},"budget_min":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Budget Min"},"budget_max":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Budget Max"},"urgency":{"type":"string","title":"Urgency","default":"flexible"},"photos":{"items":{"type":"string"},"type":"array","title":"Photos","default":[]},"poster_name":{"type":"string","minLength":1,"title":"Poster Name"},"poster_email":{"type":"string","format":"email","title":"Poster Email"},"is_invite_only":{"type":"boolean","title":"Is Invite Only","default":false}},"type":"object","required":["title","description","postcode","poster_name","poster_email"],"title":"EstijobListingCreateRequest"},"EstijobListingDetailResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"title":{"type":"string","title":"Title"},"description":{"type":"string","title":"Description"},"category_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Category Id"},"postcode":{"type":"string","title":"Postcode"},"lat":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Lat"},"lng":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Lng"},"budget_min":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Budget Min"},"budget_max":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Budget Max"},"urgency":{"type":"string","title":"Urgency"},"status":{"type":"string","title":"Status"},"photos":{"items":{},"type":"array","title":"Photos"},"poster_name":{"type":"string","title":"Poster Name"},"bid_count":{"type":"integer","title":"Bid Count"},"is_featured":{"type":"boolean","title":"Is Featured"},"featured_until":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Featured Until"},"view_count":{"type":"integer","title":"View Count"},"expires_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Expires At"},"awarded_bid_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Awarded Bid Id"},"is_invite_only":{"type":"boolean","title":"Is Invite Only","default":false},"urgent_until":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Urgent Until"},"poster_avg_rating":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Poster Avg Rating"},"has_applied":{"type":"boolean","title":"Has Applied","default":false},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"},"bids_preview":{"items":{"$ref":"#/components/schemas/BidPreviewItem"},"type":"array","title":"Bids Preview","default":[]},"bid_min":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Bid Min"},"bid_max":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Bid Max"},"similar_listings":{"items":{"$ref":"#/components/schemas/EstijobListingResponse"},"type":"array","title":"Similar Listings","default":[]}},"type":"object","required":["id","title","description","category_id","postcode","lat","lng","budget_min","budget_max","urgency","status","photos","poster_name","bid_count","is_featured","featured_until","view_count","expires_at","awarded_bid_id","created_at","updated_at"],"title":"EstijobListingDetailResponse"},"EstijobListingResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"title":{"type":"string","title":"Title"},"description":{"type":"string","title":"Description"},"category_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Category Id"},"postcode":{"type":"string","title":"Postcode"},"lat":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Lat"},"lng":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Lng"},"budget_min":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Budget Min"},"budget_max":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Budget Max"},"urgency":{"type":"string","title":"Urgency"},"status":{"type":"string","title":"Status"},"photos":{"items":{},"type":"array","title":"Photos"},"poster_name":{"type":"string","title":"Poster Name"},"bid_count":{"type":"integer","title":"Bid Count"},"is_featured":{"type":"boolean","title":"Is Featured"},"featured_until":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Featured Until"},"view_count":{"type":"integer","title":"View Count"},"expires_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Expires At"},"awarded_bid_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Awarded Bid Id"},"is_invite_only":{"type":"boolean","title":"Is Invite Only","default":false},"urgent_until":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Urgent Until"},"poster_avg_rating":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Poster Avg Rating"},"has_applied":{"type":"boolean","title":"Has Applied","default":false},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"}},"type":"object","required":["id","title","description","category_id","postcode","lat","lng","budget_min","budget_max","urgency","status","photos","poster_name","bid_count","is_featured","featured_until","view_count","expires_at","awarded_bid_id","created_at","updated_at"],"title":"EstijobListingResponse"},"EstijobLoginRequest":{"properties":{"email":{"type":"string","format":"email","title":"Email"},"password":{"type":"string","title":"Password"}},"type":"object","required":["email","password"],"title":"EstijobLoginRequest"},"EstijobMessageCreateRequest":{"properties":{"bid_id":{"type":"string","format":"uuid","title":"Bid Id"},"body":{"type":"string","minLength":1,"title":"Body"}},"type":"object","required":["bid_id","body"],"title":"EstijobMessageCreateRequest"},"EstijobMessageResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"bid_id":{"type":"string","format":"uuid","title":"Bid Id"},"sender_company_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Sender Company Id"},"sender_estijob_user_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Sender Estijob User Id"},"body":{"type":"string","title":"Body"},"read_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Read At"},"created_at":{"type":"string","format":"date-time","title":"Created At"}},"type":"object","required":["id","bid_id","sender_company_id","sender_estijob_user_id","body","read_at","created_at"],"title":"EstijobMessageResponse"},"EstijobNotificationResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"type":{"type":"string","title":"Type"},"title":{"type":"string","title":"Title"},"body":{"type":"string","title":"Body"},"entity_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Entity Type"},"entity_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Entity Id"},"is_read":{"type":"boolean","title":"Is Read"},"created_at":{"type":"string","format":"date-time","title":"Created At"}},"type":"object","required":["id","type","title","body","entity_type","entity_id","is_read","created_at"],"title":"EstijobNotificationResponse"},"EstijobPortfolioItemCreate":{"properties":{"title":{"type":"string","maxLength":200,"minLength":1,"title":"Title"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"job_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Job Type"},"location":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Location"},"year_completed":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Year Completed"},"photos":{"items":{"$ref":"#/components/schemas/PortfolioPhoto"},"type":"array","title":"Photos","default":[]}},"type":"object","required":["title"],"title":"EstijobPortfolioItemCreate"},"EstijobPortfolioItemResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"profile_id":{"type":"string","format":"uuid","title":"Profile Id"},"title":{"type":"string","title":"Title"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"job_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Job Type"},"location":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Location"},"year_completed":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Year Completed"},"photos":{"items":{},"type":"array","title":"Photos"},"sort_order":{"type":"integer","title":"Sort Order"},"created_at":{"type":"string","format":"date-time","title":"Created At"}},"type":"object","required":["id","profile_id","title","description","job_type","location","year_completed","photos","sort_order","created_at"],"title":"EstijobPortfolioItemResponse"},"EstijobPortfolioItemUpdate":{"properties":{"title":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Title"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"job_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Job Type"},"location":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Location"},"year_completed":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Year Completed"},"photos":{"anyOf":[{"items":{"$ref":"#/components/schemas/PortfolioPhoto"},"type":"array"},{"type":"null"}],"title":"Photos"}},"type":"object","title":"EstijobPortfolioItemUpdate"},"EstijobProfileResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"company_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Company Id"},"estijob_user_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Estijob User Id"},"bio":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Bio"},"trades":{"items":{"type":"string"},"type":"array","title":"Trades"},"postcode":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Postcode"},"radius_miles":{"type":"integer","title":"Radius Miles"},"avg_rating":{"type":"number","title":"Avg Rating"},"review_count":{"type":"integer","title":"Review Count"},"years_experience":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Years Experience"},"accreditations":{"type":"object","title":"Accreditations"},"portfolio_photos":{"items":{},"type":"array","title":"Portfolio Photos"},"is_verified_estimark":{"type":"boolean","title":"Is Verified Estimark"},"is_boosted":{"type":"boolean","title":"Is Boosted"},"boosted_until":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Boosted Until"},"available_from":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Available From"},"completeness_score":{"type":"integer","title":"Completeness Score","default":0},"slug":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Slug"},"blocked_dates":{"items":{"type":"string"},"type":"array","title":"Blocked Dates","default":[]},"created_at":{"type":"string","format":"date-time","title":"Created At"}},"type":"object","required":["id","company_id","estijob_user_id","bio","trades","postcode","radius_miles","avg_rating","review_count","years_experience","accreditations","portfolio_photos","is_verified_estimark","is_boosted","boosted_until","created_at"],"title":"EstijobProfileResponse"},"EstijobProfileUpdateRequest":{"properties":{"bio":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Bio"},"trades":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Trades"},"postcode":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Postcode"},"radius_miles":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Radius Miles"},"years_experience":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Years Experience"},"accreditations":{"anyOf":[{"type":"object"},{"type":"null"}],"title":"Accreditations"},"available_from":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Available From"}},"type":"object","title":"EstijobProfileUpdateRequest"},"EstijobReviewResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"listing_id":{"type":"string","format":"uuid","title":"Listing Id"},"reviewee_profile_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Reviewee Profile Id"},"rating":{"type":"integer","title":"Rating"},"body":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Body"},"direction":{"type":"string","title":"Direction"},"reviewer_name":{"type":"string","title":"Reviewer Name","default":"Anonymous"},"created_at":{"type":"string","format":"date-time","title":"Created At"}},"type":"object","required":["id","listing_id","rating","body","direction","created_at"],"title":"EstijobReviewResponse"},"EstijobSavedResponse":{"properties":{"saved":{"type":"boolean","title":"Saved"}},"type":"object","required":["saved"],"title":"EstijobSavedResponse"},"EstijobShowcaseBookRequest":{"properties":{"title":{"type":"string","title":"Title"},"tagline":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Tagline"},"image_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Image Url"},"use_discount":{"type":"boolean","title":"Use Discount","default":false}},"type":"object","required":["title"],"title":"EstijobShowcaseBookRequest"},"EstijobShowcaseBookingResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"profile_id":{"type":"string","format":"uuid","title":"Profile Id"},"title":{"type":"string","title":"Title"},"tagline":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Tagline"},"image_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Image Url"},"status":{"type":"string","title":"Status"},"price_paid":{"type":"number","title":"Price Paid"},"discount_pct":{"type":"number","title":"Discount Pct"},"starts_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Starts At"},"ends_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Ends At"},"created_at":{"type":"string","format":"date-time","title":"Created At"}},"type":"object","required":["id","profile_id","title","tagline","image_url","status","price_paid","discount_pct","starts_at","ends_at","created_at"],"title":"EstijobShowcaseBookingResponse"},"EstijobSiteSettingsResponse":{"properties":{"showcase_price_gbp":{"type":"number","title":"Showcase Price Gbp"},"showcase_discount_pct":{"type":"integer","title":"Showcase Discount Pct"}},"type":"object","required":["showcase_price_gbp","showcase_discount_pct"],"title":"EstijobSiteSettingsResponse"},"EstijobSiteSettingsUpdateRequest":{"properties":{"showcase_price_gbp":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Showcase Price Gbp"},"showcase_discount_pct":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Showcase Discount Pct"}},"type":"object","title":"EstijobSiteSettingsUpdateRequest"},"EstijobStatsResponse":{"properties":{"total_open":{"type":"integer","title":"Total Open"},"bids_this_week":{"type":"integer","title":"Bids This Week"},"total_contractors":{"type":"integer","title":"Total Contractors"},"total_completed":{"type":"integer","title":"Total Completed"}},"type":"object","required":["total_open","bids_this_week","total_contractors","total_completed"],"title":"EstijobStatsResponse"},"EstijobTokenResponse":{"properties":{"access_token":{"type":"string","title":"Access Token"},"token_type":{"type":"string","title":"Token Type","default":"bearer"},"user_type":{"type":"string","title":"User Type"},"profile_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Profile Id"}},"type":"object","required":["access_token","user_type"],"title":"EstijobTokenResponse"},"EstijobUnreadCountResponse":{"properties":{"count":{"type":"integer","title":"Count"}},"type":"object","required":["count"],"title":"EstijobUnreadCountResponse"},"EstijobUserRegisterRequest":{"properties":{"email":{"type":"string","format":"email","title":"Email"},"password":{"type":"string","minLength":8,"title":"Password"},"first_name":{"type":"string","minLength":1,"title":"First Name"},"last_name":{"type":"string","minLength":1,"title":"Last Name"},"phone":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Phone"},"user_type":{"type":"string","title":"User Type","default":"contractor"},"bio":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Bio"},"trades":{"items":{"type":"string"},"type":"array","title":"Trades","default":[]},"postcode":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Postcode"}},"type":"object","required":["email","password","first_name","last_name"],"title":"EstijobUserRegisterRequest"},"EstimateRequest":{"properties":{"project_description":{"type":"string","maxLength":2000,"title":"Project Description"},"region":{"type":"string","maxLength":50,"title":"Region"},"project_type":{"type":"string","pattern":"^(residential|commercial|mixed)$","title":"Project Type"},"additional_context":{"anyOf":[{"type":"string","maxLength":500},{"type":"null"}],"title":"Additional Context"}},"type":"object","required":["project_description","region","project_type"],"title":"EstimateRequest"},"ExpenseCategory":{"type":"string","enum":["travel","accommodation","subsistence","materials","tools","other"],"title":"ExpenseCategory"},"ExpenseClaimCreate":{"properties":{"claim_date":{"type":"string","format":"date","title":"Claim Date"},"description":{"type":"string","maxLength":500,"minLength":1,"title":"Description"},"job_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Job Id"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"items":{"items":{"$ref":"#/components/schemas/ExpenseItemCreate"},"type":"array","title":"Items","default":[]}},"type":"object","required":["claim_date","description"],"title":"ExpenseClaimCreate"},"ExpenseClaimIn":{"properties":{"employee_id":{"type":"string","format":"uuid","title":"Employee Id"},"job_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Job Id"},"claim_date":{"type":"string","title":"Claim Date"},"description":{"type":"string","title":"Description"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"items":{"items":{"$ref":"#/components/schemas/ExpenseItemIn"},"type":"array","title":"Items","default":[]}},"type":"object","required":["employee_id","claim_date","description"],"title":"ExpenseClaimIn"},"ExpenseClaimPatch":{"properties":{"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"items":{"anyOf":[{"items":{"$ref":"#/components/schemas/ExpenseItemIn"},"type":"array"},{"type":"null"}],"title":"Items"}},"type":"object","title":"ExpenseClaimPatch"},"ExpenseClaimResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"employee_id":{"type":"string","format":"uuid","title":"Employee Id"},"company_id":{"type":"string","format":"uuid","title":"Company Id"},"job_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Job Id"},"claim_date":{"type":"string","format":"date","title":"Claim Date"},"description":{"type":"string","title":"Description"},"status":{"type":"string","title":"Status"},"total_amount":{"type":"number","title":"Total Amount"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"approved_by":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Approved By"},"approved_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Approved At"},"paid_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Paid At"},"items":{"items":{"$ref":"#/components/schemas/ExpenseItemResponse"},"type":"array","title":"Items","default":[]},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"}},"type":"object","required":["id","employee_id","company_id","job_id","claim_date","description","status","total_amount","notes","approved_by","approved_at","paid_at","created_at","updated_at"],"title":"ExpenseClaimResponse"},"ExpenseItemCreate":{"properties":{"description":{"type":"string","maxLength":500,"minLength":1,"title":"Description"},"category":{"type":"string","title":"Category","default":"other"},"amount":{"type":"number","exclusiveMinimum":0.0,"title":"Amount"},"vat_amount":{"type":"number","title":"Vat Amount","default":0.0},"receipt_path":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Receipt Path"}},"type":"object","required":["description","amount"],"title":"ExpenseItemCreate"},"ExpenseItemIn":{"properties":{"description":{"type":"string","title":"Description"},"category":{"$ref":"#/components/schemas/ExpenseCategory","default":"other"},"amount":{"type":"number","title":"Amount"},"vat_amount":{"type":"number","title":"Vat Amount","default":0.0},"receipt_path":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Receipt Path"}},"type":"object","required":["description","amount"],"title":"ExpenseItemIn"},"ExpenseItemResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"claim_id":{"type":"string","format":"uuid","title":"Claim Id"},"description":{"type":"string","title":"Description"},"category":{"type":"string","title":"Category"},"amount":{"type":"number","title":"Amount"},"vat_amount":{"type":"number","title":"Vat Amount"},"receipt_path":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Receipt Path"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"}},"type":"object","required":["id","claim_id","description","category","amount","vat_amount","receipt_path","created_at","updated_at"],"title":"ExpenseItemResponse"},"ExportRequestResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"status":{"type":"string","title":"Status"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"expires_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Expires At"}},"type":"object","required":["id","status","created_at"],"title":"ExportRequestResponse"},"F10Create":{"properties":{"project_name":{"type":"string","title":"Project Name"},"client_name":{"type":"string","title":"Client Name"},"site_address":{"type":"string","title":"Site Address"},"principal_designer":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Principal Designer"},"principal_contractor":{"type":"string","title":"Principal Contractor"},"local_authority":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Local Authority"},"construction_phase_start":{"type":"string","format":"date","title":"Construction Phase Start"},"expected_duration_weeks":{"type":"integer","title":"Expected Duration Weeks","default":1},"max_workers":{"type":"integer","title":"Max Workers","default":1},"answers":{"type":"object","title":"Answers","default":{}},"job_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Job Id"}},"type":"object","required":["project_name","client_name","site_address","principal_contractor","construction_phase_start"],"title":"F10Create"},"F10Update":{"properties":{"project_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Project Name"},"client_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Client Name"},"site_address":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Site Address"},"principal_designer":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Principal Designer"},"principal_contractor":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Principal Contractor"},"local_authority":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Local Authority"},"construction_phase_start":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Construction Phase Start"},"expected_duration_weeks":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Expected Duration Weeks"},"max_workers":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Max Workers"},"answers":{"anyOf":[{"type":"object"},{"type":"null"}],"title":"Answers"}},"type":"object","title":"F10Update"},"FeatureFlagCreate":{"properties":{"key":{"type":"string","title":"Key"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"is_enabled":{"type":"boolean","title":"Is Enabled","default":false}},"type":"object","required":["key"],"title":"FeatureFlagCreate"},"FieldDefinition":{"properties":{"key":{"type":"string","title":"Key"},"label":{"type":"string","title":"Label"},"type":{"type":"string","title":"Type"},"filterable":{"type":"boolean","title":"Filterable","default":true},"sortable":{"type":"boolean","title":"Sortable","default":false},"aggregatable":{"type":"boolean","title":"Aggregatable","default":false},"options":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Options"}},"type":"object","required":["key","label","type"],"title":"FieldDefinition"},"FieldType":{"type":"string","enum":["text","number","date","dropdown"],"title":"FieldType"},"FlagRequest":{"properties":{"reason":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Reason"}},"type":"object","title":"FlagRequest"},"FleetAlert":{"properties":{"alert_type":{"type":"string","title":"Alert Type"},"entity_type":{"type":"string","title":"Entity Type"},"entity_id":{"type":"string","format":"uuid","title":"Entity Id"},"entity_name":{"type":"string","title":"Entity Name"},"due_date":{"type":"string","format":"date","title":"Due Date"},"days_remaining":{"type":"integer","title":"Days Remaining"},"severity":{"type":"string","title":"Severity"}},"type":"object","required":["alert_type","entity_type","entity_id","entity_name","due_date","days_remaining","severity"],"title":"FleetAlert"},"ForgotPasswordRequest":{"properties":{"email":{"type":"string","format":"email","title":"Email"}},"type":"object","required":["email"],"title":"ForgotPasswordRequest"},"FormCreate":{"properties":{"name":{"type":"string","maxLength":255,"minLength":1,"title":"Name"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"entity_type":{"$ref":"#/components/schemas/FormEntityType","default":"job"},"schema":{"items":{"type":"object"},"type":"array","title":"Schema"},"is_required":{"type":"boolean","title":"Is Required","default":false}},"type":"object","required":["name"],"title":"FormCreate"},"FormEntityType":{"type":"string","enum":["job","repair","property","void","standalone"],"title":"FormEntityType","description":"What a form can be attached to."},"FormResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"company_id":{"type":"string","format":"uuid","title":"Company Id"},"name":{"type":"string","title":"Name"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"entity_type":{"$ref":"#/components/schemas/FormEntityType"},"schema":{"items":{"type":"object"},"type":"array","title":"Schema"},"version":{"type":"integer","title":"Version"},"is_active":{"type":"boolean","title":"Is Active"},"is_required":{"type":"boolean","title":"Is Required"},"created_at":{"type":"string","format":"date-time","title":"Created At"}},"type":"object","required":["id","company_id","name","description","entity_type","version","is_active","is_required","created_at"],"title":"FormResponse"},"FormUpdate":{"properties":{"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"schema":{"anyOf":[{"items":{"type":"object"},"type":"array"},{"type":"null"}],"title":"Schema"},"is_required":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Required"},"is_active":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Active"}},"type":"object","title":"FormUpdate"},"GanttJobResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"title":{"type":"string","title":"Title"},"job_number":{"type":"string","title":"Job Number"},"status":{"$ref":"#/components/schemas/JobStatus"},"start_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Start Date"},"end_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"End Date"},"milestones":{"items":{"$ref":"#/components/schemas/GanttMilestoneItem"},"type":"array","title":"Milestones","default":[]}},"type":"object","required":["id","title","job_number","status","start_date","end_date"],"title":"GanttJobResponse"},"GanttMilestoneItem":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"title":{"type":"string","title":"Title"},"target_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Target Date"},"completed":{"type":"boolean","title":"Completed"}},"type":"object","required":["id","title","target_date","completed"],"title":"GanttMilestoneItem"},"GenerateReturnRequest":{"properties":{"tax_month":{"type":"integer","maximum":12.0,"minimum":1.0,"title":"Tax Month"},"tax_year":{"type":"integer","minimum":2000.0,"title":"Tax Year"}},"type":"object","required":["tax_month","tax_year"],"title":"GenerateReturnRequest"},"HSAttendeeCreate":{"properties":{"name":{"type":"string","title":"Name"},"role":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Role"}},"type":"object","required":["name"],"title":"HSAttendeeCreate"},"HSAttendeeResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"name":{"type":"string","title":"Name"},"role":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Role"},"signed":{"type":"boolean","title":"Signed"},"created_at":{"type":"string","format":"date-time","title":"Created At"}},"type":"object","required":["id","name","role","signed","created_at"],"title":"HSAttendeeResponse"},"HSDocumentCreate":{"properties":{"doc_type":{"$ref":"#/components/schemas/HSDocumentType"},"title":{"type":"string","title":"Title"},"answers":{"type":"object","title":"Answers","default":{}}},"type":"object","required":["doc_type","title"],"title":"HSDocumentCreate"},"HSDocumentResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"company_id":{"type":"string","format":"uuid","title":"Company Id"},"doc_type":{"$ref":"#/components/schemas/HSDocumentType"},"title":{"type":"string","title":"Title"},"reference_number":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Reference Number"},"status":{"$ref":"#/components/schemas/HSDocumentStatus"},"answers":{"type":"object","title":"Answers"},"attendees":{"items":{"$ref":"#/components/schemas/HSAttendeeResponse"},"type":"array","title":"Attendees","default":[]},"completed_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Completed At"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"}},"type":"object","required":["id","company_id","doc_type","title","reference_number","status","answers","completed_at","created_at","updated_at"],"title":"HSDocumentResponse"},"HSDocumentStatus":{"type":"string","enum":["draft","complete"],"title":"HSDocumentStatus"},"HSDocumentType":{"type":"string","enum":["method_statement","risk_assessment","toolbox_talk","coshh","near_miss","accident_report"],"title":"HSDocumentType"},"HSDocumentUpdate":{"properties":{"title":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Title"},"status":{"anyOf":[{"$ref":"#/components/schemas/HSDocumentStatus"},{"type":"null"}]},"answers":{"anyOf":[{"type":"object"},{"type":"null"}],"title":"Answers"}},"type":"object","title":"HSDocumentUpdate"},"HSPolicyCreate":{"properties":{"title":{"type":"string","maxLength":500,"minLength":1,"title":"Title"},"policy_type":{"$ref":"#/components/schemas/HSPolicyType","default":"health_safety"},"content":{"type":"string","minLength":1,"title":"Content"},"version":{"type":"string","title":"Version","default":"1.0"},"issued_date":{"type":"string","format":"date","title":"Issued Date"},"review_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Review Date"},"issued_by":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Issued By"}},"type":"object","required":["title","content","issued_date"],"title":"HSPolicyCreate"},"HSPolicyResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"title":{"type":"string","title":"Title"},"policy_type":{"$ref":"#/components/schemas/HSPolicyType"},"content":{"type":"string","title":"Content"},"version":{"type":"string","title":"Version"},"issued_date":{"type":"string","format":"date","title":"Issued Date"},"review_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Review Date"},"issued_by":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Issued By"},"is_current":{"type":"boolean","title":"Is Current"},"policy_group_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Policy Group Id"},"change_notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Change Notes"},"generated_by_ai":{"type":"boolean","title":"Generated By Ai"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"}},"type":"object","required":["id","title","policy_type","content","version","issued_date","review_date","issued_by","is_current","policy_group_id","change_notes","generated_by_ai","created_at","updated_at"],"title":"HSPolicyResponse"},"HSPolicyReviseRequest":{"properties":{"content":{"type":"string","minLength":1,"title":"Content"},"change_notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Change Notes"},"title":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Title"},"policy_type":{"anyOf":[{"$ref":"#/components/schemas/HSPolicyType"},{"type":"null"}]},"version":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Version"},"issued_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Issued Date"},"review_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Review Date"},"issued_by":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Issued By"}},"type":"object","required":["content"],"title":"HSPolicyReviseRequest","description":"Creates a new version of an existing policy, archiving the old one."},"HSPolicyType":{"type":"string","enum":["health_safety","environmental","equality","quality","other"],"title":"HSPolicyType"},"HSPolicyUpdate":{"properties":{"title":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Title"},"policy_type":{"anyOf":[{"$ref":"#/components/schemas/HSPolicyType"},{"type":"null"}]},"content":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Content"},"version":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Version"},"issued_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Issued Date"},"review_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Review Date"},"issued_by":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Issued By"},"is_current":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Current"}},"type":"object","title":"HSPolicyUpdate"},"HTTPValidationError":{"properties":{"detail":{"items":{"$ref":"#/components/schemas/ValidationError"},"type":"array","title":"Detail"}},"type":"object","title":"HTTPValidationError"},"HandoverItemIn":{"properties":{"category":{"type":"string","title":"Category"},"title":{"type":"string","title":"Title"},"document_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Document Id"},"file_path":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"File Path"},"sort_order":{"type":"integer","title":"Sort Order","default":0},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"}},"type":"object","required":["category","title"],"title":"HandoverItemIn"},"HandoverPackIn":{"properties":{"job_id":{"type":"string","format":"uuid","title":"Job Id"},"title":{"type":"string","title":"Title"},"recipient_email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Recipient Email"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"items":{"items":{"$ref":"#/components/schemas/HandoverItemIn"},"type":"array","title":"Items","default":[]}},"type":"object","required":["job_id","title"],"title":"HandoverPackIn"},"HandoverPackPatch":{"properties":{"title":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Title"},"recipient_email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Recipient Email"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"}},"type":"object","title":"HandoverPackPatch"},"HandoverSendIn":{"properties":{"recipient_email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Recipient Email"}},"type":"object","title":"HandoverSendIn"},"HasDemoResponse":{"properties":{"has_demo":{"type":"boolean","title":"Has Demo"}},"type":"object","required":["has_demo"],"title":"HasDemoResponse"},"HealthResponse":{"properties":{"status":{"type":"string","title":"Status"},"version":{"type":"string","title":"Version"},"environment":{"type":"string","title":"Environment"}},"type":"object","required":["status","version","environment"],"title":"HealthResponse"},"HelpArticleCreate":{"properties":{"title":{"type":"string","maxLength":500,"minLength":1,"title":"Title"},"slug":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Slug"},"summary":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Summary"},"content":{"type":"string","title":"Content","default":""},"category_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Category Id"},"sort_order":{"type":"integer","title":"Sort Order","default":0},"is_published":{"type":"boolean","title":"Is Published","default":false}},"type":"object","required":["title"],"title":"HelpArticleCreate"},"HelpArticleDetailResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"title":{"type":"string","title":"Title"},"slug":{"type":"string","title":"Slug"},"summary":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Summary"},"content":{"type":"string","title":"Content"},"category_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Category Id"},"category_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Category Name"},"sort_order":{"type":"integer","title":"Sort Order"},"is_published":{"type":"boolean","title":"Is Published"},"source":{"type":"string","title":"Source"},"source_ref":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source Ref"},"screenshots":{"items":{},"type":"array","title":"Screenshots"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"}},"type":"object","required":["id","title","slug","summary","content","category_id","sort_order","is_published","source","source_ref","screenshots","created_at","updated_at"],"title":"HelpArticleDetailResponse"},"HelpArticleSummaryResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"title":{"type":"string","title":"Title"},"slug":{"type":"string","title":"Slug"},"summary":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Summary"},"category_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Category Id"},"category_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Category Name"},"sort_order":{"type":"integer","title":"Sort Order"},"is_published":{"type":"boolean","title":"Is Published"},"source":{"type":"string","title":"Source"},"screenshot_count":{"type":"integer","title":"Screenshot Count","default":0},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"}},"type":"object","required":["id","title","slug","summary","category_id","sort_order","is_published","source","created_at","updated_at"],"title":"HelpArticleSummaryResponse"},"HelpArticleUpdate":{"properties":{"title":{"anyOf":[{"type":"string","maxLength":500,"minLength":1},{"type":"null"}],"title":"Title"},"slug":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Slug"},"summary":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Summary"},"content":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Content"},"category_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Category Id"},"sort_order":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Sort Order"},"is_published":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Published"}},"type":"object","title":"HelpArticleUpdate"},"HelpCategoryCreate":{"properties":{"name":{"type":"string","maxLength":100,"minLength":1,"title":"Name"},"slug":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Slug"},"icon":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Icon"},"sort_order":{"type":"integer","title":"Sort Order","default":0}},"type":"object","required":["name"],"title":"HelpCategoryCreate"},"HelpCategoryResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"name":{"type":"string","title":"Name"},"slug":{"type":"string","title":"Slug"},"icon":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Icon"},"sort_order":{"type":"integer","title":"Sort Order"},"article_count":{"type":"integer","title":"Article Count","default":0},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"}},"type":"object","required":["id","name","slug","icon","sort_order","created_at","updated_at"],"title":"HelpCategoryResponse"},"HelpCategoryUpdate":{"properties":{"name":{"anyOf":[{"type":"string","maxLength":100,"minLength":1},{"type":"null"}],"title":"Name"},"slug":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Slug"},"icon":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Icon"},"sort_order":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Sort Order"}},"type":"object","title":"HelpCategoryUpdate"},"HelpChatRequest":{"properties":{"message":{"type":"string","maxLength":2000,"minLength":1,"title":"Message"},"conversation_history":{"items":{"$ref":"#/components/schemas/ConversationMessage"},"type":"array","title":"Conversation History"}},"type":"object","required":["message"],"title":"HelpChatRequest"},"HelpChatResponse":{"properties":{"answer":{"type":"string","title":"Answer"},"related_articles":{"items":{"$ref":"#/components/schemas/RelatedArticle"},"type":"array","title":"Related Articles"}},"type":"object","required":["answer"],"title":"HelpChatResponse"},"HelpSyncItem":{"properties":{"title":{"type":"string","maxLength":500,"minLength":1,"title":"Title"},"slug":{"type":"string","title":"Slug"},"summary":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Summary"},"content_html":{"type":"string","title":"Content Html","default":""},"source":{"type":"string","title":"Source","default":"changelog"},"source_ref":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source Ref"},"category_slug":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Category Slug"},"category_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Category Name"}},"type":"object","required":["title","slug"],"title":"HelpSyncItem"},"HelpSyncResponse":{"properties":{"created":{"type":"integer","title":"Created"},"updated":{"type":"integer","title":"Updated"},"skipped":{"type":"integer","title":"Skipped"}},"type":"object","required":["created","updated","skipped"],"title":"HelpSyncResponse"},"IPWhitelistCreate":{"properties":{"ip_address":{"type":"string","maxLength":50,"title":"Ip Address","description":"IPv4 or IPv6 address"},"description":{"anyOf":[{"type":"string","maxLength":500},{"type":"null"}],"title":"Description"}},"type":"object","required":["ip_address"],"title":"IPWhitelistCreate"},"IPWhitelistResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"ip_address":{"type":"string","title":"Ip Address"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"created_by":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Created By"},"created_at":{"type":"string","format":"date-time","title":"Created At"}},"type":"object","required":["id","ip_address","created_at"],"title":"IPWhitelistResponse"},"ImportResult":{"properties":{"dry_run":{"type":"boolean","title":"Dry Run"},"total_rows":{"type":"integer","title":"Total Rows"},"created":{"type":"integer","title":"Created"},"updated":{"type":"integer","title":"Updated"},"skipped":{"type":"integer","title":"Skipped"},"errors":{"items":{"$ref":"#/components/schemas/RowError"},"type":"array","title":"Errors"},"preview":{"items":{"type":"object"},"type":"array","title":"Preview"}},"type":"object","required":["dry_run","total_rows","created","updated","skipped","errors","preview"],"title":"ImportResult"},"IncidentSeverity":{"type":"string","enum":["first_aid","lost_time","reportable","fatal"],"title":"IncidentSeverity"},"IncidentType":{"type":"string","enum":["accident","near_miss","dangerous_occurrence"],"title":"IncidentType"},"InductionCreate":{"properties":{"person_name":{"type":"string","maxLength":255,"minLength":1,"title":"Person Name"},"job_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Job Id"},"worker_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Worker Id"},"person_company":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Person Company"},"person_role":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Person Role"},"induction_date":{"type":"string","format":"date","title":"Induction Date"},"valid_until":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Valid Until"},"delivered_by":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Delivered By"},"topics_covered":{"items":{"type":"string"},"type":"array","title":"Topics Covered","default":[]},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"signature":{"anyOf":[{"type":"object"},{"type":"null"}],"title":"Signature"}},"type":"object","required":["person_name","induction_date"],"title":"InductionCreate"},"InductionResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"company_id":{"type":"string","format":"uuid","title":"Company Id"},"job_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Job Id"},"worker_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Worker Id"},"person_name":{"type":"string","title":"Person Name"},"person_company":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Person Company"},"person_role":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Person Role"},"induction_date":{"type":"string","format":"date","title":"Induction Date"},"valid_until":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Valid Until"},"delivered_by":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Delivered By"},"topics_covered":{"items":{},"type":"array","title":"Topics Covered"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"is_active":{"type":"boolean","title":"Is Active"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"}},"type":"object","required":["id","company_id","job_id","worker_id","person_name","person_company","person_role","induction_date","valid_until","delivered_by","topics_covered","notes","is_active","created_at","updated_at"],"title":"InductionResponse"},"InductionUpdate":{"properties":{"person_name":{"anyOf":[{"type":"string","maxLength":255,"minLength":1},{"type":"null"}],"title":"Person Name"},"person_company":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Person Company"},"person_role":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Person Role"},"induction_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Induction Date"},"valid_until":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Valid Until"},"delivered_by":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Delivered By"},"topics_covered":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Topics Covered"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"is_active":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Active"}},"type":"object","title":"InductionUpdate"},"InstallmentInput":{"properties":{"amount":{"type":"number","exclusiveMinimum":0.0,"title":"Amount"},"due_date":{"type":"string","format":"date","title":"Due Date"}},"type":"object","required":["amount","due_date"],"title":"InstallmentInput"},"InstallmentResponse":{"properties":{"amount":{"type":"number","title":"Amount"},"due_date":{"type":"string","title":"Due Date"},"status":{"type":"string","title":"Status"},"paid_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Paid At"}},"type":"object","required":["amount","due_date","status","paid_at"],"title":"InstallmentResponse"},"InstantPriceRequest":{"properties":{"trade":{"type":"string","title":"Trade"},"description":{"type":"string","title":"Description"},"location":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Location"},"dimensions":{"anyOf":[{"$ref":"#/components/schemas/Dimensions"},{"type":"null"}]}},"type":"object","required":["trade","description"],"title":"InstantPriceRequest"},"InstantPriceResponse":{"properties":{"estimated_range":{"$ref":"#/components/schemas/PriceRange"},"confidence":{"type":"string","title":"Confidence"},"factors":{"items":{"type":"string"},"type":"array","title":"Factors"},"disclaimer":{"type":"string","title":"Disclaimer"}},"type":"object","required":["estimated_range","confidence","factors","disclaimer"],"title":"InstantPriceResponse"},"InsurancePolicyIn":{"properties":{"entity_type":{"type":"string","title":"Entity Type","default":"company"},"entity_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Entity Id"},"policy_type":{"type":"string","title":"Policy Type"},"provider":{"type":"string","title":"Provider"},"policy_number":{"type":"string","title":"Policy Number"},"cover_amount_pence":{"type":"integer","title":"Cover Amount Pence"},"excess_pence":{"type":"integer","title":"Excess Pence","default":0},"start_date":{"type":"string","title":"Start Date"},"expiry_date":{"type":"string","title":"Expiry Date"},"renewal_date":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Renewal Date"},"document_path":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Document Path"},"is_verified":{"type":"boolean","title":"Is Verified","default":false},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"}},"type":"object","required":["policy_type","provider","policy_number","cover_amount_pence","start_date","expiry_date"],"title":"InsurancePolicyIn"},"InsurancePolicyPatch":{"properties":{"policy_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Policy Type"},"provider":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Provider"},"policy_number":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Policy Number"},"cover_amount_pence":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Cover Amount Pence"},"excess_pence":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Excess Pence"},"start_date":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Start Date"},"expiry_date":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Expiry Date"},"renewal_date":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Renewal Date"},"document_path":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Document Path"},"is_verified":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Verified"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"}},"type":"object","title":"InsurancePolicyPatch"},"InvitationLineItemCreate":{"properties":{"rfq_line_item_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Rfq Line Item Id"},"description":{"type":"string","minLength":1,"title":"Description"},"unit_price":{"type":"number","title":"Unit Price","default":0.0},"total":{"type":"number","title":"Total","default":0.0},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"sort_order":{"type":"integer","title":"Sort Order","default":0}},"type":"object","required":["description"],"title":"InvitationLineItemCreate"},"InvitationLineItemResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"rfq_line_item_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Rfq Line Item Id"},"description":{"type":"string","title":"Description"},"unit_price":{"type":"number","title":"Unit Price"},"total":{"type":"number","title":"Total"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"sort_order":{"type":"integer","title":"Sort Order"}},"type":"object","required":["id","rfq_line_item_id","description","unit_price","total","notes","sort_order"],"title":"InvitationLineItemResponse"},"InvitationRespondBody":{"properties":{"total_price":{"type":"number","title":"Total Price"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"line_items":{"items":{"$ref":"#/components/schemas/InvitationLineItemCreate"},"type":"array","title":"Line Items","default":[]}},"type":"object","required":["total_price"],"title":"InvitationRespondBody"},"InvitationStatus":{"type":"string","enum":["invited","sent","responded","accepted","declined"],"title":"InvitationStatus"},"InviteMember":{"properties":{"name":{"type":"string","maxLength":255,"minLength":1,"title":"Name"},"email":{"type":"string","format":"email","title":"Email"},"role":{"type":"string","title":"Role","default":"MEMBER"}},"type":"object","required":["name","email"],"title":"InviteMember"},"InviteMemberRequest":{"properties":{"email":{"type":"string","maxLength":255,"title":"Email"},"role":{"$ref":"#/components/schemas/CompanyUserRole","default":"MEMBER"}},"type":"object","required":["email"],"title":"InviteMemberRequest"},"InviteTeamRequest":{"properties":{"members":{"items":{"$ref":"#/components/schemas/InviteMember"},"type":"array","maxItems":50,"minItems":1,"title":"Members"}},"type":"object","required":["members"],"title":"InviteTeamRequest"},"InviteTeamResponse":{"properties":{"invited":{"type":"integer","title":"Invited"},"errors":{"items":{"type":"string"},"type":"array","title":"Errors"}},"type":"object","required":["invited","errors"],"title":"InviteTeamResponse"},"InvoiceCreateRequest":{"properties":{"client_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Client Id"},"job_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Job Id"},"invoice_number":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Invoice Number","description":"Generated from the company prefix if omitted."},"issue_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Issue Date"},"due_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Due Date","description":"Defaults to the client's agreed payment terms."},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"line_items":{"items":{"$ref":"#/components/schemas/InvoiceLineItemIn"},"type":"array","minItems":1,"title":"Line Items"}},"type":"object","required":["line_items"],"title":"InvoiceCreateRequest","description":"Raise an invoice directly, without a job behind it.\n\nInvoices could only be spawned by job completion, AFP certification, retention release\nor the recurring cron — there was no way to bill for anything else."},"InvoiceFrequency":{"type":"string","enum":["weekly","monthly","quarterly","annually"],"title":"InvoiceFrequency"},"InvoiceLineItemIn":{"properties":{"description":{"type":"string","minLength":1,"title":"Description"},"quantity":{"type":"number","exclusiveMinimum":0.0,"title":"Quantity","default":1.0},"unit":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Unit"},"unit_price":{"type":"number","minimum":0.0,"title":"Unit Price","default":0.0},"vat_rate":{"type":"number","maximum":100.0,"minimum":0.0,"title":"Vat Rate","default":20.0},"category":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Category"}},"type":"object","required":["description"],"title":"InvoiceLineItemIn"},"InvoiceLineItemResponse":{"properties":{"description":{"type":"string","minLength":1,"title":"Description"},"quantity":{"type":"number","exclusiveMinimum":0.0,"title":"Quantity","default":1.0},"unit":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Unit"},"unit_price":{"type":"number","minimum":0.0,"title":"Unit Price","default":0.0},"vat_rate":{"type":"number","maximum":100.0,"minimum":0.0,"title":"Vat Rate","default":20.0},"category":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Category"},"id":{"type":"string","format":"uuid","title":"Id"},"total":{"type":"number","title":"Total"},"sort_order":{"type":"integer","title":"Sort Order"}},"type":"object","required":["description","id","total","sort_order"],"title":"InvoiceLineItemResponse"},"InvoiceResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"company_id":{"type":"string","format":"uuid","title":"Company Id"},"job_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Job Id"},"client_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Client Id"},"invoice_number":{"type":"string","title":"Invoice Number"},"status":{"type":"string","title":"Status"},"subtotal":{"type":"number","title":"Subtotal","default":0.0},"vat_rate":{"type":"number","title":"Vat Rate","default":20.0},"vat_amount":{"type":"number","title":"Vat Amount","default":0.0},"reverse_charge":{"type":"boolean","title":"Reverse Charge","default":false},"amount_total":{"type":"number","title":"Amount Total"},"amount_paid":{"type":"number","title":"Amount Paid"},"amount_due":{"type":"number","title":"Amount Due"},"currency":{"type":"string","title":"Currency"},"issue_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Issue Date"},"due_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Due Date"},"paid_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Paid At"},"last_synced_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Synced At"},"provider":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Provider"},"xero_invoice_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Xero Invoice Id"},"quickbooks_invoice_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Quickbooks Invoice Id"},"freshbooks_invoice_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Freshbooks Invoice Id"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"interest_rate":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Interest Rate"},"interest_accrued":{"type":"number","title":"Interest Accrued"},"reminder_count":{"type":"integer","title":"Reminder Count"},"last_reminder_sent_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Reminder Sent At"},"line_items":{"items":{"$ref":"#/components/schemas/InvoiceLineItemResponse"},"type":"array","title":"Line Items","default":[]},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"}},"type":"object","required":["id","company_id","job_id","client_id","invoice_number","status","amount_total","amount_paid","amount_due","currency","issue_date","due_date","paid_at","last_synced_at","provider","xero_invoice_id","quickbooks_invoice_id","freshbooks_invoice_id","notes","interest_rate","interest_accrued","reminder_count","last_reminder_sent_at","created_at","updated_at"],"title":"InvoiceResponse"},"InvoiceTemplateCreate":{"properties":{"name":{"type":"string","title":"Name"},"logo_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Logo Url"},"header_text":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Header Text"},"footer_text":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Footer Text"},"payment_terms_text":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Payment Terms Text"},"accent_color":{"type":"string","title":"Accent Color","default":"#4F46E5"},"font_family":{"type":"string","title":"Font Family","default":"Inter"},"show_bank_details":{"type":"boolean","title":"Show Bank Details","default":false},"bank_details_text":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Bank Details Text"},"is_default":{"type":"boolean","title":"Is Default","default":false}},"type":"object","required":["name"],"title":"InvoiceTemplateCreate"},"InvoiceTemplateResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"company_id":{"type":"string","format":"uuid","title":"Company Id"},"name":{"type":"string","title":"Name"},"logo_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Logo Url"},"header_text":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Header Text"},"footer_text":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Footer Text"},"payment_terms_text":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Payment Terms Text"},"accent_color":{"type":"string","title":"Accent Color"},"font_family":{"type":"string","title":"Font Family"},"show_bank_details":{"type":"boolean","title":"Show Bank Details"},"bank_details_text":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Bank Details Text"},"is_default":{"type":"boolean","title":"Is Default"},"created_at":{"type":"string","title":"Created At"},"updated_at":{"type":"string","title":"Updated At"}},"type":"object","required":["id","company_id","name","accent_color","font_family","show_bank_details","is_default","created_at","updated_at"],"title":"InvoiceTemplateResponse"},"InvoiceTemplateUpdate":{"properties":{"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name"},"logo_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Logo Url"},"header_text":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Header Text"},"footer_text":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Footer Text"},"payment_terms_text":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Payment Terms Text"},"accent_color":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Accent Color"},"font_family":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Font Family"},"show_bank_details":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Show Bank Details"},"bank_details_text":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Bank Details Text"},"is_default":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Default"}},"type":"object","title":"InvoiceTemplateUpdate"},"IssueCreditRequest":{"properties":{"company_id":{"type":"string","format":"uuid","title":"Company Id"},"amount":{"anyOf":[{"type":"number","maximum":100000.0,"exclusiveMinimum":0.0},{"type":"string"}],"title":"Amount","description":"Positive amount in GBP"},"reason":{"$ref":"#/components/schemas/CreditReason","default":"goodwill"},"note":{"anyOf":[{"type":"string","maxLength":2000},{"type":"null"}],"title":"Note"},"internal_note":{"anyOf":[{"type":"string","maxLength":2000},{"type":"null"}],"title":"Internal Note"},"expires_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Expires At"}},"type":"object","required":["company_id","amount"],"title":"IssueCreditRequest"},"JobBudgetCreate":{"properties":{"name":{"type":"string","title":"Name","default":"Original budget"},"source":{"type":"string","title":"Source","default":"estimate"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"lines":{"items":{"$ref":"#/components/schemas/JobBudgetLineIn"},"type":"array","title":"Lines","default":[]}},"type":"object","title":"JobBudgetCreate"},"JobBudgetLineIn":{"properties":{"cost_code_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Cost Code Id"},"category":{"$ref":"#/components/schemas/CostCategory","default":"other"},"description":{"type":"string","title":"Description","default":""},"budget_amount":{"type":"number","title":"Budget Amount","default":0.0}},"type":"object","title":"JobBudgetLineIn"},"JobBudgetLineResponse":{"properties":{"cost_code_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Cost Code Id"},"category":{"$ref":"#/components/schemas/CostCategory","default":"other"},"description":{"type":"string","title":"Description","default":""},"budget_amount":{"type":"number","title":"Budget Amount","default":0.0},"id":{"type":"string","format":"uuid","title":"Id"}},"type":"object","required":["id"],"title":"JobBudgetLineResponse"},"JobBudgetResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"job_id":{"type":"string","format":"uuid","title":"Job Id"},"version":{"type":"integer","title":"Version"},"name":{"type":"string","title":"Name"},"status":{"$ref":"#/components/schemas/BudgetStatus"},"source":{"type":"string","title":"Source"},"total_budget":{"type":"number","title":"Total Budget"},"baselined_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Baselined At"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"lines":{"items":{"$ref":"#/components/schemas/JobBudgetLineResponse"},"type":"array","title":"Lines","default":[]},"created_at":{"type":"string","format":"date-time","title":"Created At"}},"type":"object","required":["id","job_id","version","name","status","source","total_budget","baselined_at","notes","created_at"],"title":"JobBudgetResponse"},"JobCostEntryCreate":{"properties":{"category":{"$ref":"#/components/schemas/CostCategory","default":"other"},"cost_code_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Cost Code Id"},"description":{"type":"string","maxLength":500,"minLength":1,"title":"Description"},"amount":{"type":"number","title":"Amount"},"entry_date":{"type":"string","format":"date","title":"Entry Date"},"reference":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Reference"},"po_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Po Id"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"}},"type":"object","required":["description","amount","entry_date"],"title":"JobCostEntryCreate"},"JobCostEntryResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"job_id":{"type":"string","format":"uuid","title":"Job Id"},"category":{"$ref":"#/components/schemas/CostCategory"},"cost_code_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Cost Code Id"},"description":{"type":"string","title":"Description"},"amount":{"type":"number","title":"Amount"},"entry_date":{"type":"string","format":"date","title":"Entry Date"},"reference":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Reference"},"po_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Po Id"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"}},"type":"object","required":["id","job_id","category","description","amount","entry_date","reference","po_id","notes","created_at","updated_at"],"title":"JobCostEntryResponse"},"JobCostEntryUpdate":{"properties":{"category":{"anyOf":[{"$ref":"#/components/schemas/CostCategory"},{"type":"null"}]},"cost_code_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Cost Code Id"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"amount":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Amount"},"entry_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Entry Date"},"reference":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Reference"},"po_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Po Id"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"}},"type":"object","title":"JobCostEntryUpdate"},"JobCostForecastCreate":{"properties":{"period_end":{"type":"string","format":"date","title":"Period End"},"cost_to_complete":{"type":"number","title":"Cost To Complete","default":0.0},"cost_code_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Cost Code Id"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"}},"type":"object","required":["period_end"],"title":"JobCostForecastCreate"},"JobCostForecastResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"job_id":{"type":"string","format":"uuid","title":"Job Id"},"cost_code_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Cost Code Id"},"period_end":{"type":"string","format":"date","title":"Period End"},"cost_to_complete":{"type":"number","title":"Cost To Complete"},"forecast_final_cost":{"type":"number","title":"Forecast Final Cost"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"created_at":{"type":"string","format":"date-time","title":"Created At"}},"type":"object","required":["id","job_id","cost_code_id","period_end","cost_to_complete","forecast_final_cost","notes","created_at"],"title":"JobCostForecastResponse"},"JobCostPositionResponse":{"properties":{"job_id":{"type":"string","format":"uuid","title":"Job Id"},"actual_labour":{"type":"number","title":"Actual Labour"},"actual_received_orders":{"type":"number","title":"Actual Received Orders"},"actual_ledger":{"type":"number","title":"Actual Ledger"},"actual_cost":{"type":"number","title":"Actual Cost"},"committed_cost":{"type":"number","title":"Committed Cost"},"total_exposure":{"type":"number","title":"Total Exposure"},"budget":{"type":"number","title":"Budget"},"budget_source":{"type":"string","title":"Budget Source"},"budget_version":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Budget Version"},"cost_to_complete":{"type":"number","title":"Cost To Complete"},"forecast_final_cost":{"type":"number","title":"Forecast Final Cost"},"forecast_source":{"type":"string","title":"Forecast Source"},"forecast_period_end":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Forecast Period End"},"variance_to_budget":{"type":"number","title":"Variance To Budget"},"by_category":{"additionalProperties":{"type":"number"},"type":"object","title":"By Category","default":{}}},"type":"object","required":["job_id","actual_labour","actual_received_orders","actual_ledger","actual_cost","committed_cost","total_exposure","budget","budget_source","cost_to_complete","forecast_final_cost","forecast_source","variance_to_budget"],"title":"JobCostPositionResponse"},"JobCostingSummary":{"properties":{"job_id":{"type":"string","format":"uuid","title":"Job Id"},"job_number":{"type":"string","title":"Job Number"},"title":{"type":"string","title":"Title"},"contract_value":{"type":"number","title":"Contract Value"},"approved_variations":{"type":"number","title":"Approved Variations"},"revised_contract_value":{"type":"number","title":"Revised Contract Value"},"estimated_cost":{"$ref":"#/components/schemas/CostBreakdown"},"budget":{"type":"number","title":"Budget"},"budget_source":{"type":"string","title":"Budget Source"},"budget_version":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Budget Version"},"committed_cost":{"type":"number","title":"Committed Cost"},"actual_labour":{"type":"number","title":"Actual Labour"},"actual_received_orders":{"type":"number","title":"Actual Received Orders"},"actual_ledger":{"type":"number","title":"Actual Ledger"},"actual_cost":{"type":"number","title":"Actual Cost"},"total_exposure":{"type":"number","title":"Total Exposure"},"actual_by_category":{"additionalProperties":{"type":"number"},"type":"object","title":"Actual By Category","default":{}},"cost_to_complete":{"type":"number","title":"Cost To Complete"},"forecast_final_cost":{"type":"number","title":"Forecast Final Cost"},"forecast_source":{"type":"string","title":"Forecast Source"},"variance_to_budget":{"type":"number","title":"Variance To Budget"},"gross_profit_estimated":{"type":"number","title":"Gross Profit Estimated"},"gross_margin_estimated":{"type":"number","title":"Gross Margin Estimated"},"gross_profit_actual":{"type":"number","title":"Gross Profit Actual"},"gross_margin_actual":{"type":"number","title":"Gross Margin Actual"},"gross_profit_forecast":{"type":"number","title":"Gross Profit Forecast"},"gross_margin_forecast":{"type":"number","title":"Gross Margin Forecast"}},"type":"object","required":["job_id","job_number","title","contract_value","approved_variations","revised_contract_value","estimated_cost","budget","budget_source","committed_cost","actual_labour","actual_received_orders","actual_ledger","actual_cost","total_exposure","cost_to_complete","forecast_final_cost","forecast_source","variance_to_budget","gross_profit_estimated","gross_margin_estimated","gross_profit_actual","gross_margin_actual","gross_profit_forecast","gross_margin_forecast"],"title":"JobCostingSummary","description":"Job cost summary. Every cost figure comes from `app.services.cost_service`."},"JobCreateRequest":{"properties":{"title":{"type":"string","maxLength":500,"minLength":1,"title":"Title"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"client_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Client Id"},"quote_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Quote Id"},"client_site_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Client Site Id"},"site_address":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Site Address"},"start_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Start Date"},"end_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"End Date"},"contract_value":{"type":"number","title":"Contract Value","default":0.0},"retention_percentage":{"anyOf":[{"type":"number","maximum":100.0,"minimum":0.0},{"type":"null"}],"title":"Retention Percentage"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"line_items":{"items":{"$ref":"#/components/schemas/JobLineItemCreate"},"type":"array","title":"Line Items","default":[]},"is_recurring":{"type":"boolean","title":"Is Recurring","default":false},"recurrence_frequency":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Recurrence Frequency"},"currency":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Currency"},"qr_attendance_enabled":{"type":"boolean","title":"Qr Attendance Enabled","default":false},"site_postcode":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Site Postcode"},"site_lat":{"anyOf":[{"type":"number","maximum":90.0,"minimum":-90.0},{"type":"null"}],"title":"Site Lat"},"site_lon":{"anyOf":[{"type":"number","maximum":180.0,"minimum":-180.0},{"type":"null"}],"title":"Site Lon"},"qr_radius_metres":{"anyOf":[{"type":"integer","maximum":5000.0,"minimum":10.0},{"type":"null"}],"title":"Qr Radius Metres"},"shift_start_time":{"anyOf":[{"type":"string","format":"time"},{"type":"null"}],"title":"Shift Start Time"},"shift_end_time":{"anyOf":[{"type":"string","format":"time"},{"type":"null"}],"title":"Shift End Time"},"site_manager_email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Site Manager Email"}},"type":"object","required":["title"],"title":"JobCreateRequest"},"JobLineItemCreate":{"properties":{"description":{"type":"string","minLength":1,"title":"Description"},"quantity":{"type":"number","minimum":0.0,"title":"Quantity","default":1.0},"unit":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Unit"},"unit_price":{"type":"number","minimum":0.0,"title":"Unit Price","default":0.0},"actual_cost":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Actual Cost"},"category":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Category"},"sort_order":{"type":"integer","title":"Sort Order","default":0}},"type":"object","required":["description"],"title":"JobLineItemCreate"},"JobLineItemResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"description":{"type":"string","title":"Description"},"quantity":{"type":"number","title":"Quantity"},"unit":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Unit"},"unit_price":{"type":"number","title":"Unit Price"},"actual_cost":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Actual Cost"},"total":{"type":"number","title":"Total"},"category":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Category"},"sort_order":{"type":"integer","title":"Sort Order"}},"type":"object","required":["id","description","quantity","unit","unit_price","actual_cost","total","category","sort_order"],"title":"JobLineItemResponse"},"JobMapItem":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"job_number":{"type":"string","title":"Job Number"},"title":{"type":"string","title":"Title"},"status":{"$ref":"#/components/schemas/JobStatus"},"contract_value":{"type":"number","title":"Contract Value"},"site_address":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Site Address"},"site_postcode":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Site Postcode"},"lat":{"type":"number","title":"Lat"},"lon":{"type":"number","title":"Lon"},"client_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Client Name"},"start_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Start Date"},"end_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"End Date"}},"type":"object","required":["id","job_number","title","status","contract_value","lat","lon"],"title":"JobMapItem","description":"A job pin for the live project map."},"JobMapResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/JobMapItem"},"type":"array","title":"Items"},"without_location":{"type":"integer","title":"Without Location"}},"type":"object","required":["items","without_location"],"title":"JobMapResponse"},"JobQRCodeResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"job_id":{"type":"string","format":"uuid","title":"Job Id"},"token":{"type":"string","title":"Token"},"qr_png_url":{"type":"string","title":"Qr Png Url"},"scan_url":{"type":"string","title":"Scan Url"},"is_active":{"type":"boolean","title":"Is Active"},"created_at":{"type":"string","format":"date-time","title":"Created At"}},"type":"object","required":["id","job_id","token","qr_png_url","scan_url","is_active","created_at"],"title":"JobQRCodeResponse"},"JobResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"company_id":{"type":"string","format":"uuid","title":"Company Id"},"quote_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Quote Id"},"client_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Client Id"},"client_site_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Client Site Id"},"job_number":{"type":"string","title":"Job Number"},"title":{"type":"string","title":"Title"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"status":{"$ref":"#/components/schemas/JobStatus"},"site_address":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Site Address"},"start_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Start Date"},"end_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"End Date"},"completed_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Completed At"},"invoiced_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Invoiced At"},"contract_value":{"type":"number","title":"Contract Value"},"retention_percentage":{"type":"number","title":"Retention Percentage"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"custom_fields":{"type":"object","title":"Custom Fields"},"currency":{"type":"string","title":"Currency"},"is_recurring":{"type":"boolean","title":"Is Recurring"},"recurrence_frequency":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Recurrence Frequency"},"recurrence_template_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Recurrence Template Id"},"next_recurrence_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Next Recurrence Date"},"line_items":{"items":{"$ref":"#/components/schemas/JobLineItemResponse"},"type":"array","title":"Line Items"},"milestones":{"items":{"$ref":"#/components/schemas/MilestoneResponse"},"type":"array","title":"Milestones","default":[]},"qr_attendance_enabled":{"type":"boolean","title":"Qr Attendance Enabled"},"site_postcode":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Site Postcode"},"site_lat":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Site Lat"},"site_lon":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Site Lon"},"qr_radius_metres":{"type":"integer","title":"Qr Radius Metres"},"shift_start_time":{"anyOf":[{"type":"string","format":"time"},{"type":"null"}],"title":"Shift Start Time"},"shift_end_time":{"anyOf":[{"type":"string","format":"time"},{"type":"null"}],"title":"Shift End Time"},"site_manager_email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Site Manager Email"},"gate_induction":{"$ref":"#/components/schemas/SiteGateMode"},"gate_cscs":{"$ref":"#/components/schemas/SiteGateMode"},"gate_rams":{"$ref":"#/components/schemas/SiteGateMode"},"active_rams_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Active Rams Id"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"}},"type":"object","required":["id","company_id","quote_id","client_id","client_site_id","job_number","title","description","status","site_address","start_date","end_date","completed_at","invoiced_at","contract_value","retention_percentage","notes","custom_fields","currency","is_recurring","recurrence_frequency","recurrence_template_id","next_recurrence_date","line_items","qr_attendance_enabled","site_postcode","site_lat","site_lon","qr_radius_metres","shift_start_time","shift_end_time","site_manager_email","gate_induction","gate_cscs","gate_rams","active_rams_id","created_at","updated_at"],"title":"JobResponse"},"JobStatus":{"type":"string","enum":["pending","active","on_hold","complete","invoiced","cancelled"],"title":"JobStatus"},"JobStatusUpdate":{"properties":{"status":{"$ref":"#/components/schemas/JobStatus"}},"type":"object","required":["status"],"title":"JobStatusUpdate"},"JobTemplateCreate":{"properties":{"name":{"type":"string","maxLength":100,"minLength":1,"title":"Name"},"title":{"type":"string","maxLength":500,"title":"Title","default":""},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"contract_value":{"type":"number","minimum":0.0,"title":"Contract Value","default":0.0},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"site_address":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Site Address"},"custom_fields":{"type":"object","title":"Custom Fields"},"line_items":{"items":{"$ref":"#/components/schemas/JobTemplateLineItemIn"},"type":"array","title":"Line Items"}},"type":"object","required":["name"],"title":"JobTemplateCreate"},"JobTemplateLineItemIn":{"properties":{"description":{"type":"string","minLength":1,"title":"Description"},"quantity":{"type":"number","minimum":0.0,"title":"Quantity","default":1.0},"unit":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Unit"},"unit_price":{"type":"number","minimum":0.0,"title":"Unit Price","default":0.0},"category":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Category"},"sort_order":{"type":"integer","title":"Sort Order","default":0}},"type":"object","required":["description"],"title":"JobTemplateLineItemIn"},"JobTemplateLineItemOut":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"description":{"type":"string","title":"Description"},"quantity":{"type":"number","title":"Quantity"},"unit":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Unit"},"unit_price":{"type":"number","title":"Unit Price"},"category":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Category"},"sort_order":{"type":"integer","title":"Sort Order"}},"type":"object","required":["id","description","quantity","unit","unit_price","category","sort_order"],"title":"JobTemplateLineItemOut"},"JobTemplateResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"company_id":{"type":"string","format":"uuid","title":"Company Id"},"name":{"type":"string","title":"Name"},"title":{"type":"string","title":"Title"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"contract_value":{"type":"number","title":"Contract Value"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"site_address":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Site Address"},"custom_fields":{"type":"object","title":"Custom Fields"},"is_active":{"type":"boolean","title":"Is Active"},"line_items":{"items":{"$ref":"#/components/schemas/JobTemplateLineItemOut"},"type":"array","title":"Line Items"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"}},"type":"object","required":["id","company_id","name","title","description","contract_value","notes","site_address","custom_fields","is_active","line_items","created_at","updated_at"],"title":"JobTemplateResponse"},"JobTemplateUpdate":{"properties":{"name":{"anyOf":[{"type":"string","maxLength":100,"minLength":1},{"type":"null"}],"title":"Name"},"title":{"anyOf":[{"type":"string","maxLength":500},{"type":"null"}],"title":"Title"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"contract_value":{"anyOf":[{"type":"number","minimum":0.0},{"type":"null"}],"title":"Contract Value"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"site_address":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Site Address"},"custom_fields":{"anyOf":[{"type":"object"},{"type":"null"}],"title":"Custom Fields"},"is_active":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Active"},"line_items":{"anyOf":[{"items":{"$ref":"#/components/schemas/JobTemplateLineItemIn"},"type":"array"},{"type":"null"}],"title":"Line Items"}},"type":"object","title":"JobTemplateUpdate"},"JobUpdateRequest":{"properties":{"title":{"anyOf":[{"type":"string","maxLength":500,"minLength":1},{"type":"null"}],"title":"Title"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"client_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Client Id"},"quote_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Quote Id"},"client_site_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Client Site Id"},"custom_fields":{"anyOf":[{"type":"object"},{"type":"null"}],"title":"Custom Fields"},"site_address":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Site Address"},"start_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Start Date"},"end_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"End Date"},"contract_value":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Contract Value"},"retention_percentage":{"anyOf":[{"type":"number","maximum":100.0,"minimum":0.0},{"type":"null"}],"title":"Retention Percentage"},"currency":{"anyOf":[{"type":"string","maxLength":10,"minLength":3},{"type":"null"}],"title":"Currency"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"line_items":{"anyOf":[{"items":{"$ref":"#/components/schemas/JobLineItemCreate"},"type":"array"},{"type":"null"}],"title":"Line Items"},"is_recurring":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Recurring"},"recurrence_frequency":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Recurrence Frequency"},"next_recurrence_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Next Recurrence Date"},"qr_attendance_enabled":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Qr Attendance Enabled"},"site_postcode":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Site Postcode"},"site_lat":{"anyOf":[{"type":"number","maximum":90.0,"minimum":-90.0},{"type":"null"}],"title":"Site Lat"},"site_lon":{"anyOf":[{"type":"number","maximum":180.0,"minimum":-180.0},{"type":"null"}],"title":"Site Lon"},"qr_radius_metres":{"anyOf":[{"type":"integer","maximum":5000.0,"minimum":10.0},{"type":"null"}],"title":"Qr Radius Metres"},"shift_start_time":{"anyOf":[{"type":"string","format":"time"},{"type":"null"}],"title":"Shift Start Time"},"shift_end_time":{"anyOf":[{"type":"string","format":"time"},{"type":"null"}],"title":"Shift End Time"},"site_manager_email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Site Manager Email"},"gate_induction":{"anyOf":[{"$ref":"#/components/schemas/SiteGateMode"},{"type":"null"}]},"gate_cscs":{"anyOf":[{"$ref":"#/components/schemas/SiteGateMode"},{"type":"null"}]},"gate_rams":{"anyOf":[{"$ref":"#/components/schemas/SiteGateMode"},{"type":"null"}]},"active_rams_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Active Rams Id"}},"type":"object","title":"JobUpdateRequest"},"KPIs":{"properties":{"total_pipeline_value":{"type":"number","title":"Total Pipeline Value"},"active_job_value":{"type":"number","title":"Active Job Value"},"invoiced_this_month":{"type":"number","title":"Invoiced This Month"},"total_clients":{"type":"integer","title":"Total Clients"},"total_tenders":{"type":"integer","title":"Total Tenders"},"workers_on_site":{"type":"integer","title":"Workers On Site"},"active_sites":{"type":"integer","title":"Active Sites"},"revenue_this_period":{"type":"number","title":"Revenue This Period"},"leave_today":{"type":"integer","title":"Leave Today"}},"type":"object","required":["total_pipeline_value","active_job_value","invoiced_this_month","total_clients","total_tenders","workers_on_site","active_sites","revenue_this_period","leave_today"],"title":"KPIs"},"LabourEntryIn":{"properties":{"worker_name":{"type":"string","title":"Worker Name"},"trade":{"type":"string","title":"Trade"},"hours":{"type":"number","title":"Hours"},"rate_pence":{"type":"integer","title":"Rate Pence"},"amount":{"type":"number","title":"Amount"}},"type":"object","required":["worker_name","trade","hours","rate_pence","amount"],"title":"LabourEntryIn"},"LabourRateCreate":{"properties":{"trade":{"type":"string","maxLength":100,"minLength":1,"title":"Trade"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"hourly_rate":{"type":"number","minimum":0.0,"title":"Hourly Rate","default":0.0},"daily_rate":{"anyOf":[{"type":"number","minimum":0.0},{"type":"null"}],"title":"Daily Rate"},"overtime_rate":{"anyOf":[{"type":"number","minimum":0.0},{"type":"null"}],"title":"Overtime Rate"},"is_active":{"type":"boolean","title":"Is Active","default":true}},"type":"object","required":["trade"],"title":"LabourRateCreate"},"LabourRateResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"company_id":{"type":"string","format":"uuid","title":"Company Id"},"trade":{"type":"string","title":"Trade"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"hourly_rate":{"type":"number","title":"Hourly Rate"},"daily_rate":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Daily Rate"},"overtime_rate":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Overtime Rate"},"is_active":{"type":"boolean","title":"Is Active"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"}},"type":"object","required":["id","company_id","trade","description","hourly_rate","daily_rate","overtime_rate","is_active","created_at","updated_at"],"title":"LabourRateResponse"},"LabourRateUpdate":{"properties":{"trade":{"anyOf":[{"type":"string","maxLength":100,"minLength":1},{"type":"null"}],"title":"Trade"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"hourly_rate":{"anyOf":[{"type":"number","minimum":0.0},{"type":"null"}],"title":"Hourly Rate"},"daily_rate":{"anyOf":[{"type":"number","minimum":0.0},{"type":"null"}],"title":"Daily Rate"},"overtime_rate":{"anyOf":[{"type":"number","minimum":0.0},{"type":"null"}],"title":"Overtime Rate"},"is_active":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Active"}},"type":"object","title":"LabourRateUpdate"},"LeagueEntry":{"properties":{"rank":{"type":"integer","title":"Rank"},"profile_id":{"type":"string","format":"uuid","title":"Profile Id"},"display_name":{"type":"string","title":"Display Name"},"trades":{"items":{"type":"string"},"type":"array","title":"Trades"},"postcode":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Postcode"},"avg_rating":{"type":"number","title":"Avg Rating"},"review_count":{"type":"integer","title":"Review Count"},"is_verified_estimark":{"type":"boolean","title":"Is Verified Estimark"},"is_boosted":{"type":"boolean","title":"Is Boosted"}},"type":"object","required":["rank","profile_id","display_name","trades","postcode","avg_rating","review_count","is_verified_estimark","is_boosted"],"title":"LeagueEntry"},"LeaveBalanceResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"user_id":{"type":"string","format":"uuid","title":"User Id"},"year":{"type":"integer","title":"Year"},"leave_type":{"$ref":"#/components/schemas/LeaveType"},"allocated_days":{"type":"number","title":"Allocated Days"},"used_days":{"type":"number","title":"Used Days"},"carried_over_days":{"type":"number","title":"Carried Over Days"},"remaining_days":{"type":"number","title":"Remaining Days"}},"type":"object","required":["id","user_id","year","leave_type","allocated_days","used_days","carried_over_days","remaining_days"],"title":"LeaveBalanceResponse"},"LeaveCalendarEvent":{"properties":{"user_id":{"type":"string","format":"uuid","title":"User Id"},"full_name":{"type":"string","title":"Full Name"},"leave_type":{"$ref":"#/components/schemas/LeaveType"},"start_date":{"type":"string","format":"date","title":"Start Date"},"end_date":{"type":"string","format":"date","title":"End Date"},"days_requested":{"type":"number","title":"Days Requested"}},"type":"object","required":["user_id","full_name","leave_type","start_date","end_date","days_requested"],"title":"LeaveCalendarEvent"},"LeavePolicyCreate":{"properties":{"name":{"type":"string","title":"Name","default":"Default Leave Policy"},"annual_days":{"type":"number","title":"Annual Days","default":28.0},"sick_days":{"type":"number","title":"Sick Days","default":10.0},"carry_over_days":{"type":"number","title":"Carry Over Days","default":5.0},"carry_over_expiry_months":{"type":"integer","title":"Carry Over Expiry Months","default":3},"is_default":{"type":"boolean","title":"Is Default","default":true}},"type":"object","title":"LeavePolicyCreate"},"LeavePolicyResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"name":{"type":"string","title":"Name"},"annual_days":{"type":"number","title":"Annual Days"},"sick_days":{"type":"number","title":"Sick Days"},"carry_over_days":{"type":"number","title":"Carry Over Days"},"carry_over_expiry_months":{"type":"integer","title":"Carry Over Expiry Months"},"is_default":{"type":"boolean","title":"Is Default"},"created_at":{"title":"Created At"},"updated_at":{"title":"Updated At"}},"type":"object","required":["id","name","annual_days","sick_days","carry_over_days","carry_over_expiry_months","is_default","created_at","updated_at"],"title":"LeavePolicyResponse"},"LeavePolicyUpdate":{"properties":{"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name"},"annual_days":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Annual Days"},"sick_days":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Sick Days"},"carry_over_days":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Carry Over Days"},"carry_over_expiry_months":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Carry Over Expiry Months"},"is_default":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Default"}},"type":"object","title":"LeavePolicyUpdate"},"LeaveRequestResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"user_id":{"type":"string","format":"uuid","title":"User Id"},"leave_type":{"$ref":"#/components/schemas/LeaveType"},"start_date":{"type":"string","format":"date","title":"Start Date"},"end_date":{"type":"string","format":"date","title":"End Date"},"days_requested":{"type":"number","title":"Days Requested"},"status":{"$ref":"#/components/schemas/LeaveStatus"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"reviewed_by":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Reviewed By"},"review_notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Review Notes"},"created_at":{"title":"Created At"}},"type":"object","required":["id","user_id","leave_type","start_date","end_date","days_requested","status","created_at"],"title":"LeaveRequestResponse"},"LeaveStatus":{"type":"string","enum":["pending","approved","rejected","cancelled"],"title":"LeaveStatus"},"LeaveType":{"type":"string","enum":["annual","sick","unpaid","compassionate","maternity","paternity","other"],"title":"LeaveType"},"LineItemIn":{"properties":{"description":{"type":"string","title":"Description"},"quantity":{"type":"number","title":"Quantity","default":1.0},"unit_price":{"type":"number","title":"Unit Price"}},"type":"object","required":["description","unit_price"],"title":"LineItemIn"},"LineItemType":{"type":"string","enum":["material","labour"],"title":"LineItemType"},"LinkWorkerRequest":{"properties":{"worker_id":{"type":"string","format":"uuid","title":"Worker Id"}},"type":"object","required":["worker_id"],"title":"LinkWorkerRequest"},"LinkableWorker":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"name":{"type":"string","title":"Name"},"job_title":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Job Title"},"email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Email"},"employee_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Employee Id"}},"type":"object","required":["id","name","job_title","email","employee_id"],"title":"LinkableWorker","description":"A worker offered in the \"link this employee\" picker."},"LocationCreate":{"properties":{"name":{"type":"string","maxLength":255,"minLength":1,"title":"Name"},"location_type":{"$ref":"#/components/schemas/StockLocationType","default":"van"},"assigned_user_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Assigned User Id"},"vehicle_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Vehicle Id"}},"type":"object","required":["name"],"title":"LocationCreate"},"LocationResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"name":{"type":"string","title":"Name"},"location_type":{"$ref":"#/components/schemas/StockLocationType"},"assigned_user_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Assigned User Id"},"vehicle_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Vehicle Id"},"is_active":{"type":"boolean","title":"Is Active"}},"type":"object","required":["id","name","location_type","assigned_user_id","vehicle_id","is_active"],"title":"LocationResponse"},"LoginLinkRequest":{"properties":{"email":{"type":"string","format":"email","title":"Email"},"target":{"type":"string","title":"Target","default":"app"}},"type":"object","required":["email"],"title":"LoginLinkRequest"},"LoginLinkVerify":{"properties":{"token":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Token"},"email":{"anyOf":[{"type":"string","format":"email"},{"type":"null"}],"title":"Email"},"code":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Code"}},"type":"object","title":"LoginLinkVerify"},"LoginRequest":{"properties":{"email":{"type":"string","format":"email","title":"Email"},"password":{"type":"string","title":"Password"}},"type":"object","required":["email","password"],"title":"LoginRequest"},"MaintenanceContractCreate":{"properties":{"title":{"type":"string","maxLength":255,"minLength":1,"title":"Title"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"client_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Client Id"},"service_type":{"type":"string","maxLength":100,"minLength":1,"title":"Service Type"},"frequency":{"type":"string","title":"Frequency"},"start_date":{"type":"string","format":"date","title":"Start Date"},"end_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"End Date"},"price_pence":{"type":"integer","minimum":0.0,"title":"Price Pence"},"auto_invoice":{"type":"boolean","title":"Auto Invoice","default":false},"next_visit_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Next Visit Date"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"}},"type":"object","required":["title","service_type","frequency","start_date","price_pence"],"title":"MaintenanceContractCreate"},"MaintenanceContractResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"company_id":{"type":"string","format":"uuid","title":"Company Id"},"client_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Client Id"},"title":{"type":"string","title":"Title"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"service_type":{"type":"string","title":"Service Type"},"frequency":{"type":"string","title":"Frequency"},"start_date":{"type":"string","format":"date","title":"Start Date"},"end_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"End Date"},"price_pence":{"type":"integer","title":"Price Pence"},"is_active":{"type":"boolean","title":"Is Active"},"next_visit_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Next Visit Date"},"last_visit_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Last Visit Date"},"auto_invoice":{"type":"boolean","title":"Auto Invoice"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"},"client_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Client Name"},"visit_count":{"type":"integer","title":"Visit Count","default":0}},"type":"object","required":["id","company_id","client_id","title","description","service_type","frequency","start_date","end_date","price_pence","is_active","next_visit_date","last_visit_date","auto_invoice","notes","created_at","updated_at"],"title":"MaintenanceContractResponse"},"MaintenanceContractUpdate":{"properties":{"title":{"anyOf":[{"type":"string","maxLength":255,"minLength":1},{"type":"null"}],"title":"Title"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"client_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Client Id"},"service_type":{"anyOf":[{"type":"string","maxLength":100,"minLength":1},{"type":"null"}],"title":"Service Type"},"frequency":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Frequency"},"start_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Start Date"},"end_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"End Date"},"price_pence":{"anyOf":[{"type":"integer","minimum":0.0},{"type":"null"}],"title":"Price Pence"},"auto_invoice":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Auto Invoice"},"is_active":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Active"},"next_visit_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Next Visit Date"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"}},"type":"object","title":"MaintenanceContractUpdate"},"MaintenanceCreateRequest":{"properties":{"client_name":{"type":"string","title":"Client Name"},"client_email":{"type":"string","title":"Client Email"},"service_type":{"type":"string","title":"Service Type"},"frequency":{"type":"string","title":"Frequency"},"description":{"type":"string","title":"Description"},"price_pence":{"type":"integer","title":"Price Pence"},"start_date":{"type":"string","format":"date","title":"Start Date"}},"type":"object","required":["client_name","client_email","service_type","frequency","description","price_pence","start_date"],"title":"MaintenanceCreateRequest"},"MaintenanceResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"profile_id":{"type":"string","format":"uuid","title":"Profile Id"},"client_name":{"type":"string","title":"Client Name"},"client_email":{"type":"string","title":"Client Email"},"service_type":{"type":"string","title":"Service Type"},"frequency":{"type":"string","title":"Frequency"},"description":{"type":"string","title":"Description"},"price_pence":{"type":"integer","title":"Price Pence"},"start_date":{"type":"string","format":"date","title":"Start Date"},"is_active":{"type":"boolean","title":"Is Active"},"created_at":{"type":"string","title":"Created At"},"visits":{"anyOf":[{"items":{"$ref":"#/components/schemas/VisitResponse"},"type":"array"},{"type":"null"}],"title":"Visits"}},"type":"object","required":["id","profile_id","client_name","client_email","service_type","frequency","description","price_pence","start_date","is_active","created_at"],"title":"MaintenanceResponse"},"MaintenanceUpdateRequest":{"properties":{"client_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Client Name"},"client_email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Client Email"},"service_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Service Type"},"frequency":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Frequency"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"price_pence":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Price Pence"}},"type":"object","title":"MaintenanceUpdateRequest"},"MaintenanceVisitCreate":{"properties":{"visit_date":{"type":"string","format":"date","title":"Visit Date"},"technician_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Technician Name"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"duration_minutes":{"anyOf":[{"type":"integer","minimum":0.0},{"type":"null"}],"title":"Duration Minutes"}},"type":"object","required":["visit_date"],"title":"MaintenanceVisitCreate"},"MaintenanceVisitResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"contract_id":{"type":"string","format":"uuid","title":"Contract Id"},"visit_date":{"type":"string","format":"date","title":"Visit Date"},"status":{"type":"string","title":"Status"},"technician_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Technician Name"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"photos":{"items":{},"type":"array","title":"Photos"},"duration_minutes":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Duration Minutes"},"invoice_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Invoice Id"},"created_at":{"type":"string","format":"date-time","title":"Created At"}},"type":"object","required":["id","contract_id","visit_date","status","technician_name","notes","photos","duration_minutes","invoice_id","created_at"],"title":"MaintenanceVisitResponse"},"MaintenanceVisitUpdate":{"properties":{"visit_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Visit Date"},"status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Status"},"technician_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Technician Name"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"duration_minutes":{"anyOf":[{"type":"integer","minimum":0.0},{"type":"null"}],"title":"Duration Minutes"},"photos":{"anyOf":[{"items":{},"type":"array"},{"type":"null"}],"title":"Photos"}},"type":"object","title":"MaintenanceVisitUpdate"},"MandateResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"client_id":{"type":"string","format":"uuid","title":"Client Id"},"status":{"$ref":"#/components/schemas/MandateStatus"},"mandate_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Mandate Id"},"reference":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Reference"},"authorised_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Authorised At"}},"type":"object","required":["id","client_id","status","mandate_id","reference","authorised_at"],"title":"MandateResponse"},"MandateStartRequest":{"properties":{"client_id":{"type":"string","format":"uuid","title":"Client Id"},"success_redirect_url":{"type":"string","title":"Success Redirect Url"}},"type":"object","required":["client_id","success_redirect_url"],"title":"MandateStartRequest"},"MandateStartResponse":{"properties":{"mandate":{"$ref":"#/components/schemas/MandateResponse"},"authorisation_url":{"type":"string","title":"Authorisation Url"}},"type":"object","required":["mandate","authorisation_url"],"title":"MandateStartResponse"},"MandateStatus":{"type":"string","enum":["pending","active","cancelled","failed"],"title":"MandateStatus"},"MatchUserStatus":{"type":"string","enum":["new","reviewing","preparing","submitted","won","lost"],"title":"MatchUserStatus"},"MaterialEntryIn":{"properties":{"description":{"type":"string","title":"Description"},"quantity":{"type":"number","title":"Quantity"},"unit":{"type":"string","title":"Unit"},"unit_cost":{"type":"number","title":"Unit Cost"},"amount":{"type":"number","title":"Amount"}},"type":"object","required":["description","quantity","unit","unit_cost","amount"],"title":"MaterialEntryIn"},"MeetingNoteCreate":{"properties":{"title":{"type":"string","title":"Title"},"meeting_date":{"type":"string","format":"date","title":"Meeting Date"},"location":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Location"},"job_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Job Id"},"attendees":{"items":{"type":"object"},"type":"array","title":"Attendees","default":[]},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"action_items":{"items":{"type":"object"},"type":"array","title":"Action Items","default":[]}},"type":"object","required":["title","meeting_date"],"title":"MeetingNoteCreate"},"MeetingNoteResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"company_id":{"type":"string","format":"uuid","title":"Company Id"},"job_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Job Id"},"title":{"type":"string","title":"Title"},"meeting_date":{"type":"string","format":"date","title":"Meeting Date"},"location":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Location"},"attendees":{"items":{"type":"object"},"type":"array","title":"Attendees"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"action_items":{"items":{"type":"object"},"type":"array","title":"Action Items"},"created_by_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Created By Id"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"}},"type":"object","required":["id","company_id","job_id","title","meeting_date","location","attendees","notes","action_items","created_by_id","created_at","updated_at"],"title":"MeetingNoteResponse"},"MeetingNoteUpdate":{"properties":{"title":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Title"},"meeting_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Meeting Date"},"location":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Location"},"job_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Job Id"},"attendees":{"anyOf":[{"items":{"type":"object"},"type":"array"},{"type":"null"}],"title":"Attendees"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"action_items":{"anyOf":[{"items":{"type":"object"},"type":"array"},{"type":"null"}],"title":"Action Items"}},"type":"object","title":"MeetingNoteUpdate"},"MessageChannel":{"type":"string","enum":["sms","email"],"title":"MessageChannel"},"MessageCreate":{"properties":{"body":{"type":"string","title":"Body"},"parent_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Parent Id"}},"type":"object","required":["body"],"title":"MessageCreate"},"MessageKind":{"type":"string","enum":["appointment_confirmed","appointment_reminder","on_my_way","no_access_card","completed","satisfaction"],"title":"MessageKind"},"MessageUpdate":{"properties":{"body":{"type":"string","title":"Body"}},"type":"object","required":["body"],"title":"MessageUpdate"},"MileageLogCreate":{"properties":{"trip_date":{"type":"string","format":"date","title":"Trip Date"},"start_mileage":{"type":"integer","title":"Start Mileage"},"end_mileage":{"type":"integer","title":"End Mileage"},"job_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Job Id"},"driver_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Driver Name"},"purpose":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Purpose"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"}},"type":"object","required":["trip_date","start_mileage","end_mileage"],"title":"MileageLogCreate"},"MileageLogResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"vehicle_id":{"type":"string","format":"uuid","title":"Vehicle Id"},"job_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Job Id"},"trip_date":{"type":"string","format":"date","title":"Trip Date"},"start_mileage":{"type":"integer","title":"Start Mileage"},"end_mileage":{"type":"integer","title":"End Mileage"},"driver_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Driver Name"},"purpose":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Purpose"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"created_at":{"type":"string","format":"date-time","title":"Created At"}},"type":"object","required":["id","vehicle_id","job_id","trip_date","start_mileage","end_mileage","driver_name","purpose","notes","created_at"],"title":"MileageLogResponse"},"MilestoneCreate":{"properties":{"title":{"type":"string","maxLength":500,"minLength":1,"title":"Title"},"target_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Target Date"},"sort_order":{"type":"integer","title":"Sort Order","default":0}},"type":"object","required":["title"],"title":"MilestoneCreate"},"MilestoneResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"job_id":{"type":"string","format":"uuid","title":"Job Id"},"title":{"type":"string","title":"Title"},"target_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Target Date"},"completed":{"type":"boolean","title":"Completed"},"sort_order":{"type":"integer","title":"Sort Order"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"}},"type":"object","required":["id","job_id","title","target_date","completed","sort_order","created_at","updated_at"],"title":"MilestoneResponse"},"MilestoneUpdate":{"properties":{"title":{"anyOf":[{"type":"string","maxLength":500,"minLength":1},{"type":"null"}],"title":"Title"},"target_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Target Date"},"completed":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Completed"},"sort_order":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Sort Order"}},"type":"object","title":"MilestoneUpdate"},"MonthlyRevenue":{"properties":{"month":{"type":"string","title":"Month"},"value":{"type":"number","title":"Value"}},"type":"object","required":["month","value"],"title":"MonthlyRevenue"},"MovementCreate":{"properties":{"item_id":{"type":"string","format":"uuid","title":"Item Id"},"movement_type":{"$ref":"#/components/schemas/StockMovementType"},"quantity":{"type":"number","exclusiveMinimum":0.0,"title":"Quantity"},"from_location_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"From Location Id"},"to_location_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"To Location Id"},"job_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Job Id"},"repair_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Repair Id"},"reference":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Reference"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"}},"type":"object","required":["item_id","movement_type","quantity"],"title":"MovementCreate"},"MovementResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"item_id":{"type":"string","format":"uuid","title":"Item Id"},"movement_type":{"$ref":"#/components/schemas/StockMovementType"},"quantity":{"type":"number","title":"Quantity"},"from_location_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"From Location Id"},"to_location_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"To Location Id"},"job_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Job Id"},"repair_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Repair Id"},"unit_cost":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Unit Cost"},"reference":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Reference"},"created_at":{"type":"string","format":"date-time","title":"Created At"}},"type":"object","required":["id","item_id","movement_type","quantity","from_location_id","to_location_id","job_id","repair_id","unit_cost","reference","created_at"],"title":"MovementResponse"},"MusterPerson":{"properties":{"attendance_record_id":{"type":"string","format":"uuid","title":"Attendance Record Id"},"person_name":{"type":"string","title":"Person Name"},"worker_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Worker Id"},"job_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Job Id"},"job_title":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Job Title"},"job_number":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Job Number"},"clock_in_at":{"type":"string","format":"date-time","title":"Clock In At"},"minutes_on_site":{"type":"integer","title":"Minutes On Site"}},"type":"object","required":["attendance_record_id","person_name","clock_in_at","minutes_on_site"],"title":"MusterPerson"},"MusterResponse":{"properties":{"generated_at":{"type":"string","format":"date-time","title":"Generated At"},"total_on_site":{"type":"integer","title":"Total On Site"},"people":{"items":{"$ref":"#/components/schemas/MusterPerson"},"type":"array","title":"People"}},"type":"object","required":["generated_at","total_on_site","people"],"title":"MusterResponse"},"NationalProductDetailResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"name":{"type":"string","title":"Name"},"slug":{"type":"string","title":"Slug"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"category":{"type":"string","title":"Category"},"subcategory":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Subcategory"},"unit":{"type":"string","title":"Unit"},"brand":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Brand"},"material_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Material Type"},"dimensions":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Dimensions"},"weight_kg":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Weight Kg"},"colour":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Colour"},"specifications":{"type":"object","title":"Specifications"},"image_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Image Url"},"thumbnail_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Thumbnail Url"},"is_active":{"type":"boolean","title":"Is Active"},"supplier_prices":{"items":{"$ref":"#/components/schemas/SupplierPriceResponse"},"type":"array","title":"Supplier Prices","default":[]},"trend":{"anyOf":[{"$ref":"#/components/schemas/PriceTrendResponse"},{"type":"null"}]},"is_favourite":{"type":"boolean","title":"Is Favourite","default":false},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"}},"type":"object","required":["id","name","slug","category","unit","specifications","is_active","created_at","updated_at"],"title":"NationalProductDetailResponse","description":"Full product detail with prices and trend."},"NationalProductListItem":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"name":{"type":"string","title":"Name"},"category":{"type":"string","title":"Category"},"subcategory":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Subcategory"},"unit":{"type":"string","title":"Unit"},"brand":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Brand"},"dimensions":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Dimensions"},"thumbnail_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Thumbnail Url"},"best_price":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Best Price"},"cheapest_supplier":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cheapest Supplier"},"supplier_count":{"type":"integer","title":"Supplier Count","default":0},"trend_direction":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Trend Direction"},"is_favourite":{"type":"boolean","title":"Is Favourite","default":false}},"type":"object","required":["id","name","category","unit"],"title":"NationalProductListItem","description":"Compact product for list/search results."},"NoAccessRequest":{"properties":{"reason":{"type":"string","minLength":1,"title":"Reason"},"evidence_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Evidence Url"}},"type":"object","required":["reason"],"title":"NoAccessRequest"},"NotificationPreferenceResponse":{"properties":{"channels":{"additionalProperties":{"type":"boolean"},"type":"object","title":"Channels"},"digest":{"type":"string","title":"Digest"},"email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Email"}},"type":"object","required":["channels","digest","email"],"title":"NotificationPreferenceResponse"},"NotificationPreferenceUpdate":{"properties":{"channels":{"additionalProperties":{"type":"boolean"},"type":"object","title":"Channels"},"digest":{"type":"string","pattern":"^(instant|daily|weekly)$","title":"Digest","default":"instant"},"email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Email"}},"type":"object","title":"NotificationPreferenceUpdate"},"NotificationResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"company_id":{"type":"string","format":"uuid","title":"Company Id"},"user_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"User Id"},"type":{"$ref":"#/components/schemas/NotificationType"},"title":{"type":"string","title":"Title"},"body":{"type":"string","title":"Body"},"entity_type":{"type":"string","title":"Entity Type"},"entity_id":{"type":"string","format":"uuid","title":"Entity Id"},"is_read":{"type":"boolean","title":"Is Read"},"read_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Read At"},"created_at":{"type":"string","format":"date-time","title":"Created At"}},"type":"object","required":["id","company_id","type","title","body","entity_type","entity_id","is_read","read_at","created_at"],"title":"NotificationResponse"},"NotificationType":{"type":"string","enum":["quote_accepted","quote_expiry_warning","quote_expired","job_overdue","cert_expiring","payment_overdue","comment_posted","retention_release_due","rfi_response_due","rfi_overdue","rfi_assigned","defect_assigned"],"title":"NotificationType"},"ObservationCloseRequest":{"properties":{"corrective_action":{"type":"string","minLength":1,"title":"Corrective Action"},"root_cause":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Root Cause"},"closed_by":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Closed By"}},"type":"object","required":["corrective_action"],"title":"ObservationCloseRequest"},"ObservationCreate":{"properties":{"observation_type":{"$ref":"#/components/schemas/ObservationType","default":"near_miss"},"what_happened":{"type":"string","minLength":1,"title":"What Happened"},"reported_by_name":{"type":"string","maxLength":255,"minLength":1,"title":"Reported By Name"},"occurred_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Occurred At"},"job_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Job Id"},"location":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Location"},"severity":{"$ref":"#/components/schemas/ObservationSeverity","default":"negligible"},"potential_severity":{"$ref":"#/components/schemas/ObservationSeverity","default":"minor"},"immediate_action":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Immediate Action"},"photo_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Photo Url"}},"type":"object","required":["what_happened","reported_by_name"],"title":"ObservationCreate"},"ObservationResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"company_id":{"type":"string","format":"uuid","title":"Company Id"},"job_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Job Id"},"reference":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Reference"},"observation_type":{"$ref":"#/components/schemas/ObservationType"},"occurred_at":{"type":"string","format":"date-time","title":"Occurred At"},"location":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Location"},"what_happened":{"type":"string","title":"What Happened"},"severity":{"$ref":"#/components/schemas/ObservationSeverity"},"potential_severity":{"$ref":"#/components/schemas/ObservationSeverity"},"immediate_action":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Immediate Action"},"corrective_action":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Corrective Action"},"root_cause":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Root Cause"},"photo_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Photo Url"},"reported_by_name":{"type":"string","title":"Reported By Name"},"status":{"$ref":"#/components/schemas/ObservationStatus"},"closed_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Closed At"},"closed_by":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Closed By"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"}},"type":"object","required":["id","company_id","job_id","reference","observation_type","occurred_at","location","what_happened","severity","potential_severity","immediate_action","corrective_action","root_cause","photo_url","reported_by_name","status","closed_at","closed_by","created_at","updated_at"],"title":"ObservationResponse"},"ObservationSeverity":{"type":"string","enum":["negligible","minor","moderate","major","fatal"],"title":"ObservationSeverity","description":"Potential severity had the near miss played out — the leading indicator."},"ObservationStatus":{"type":"string","enum":["open","in_progress","closed"],"title":"ObservationStatus"},"ObservationType":{"type":"string","enum":["near_miss","unsafe_act","unsafe_condition","good_practice"],"title":"ObservationType"},"ObservationUpdate":{"properties":{"observation_type":{"anyOf":[{"$ref":"#/components/schemas/ObservationType"},{"type":"null"}]},"what_happened":{"anyOf":[{"type":"string","minLength":1},{"type":"null"}],"title":"What Happened"},"occurred_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Occurred At"},"location":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Location"},"severity":{"anyOf":[{"$ref":"#/components/schemas/ObservationSeverity"},{"type":"null"}]},"potential_severity":{"anyOf":[{"$ref":"#/components/schemas/ObservationSeverity"},{"type":"null"}]},"immediate_action":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Immediate Action"},"corrective_action":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Corrective Action"},"root_cause":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Root Cause"},"photo_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Photo Url"},"status":{"anyOf":[{"$ref":"#/components/schemas/ObservationStatus"},{"type":"null"}]}},"type":"object","title":"ObservationUpdate"},"OnboardingPortalContext":{"properties":{"onboarding_id":{"type":"string","format":"uuid","title":"Onboarding Id"},"employee_name":{"type":"string","title":"Employee Name"},"employee_number":{"type":"string","title":"Employee Number"},"company_name":{"type":"string","title":"Company Name"},"company_logo_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Company Logo Url"},"start_date":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Start Date"},"tasks":{"items":{"$ref":"#/components/schemas/OnboardingTaskResponse"},"type":"array","title":"Tasks"},"contract_html":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Contract Html"},"hs_policies":{"items":{"$ref":"#/components/schemas/OnboardingPortalPolicy"},"type":"array","title":"Hs Policies"},"status":{"type":"string","title":"Status"}},"type":"object","required":["onboarding_id","employee_name","employee_number","company_name","company_logo_url","start_date","tasks","contract_html","hs_policies","status"],"title":"OnboardingPortalContext"},"OnboardingPortalPolicy":{"properties":{"name":{"type":"string","title":"Name"},"policy_type":{"type":"string","title":"Policy Type"},"content":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Content"}},"type":"object","required":["name","policy_type"],"title":"OnboardingPortalPolicy"},"OnboardingResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"employee_id":{"type":"string","format":"uuid","title":"Employee Id"},"status":{"type":"string","title":"Status"},"token":{"type":"string","title":"Token"},"contract_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Contract Id"},"welcome_email_sent":{"type":"boolean","title":"Welcome Email Sent"},"welcome_email_sent_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Welcome Email Sent At"},"started_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Started At"},"completed_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Completed At"},"tasks":{"items":{"$ref":"#/components/schemas/OnboardingTaskResponse"},"type":"array","title":"Tasks","default":[]},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"}},"type":"object","required":["id","employee_id","status","token","contract_id","welcome_email_sent","welcome_email_sent_at","started_at","completed_at","created_at","updated_at"],"title":"OnboardingResponse"},"OnboardingStatusResponse":{"properties":{"onboarding_step":{"type":"integer","title":"Onboarding Step"},"onboarding_completed":{"type":"boolean","title":"Onboarding Completed"},"profile_score":{"type":"integer","title":"Profile Score"},"score_band":{"additionalProperties":{"type":"string"},"type":"object","title":"Score Band"}},"type":"object","required":["onboarding_step","onboarding_completed","profile_score","score_band"],"title":"OnboardingStatusResponse"},"OnboardingStep1":{"properties":{"trading_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Trading Name"},"companies_house_number":{"anyOf":[{"type":"string","maxLength":20},{"type":"null"}],"title":"Companies House Number"},"vat_number":{"anyOf":[{"type":"string","maxLength":20},{"type":"null"}],"title":"Vat Number"},"founded_year":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Founded Year"},"employee_count":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Employee Count"},"website":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Website"}},"type":"object","title":"OnboardingStep1","description":"Step 1 — About your company."},"OnboardingStep2":{"properties":{"project_types":{"items":{"type":"string"},"type":"array","title":"Project Types","default":[]},"typical_project_value":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Typical Project Value"},"max_project_value":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Max Project Value"},"typical_project_duration":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Typical Project Duration"}},"type":"object","title":"OnboardingStep2","description":"Step 2 — What you build."},"OnboardingStep3":{"properties":{"base_postcode":{"anyOf":[{"type":"string","maxLength":10},{"type":"null"}],"title":"Base Postcode"},"travel_radius":{"anyOf":[{"type":"integer","maximum":200.0,"minimum":10.0},{"type":"null"}],"title":"Travel Radius"},"operating_regions":{"items":{"type":"string"},"type":"array","title":"Operating Regions","default":[]}},"type":"object","title":"OnboardingStep3","description":"Step 3 — Where you work."},"OnboardingStep4":{"properties":{"has_public_liability":{"type":"boolean","title":"Has Public Liability","default":false},"public_liability_value":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Public Liability Value"},"has_employers_liability":{"type":"boolean","title":"Has Employers Liability","default":false},"cis":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cis"},"cis_number":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cis Number"},"accreditations":{"items":{"type":"string"},"type":"array","title":"Accreditations","default":[]}},"type":"object","title":"OnboardingStep4","description":"Step 4 — Accreditations."},"OnboardingStep5":{"properties":{"tender_alerts_enabled":{"type":"boolean","title":"Tender Alerts Enabled","default":false},"tender_min_value":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Tender Min Value"},"tender_max_value":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Tender Max Value"},"tender_alert_frequency":{"type":"string","title":"Tender Alert Frequency","default":"daily"}},"type":"object","title":"OnboardingStep5","description":"Step 5 — Tender preferences."},"OnboardingTaskResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"task_key":{"type":"string","title":"Task Key"},"title":{"type":"string","title":"Title"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"is_required":{"type":"boolean","title":"Is Required"},"is_completed":{"type":"boolean","title":"Is Completed"},"completed_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Completed At"},"sort_order":{"type":"integer","title":"Sort Order"},"task_metadata":{"anyOf":[{"type":"object"},{"type":"null"}],"title":"Task Metadata"}},"type":"object","required":["id","task_key","title","description","is_required","is_completed","completed_at","sort_order"],"title":"OnboardingTaskResponse"},"OrgChartNode":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"employee_number":{"type":"string","title":"Employee Number"},"full_name":{"type":"string","title":"Full Name"},"job_title":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Job Title"},"department_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Department Name"},"photo_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Photo Url"},"children":{"items":{"$ref":"#/components/schemas/OrgChartNode"},"type":"array","title":"Children","default":[]}},"type":"object","required":["id","employee_number","full_name","job_title","department_name","photo_url"],"title":"OrgChartNode"},"PCCertCreate":{"properties":{"cert_number":{"type":"string","title":"Cert Number"},"pc_date":{"type":"string","format":"date","title":"Pc Date"},"contract_value":{"type":"number","title":"Contract Value"},"retention_held":{"type":"number","title":"Retention Held","default":0.0},"retention_release_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Retention Release Date"},"defects_period_months":{"type":"integer","title":"Defects Period Months","default":12},"client_name":{"type":"string","title":"Client Name"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"job_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Job Id"}},"type":"object","required":["cert_number","pc_date","contract_value","client_name"],"title":"PCCertCreate"},"PCCertUpdate":{"properties":{"cert_number":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cert Number"},"pc_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Pc Date"},"contract_value":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Contract Value"},"retention_held":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Retention Held"},"retention_release_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Retention Release Date"},"defects_period_months":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Defects Period Months"},"client_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Client Name"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"}},"type":"object","title":"PCCertUpdate"},"POApprovalDecision":{"properties":{"note":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Note"}},"type":"object","title":"POApprovalDecision"},"POApprovalEventResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"po_id":{"type":"string","format":"uuid","title":"Po Id"},"user_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"User Id"},"action":{"type":"string","title":"Action"},"actor_role":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Actor Role"},"po_total":{"type":"number","title":"Po Total"},"limit_applied":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Limit Applied"},"note":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Note"},"created_at":{"type":"string","format":"date-time","title":"Created At"}},"type":"object","required":["id","po_id","user_id","action","actor_role","po_total","limit_applied","note","created_at"],"title":"POApprovalEventResponse"},"POApprovalLimitEntry":{"properties":{"role":{"type":"string","title":"Role"},"raise_limit":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Raise Limit"},"approve_limit":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Approve Limit"}},"type":"object","required":["role"],"title":"POApprovalLimitEntry"},"POApprovalLimitResponse":{"properties":{"role":{"type":"string","title":"Role"},"raise_limit":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Raise Limit"},"approve_limit":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Approve Limit"},"is_default":{"type":"boolean","title":"Is Default","default":true}},"type":"object","required":["role"],"title":"POApprovalLimitResponse"},"POApprovalLimitsUpdate":{"properties":{"limits":{"items":{"$ref":"#/components/schemas/POApprovalLimitEntry"},"type":"array","title":"Limits","default":[]}},"type":"object","title":"POApprovalLimitsUpdate"},"POCreate":{"properties":{"job_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Job Id"},"subcontractor_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Subcontractor Id"},"supplier_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Supplier Id"},"supplier_name":{"type":"string","maxLength":255,"title":"Supplier Name","default":""},"supplier_email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Supplier Email"},"issued_date":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Issued Date"},"expected_delivery":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Expected Delivery"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"terms":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Terms"},"tax_rate":{"type":"number","title":"Tax Rate","default":20.0},"line_items":{"items":{"$ref":"#/components/schemas/POLineItemCreate"},"type":"array","title":"Line Items","default":[]}},"type":"object","title":"POCreate"},"POLineItemCreate":{"properties":{"description":{"type":"string","minLength":1,"title":"Description"},"quantity":{"type":"number","title":"Quantity","default":1.0},"unit":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Unit"},"unit_price":{"type":"number","title":"Unit Price","default":0.0},"total":{"type":"number","title":"Total","default":0.0},"category":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Category"},"sort_order":{"type":"integer","title":"Sort Order","default":0},"plant_item_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Plant Item Id"}},"type":"object","required":["description"],"title":"POLineItemCreate"},"POLineItemResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"po_id":{"type":"string","format":"uuid","title":"Po Id"},"description":{"type":"string","title":"Description"},"quantity":{"type":"number","title":"Quantity"},"unit":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Unit"},"unit_price":{"type":"number","title":"Unit Price"},"total":{"type":"number","title":"Total"},"quantity_received":{"type":"number","title":"Quantity Received"},"received_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Received At"},"category":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Category"},"sort_order":{"type":"integer","title":"Sort Order"},"plant_item_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Plant Item Id"}},"type":"object","required":["id","po_id","description","quantity","unit","unit_price","total","quantity_received","received_at","category","sort_order","plant_item_id"],"title":"POLineItemResponse"},"POLineItemUpdate":{"properties":{"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"quantity":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Quantity"},"unit":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Unit"},"unit_price":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Unit Price"},"total":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Total"},"category":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Category"},"sort_order":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Sort Order"},"plant_item_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Plant Item Id"}},"type":"object","title":"POLineItemUpdate"},"POResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"company_id":{"type":"string","format":"uuid","title":"Company Id"},"job_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Job Id"},"subcontractor_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Subcontractor Id"},"supplier_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Supplier Id"},"po_number":{"type":"string","title":"Po Number"},"supplier_name":{"type":"string","title":"Supplier Name"},"supplier_email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Supplier Email"},"status":{"$ref":"#/components/schemas/POStatus"},"issued_date":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Issued Date"},"expected_delivery":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Expected Delivery"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"terms":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Terms"},"subtotal":{"type":"number","title":"Subtotal"},"tax_rate":{"type":"number","title":"Tax Rate"},"tax_amount":{"type":"number","title":"Tax Amount"},"total":{"type":"number","title":"Total"},"xero_bill_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Xero Bill Id"},"quickbooks_bill_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Quickbooks Bill Id"},"freshbooks_expense_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Freshbooks Expense Id"},"line_items":{"items":{"$ref":"#/components/schemas/POLineItemResponse"},"type":"array","title":"Line Items","default":[]},"approval_required":{"type":"boolean","title":"Approval Required","default":false},"approval_threshold":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Approval Threshold"},"submitted_by_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Submitted By Id"},"submitted_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Submitted At"},"approved_by_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Approved By Id"},"approved_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Approved At"},"rejected_by_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Rejected By Id"},"rejected_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Rejected At"},"rejection_reason":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Rejection Reason"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"}},"type":"object","required":["id","company_id","job_id","subcontractor_id","po_number","supplier_name","supplier_email","status","issued_date","expected_delivery","notes","terms","subtotal","tax_rate","tax_amount","total","xero_bill_id","quickbooks_bill_id","freshbooks_expense_id","created_at","updated_at"],"title":"POResponse"},"POStatus":{"type":"string","enum":["draft","pending_approval","approved","rejected","sent","partially_received","received","cancelled"],"title":"POStatus"},"POSummaryResponse":{"properties":{"committed":{"type":"number","title":"Committed"},"received":{"type":"number","title":"Received"},"outstanding":{"type":"number","title":"Outstanding"}},"type":"object","required":["committed","received","outstanding"],"title":"POSummaryResponse"},"POUpdate":{"properties":{"job_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Job Id"},"subcontractor_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Subcontractor Id"},"supplier_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Supplier Id"},"supplier_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Supplier Name"},"supplier_email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Supplier Email"},"issued_date":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Issued Date"},"expected_delivery":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Expected Delivery"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"terms":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Terms"},"tax_rate":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Tax Rate"}},"type":"object","title":"POUpdate"},"PageContentUpdate":{"properties":{"content":{"items":{"type":"object"},"type":"array","title":"Content"}},"type":"object","required":["content"],"title":"PageContentUpdate"},"PaginatedResponse_AttendanceRecordResponse_":{"properties":{"items":{"items":{"$ref":"#/components/schemas/AttendanceRecordResponse"},"type":"array","title":"Items"},"total":{"type":"integer","title":"Total"},"page":{"type":"integer","title":"Page"},"per_page":{"type":"integer","title":"Per Page"},"pages":{"type":"integer","title":"Pages"}},"type":"object","required":["items","total","page","per_page","pages"],"title":"PaginatedResponse[AttendanceRecordResponse]"},"PaginatedResponse_AuditLogResponse_":{"properties":{"items":{"items":{"$ref":"#/components/schemas/AuditLogResponse"},"type":"array","title":"Items"},"total":{"type":"integer","title":"Total"},"page":{"type":"integer","title":"Page"},"per_page":{"type":"integer","title":"Per Page"},"pages":{"type":"integer","title":"Pages"}},"type":"object","required":["items","total","page","per_page","pages"],"title":"PaginatedResponse[AuditLogResponse]"},"PaginatedResponse_CISDeductionResponse_":{"properties":{"items":{"items":{"$ref":"#/components/schemas/CISDeductionResponse"},"type":"array","title":"Items"},"total":{"type":"integer","title":"Total"},"page":{"type":"integer","title":"Page"},"per_page":{"type":"integer","title":"Per Page"},"pages":{"type":"integer","title":"Pages"}},"type":"object","required":["items","total","page","per_page","pages"],"title":"PaginatedResponse[CISDeductionResponse]"},"PaginatedResponse_CISMonthlyReturnSummary_":{"properties":{"items":{"items":{"$ref":"#/components/schemas/CISMonthlyReturnSummary"},"type":"array","title":"Items"},"total":{"type":"integer","title":"Total"},"page":{"type":"integer","title":"Page"},"per_page":{"type":"integer","title":"Per Page"},"pages":{"type":"integer","title":"Pages"}},"type":"object","required":["items","total","page","per_page","pages"],"title":"PaginatedResponse[CISMonthlyReturnSummary]"},"PaginatedResponse_CISSubcontractorResponse_":{"properties":{"items":{"items":{"$ref":"#/components/schemas/CISSubcontractorResponse"},"type":"array","title":"Items"},"total":{"type":"integer","title":"Total"},"page":{"type":"integer","title":"Page"},"per_page":{"type":"integer","title":"Per Page"},"pages":{"type":"integer","title":"Pages"}},"type":"object","required":["items","total","page","per_page","pages"],"title":"PaginatedResponse[CISSubcontractorResponse]"},"PaginatedResponse_ClientInteractionResponse_":{"properties":{"items":{"items":{"$ref":"#/components/schemas/ClientInteractionResponse"},"type":"array","title":"Items"},"total":{"type":"integer","title":"Total"},"page":{"type":"integer","title":"Page"},"per_page":{"type":"integer","title":"Per Page"},"pages":{"type":"integer","title":"Pages"}},"type":"object","required":["items","total","page","per_page","pages"],"title":"PaginatedResponse[ClientInteractionResponse]"},"PaginatedResponse_ClientResponse_":{"properties":{"items":{"items":{"$ref":"#/components/schemas/ClientResponse"},"type":"array","title":"Items"},"total":{"type":"integer","title":"Total"},"page":{"type":"integer","title":"Page"},"per_page":{"type":"integer","title":"Per Page"},"pages":{"type":"integer","title":"Pages"}},"type":"object","required":["items","total","page","per_page","pages"],"title":"PaginatedResponse[ClientResponse]"},"PaginatedResponse_CommentResponse_":{"properties":{"items":{"items":{"$ref":"#/components/schemas/CommentResponse"},"type":"array","title":"Items"},"total":{"type":"integer","title":"Total"},"page":{"type":"integer","title":"Page"},"per_page":{"type":"integer","title":"Per Page"},"pages":{"type":"integer","title":"Pages"}},"type":"object","required":["items","total","page","per_page","pages"],"title":"PaginatedResponse[CommentResponse]"},"PaginatedResponse_DailyCheckResponse_":{"properties":{"items":{"items":{"$ref":"#/components/schemas/DailyCheckResponse"},"type":"array","title":"Items"},"total":{"type":"integer","title":"Total"},"page":{"type":"integer","title":"Page"},"per_page":{"type":"integer","title":"Per Page"},"pages":{"type":"integer","title":"Pages"}},"type":"object","required":["items","total","page","per_page","pages"],"title":"PaginatedResponse[DailyCheckResponse]"},"PaginatedResponse_DeliveryResponse_":{"properties":{"items":{"items":{"$ref":"#/components/schemas/DeliveryResponse"},"type":"array","title":"Items"},"total":{"type":"integer","title":"Total"},"page":{"type":"integer","title":"Page"},"per_page":{"type":"integer","title":"Per Page"},"pages":{"type":"integer","title":"Pages"}},"type":"object","required":["items","total","page","per_page","pages"],"title":"PaginatedResponse[DeliveryResponse]"},"PaginatedResponse_EstijobBidResponse_":{"properties":{"items":{"items":{"$ref":"#/components/schemas/EstijobBidResponse"},"type":"array","title":"Items"},"total":{"type":"integer","title":"Total"},"page":{"type":"integer","title":"Page"},"per_page":{"type":"integer","title":"Per Page"},"pages":{"type":"integer","title":"Pages"}},"type":"object","required":["items","total","page","per_page","pages"],"title":"PaginatedResponse[EstijobBidResponse]"},"PaginatedResponse_EstijobLeadResponse_":{"properties":{"items":{"items":{"$ref":"#/components/schemas/EstijobLeadResponse"},"type":"array","title":"Items"},"total":{"type":"integer","title":"Total"},"page":{"type":"integer","title":"Page"},"per_page":{"type":"integer","title":"Per Page"},"pages":{"type":"integer","title":"Pages"}},"type":"object","required":["items","total","page","per_page","pages"],"title":"PaginatedResponse[EstijobLeadResponse]"},"PaginatedResponse_EstijobListingResponse_":{"properties":{"items":{"items":{"$ref":"#/components/schemas/EstijobListingResponse"},"type":"array","title":"Items"},"total":{"type":"integer","title":"Total"},"page":{"type":"integer","title":"Page"},"per_page":{"type":"integer","title":"Per Page"},"pages":{"type":"integer","title":"Pages"}},"type":"object","required":["items","total","page","per_page","pages"],"title":"PaginatedResponse[EstijobListingResponse]"},"PaginatedResponse_EstijobProfileResponse_":{"properties":{"items":{"items":{"$ref":"#/components/schemas/EstijobProfileResponse"},"type":"array","title":"Items"},"total":{"type":"integer","title":"Total"},"page":{"type":"integer","title":"Page"},"per_page":{"type":"integer","title":"Per Page"},"pages":{"type":"integer","title":"Pages"}},"type":"object","required":["items","total","page","per_page","pages"],"title":"PaginatedResponse[EstijobProfileResponse]"},"PaginatedResponse_EstijobReviewResponse_":{"properties":{"items":{"items":{"$ref":"#/components/schemas/EstijobReviewResponse"},"type":"array","title":"Items"},"total":{"type":"integer","title":"Total"},"page":{"type":"integer","title":"Page"},"per_page":{"type":"integer","title":"Per Page"},"pages":{"type":"integer","title":"Pages"}},"type":"object","required":["items","total","page","per_page","pages"],"title":"PaginatedResponse[EstijobReviewResponse]"},"PaginatedResponse_HSDocumentResponse_":{"properties":{"items":{"items":{"$ref":"#/components/schemas/HSDocumentResponse"},"type":"array","title":"Items"},"total":{"type":"integer","title":"Total"},"page":{"type":"integer","title":"Page"},"per_page":{"type":"integer","title":"Per Page"},"pages":{"type":"integer","title":"Pages"}},"type":"object","required":["items","total","page","per_page","pages"],"title":"PaginatedResponse[HSDocumentResponse]"},"PaginatedResponse_InvoiceResponse_":{"properties":{"items":{"items":{"$ref":"#/components/schemas/InvoiceResponse"},"type":"array","title":"Items"},"total":{"type":"integer","title":"Total"},"page":{"type":"integer","title":"Page"},"per_page":{"type":"integer","title":"Per Page"},"pages":{"type":"integer","title":"Pages"}},"type":"object","required":["items","total","page","per_page","pages"],"title":"PaginatedResponse[InvoiceResponse]"},"PaginatedResponse_InvoiceTemplateResponse_":{"properties":{"items":{"items":{"$ref":"#/components/schemas/InvoiceTemplateResponse"},"type":"array","title":"Items"},"total":{"type":"integer","title":"Total"},"page":{"type":"integer","title":"Page"},"per_page":{"type":"integer","title":"Per Page"},"pages":{"type":"integer","title":"Pages"}},"type":"object","required":["items","total","page","per_page","pages"],"title":"PaginatedResponse[InvoiceTemplateResponse]"},"PaginatedResponse_JobResponse_":{"properties":{"items":{"items":{"$ref":"#/components/schemas/JobResponse"},"type":"array","title":"Items"},"total":{"type":"integer","title":"Total"},"page":{"type":"integer","title":"Page"},"per_page":{"type":"integer","title":"Per Page"},"pages":{"type":"integer","title":"Pages"}},"type":"object","required":["items","total","page","per_page","pages"],"title":"PaginatedResponse[JobResponse]"},"PaginatedResponse_MeetingNoteResponse_":{"properties":{"items":{"items":{"$ref":"#/components/schemas/MeetingNoteResponse"},"type":"array","title":"Items"},"total":{"type":"integer","title":"Total"},"page":{"type":"integer","title":"Page"},"per_page":{"type":"integer","title":"Per Page"},"pages":{"type":"integer","title":"Pages"}},"type":"object","required":["items","total","page","per_page","pages"],"title":"PaginatedResponse[MeetingNoteResponse]"},"PaginatedResponse_MileageLogResponse_":{"properties":{"items":{"items":{"$ref":"#/components/schemas/MileageLogResponse"},"type":"array","title":"Items"},"total":{"type":"integer","title":"Total"},"page":{"type":"integer","title":"Page"},"per_page":{"type":"integer","title":"Per Page"},"pages":{"type":"integer","title":"Pages"}},"type":"object","required":["items","total","page","per_page","pages"],"title":"PaginatedResponse[MileageLogResponse]"},"PaginatedResponse_NationalProductListItem_":{"properties":{"items":{"items":{"$ref":"#/components/schemas/NationalProductListItem"},"type":"array","title":"Items"},"total":{"type":"integer","title":"Total"},"page":{"type":"integer","title":"Page"},"per_page":{"type":"integer","title":"Per Page"},"pages":{"type":"integer","title":"Pages"}},"type":"object","required":["items","total","page","per_page","pages"],"title":"PaginatedResponse[NationalProductListItem]"},"PaginatedResponse_PlantMaintenanceLogResponse_":{"properties":{"items":{"items":{"$ref":"#/components/schemas/PlantMaintenanceLogResponse"},"type":"array","title":"Items"},"total":{"type":"integer","title":"Total"},"page":{"type":"integer","title":"Page"},"per_page":{"type":"integer","title":"Per Page"},"pages":{"type":"integer","title":"Pages"}},"type":"object","required":["items","total","page","per_page","pages"],"title":"PaginatedResponse[PlantMaintenanceLogResponse]"},"PaginatedResponse_PlantUsageLogResponse_":{"properties":{"items":{"items":{"$ref":"#/components/schemas/PlantUsageLogResponse"},"type":"array","title":"Items"},"total":{"type":"integer","title":"Total"},"page":{"type":"integer","title":"Page"},"per_page":{"type":"integer","title":"Per Page"},"pages":{"type":"integer","title":"Pages"}},"type":"object","required":["items","total","page","per_page","pages"],"title":"PaginatedResponse[PlantUsageLogResponse]"},"PaginatedResponse_PriceBookItemResponse_":{"properties":{"items":{"items":{"$ref":"#/components/schemas/PriceBookItemResponse"},"type":"array","title":"Items"},"total":{"type":"integer","title":"Total"},"page":{"type":"integer","title":"Page"},"per_page":{"type":"integer","title":"Per Page"},"pages":{"type":"integer","title":"Pages"}},"type":"object","required":["items","total","page","per_page","pages"],"title":"PaginatedResponse[PriceBookItemResponse]"},"PaginatedResponse_PropertyResponse_":{"properties":{"items":{"items":{"$ref":"#/components/schemas/PropertyResponse"},"type":"array","title":"Items"},"total":{"type":"integer","title":"Total"},"page":{"type":"integer","title":"Page"},"per_page":{"type":"integer","title":"Per Page"},"pages":{"type":"integer","title":"Pages"}},"type":"object","required":["items","total","page","per_page","pages"],"title":"PaginatedResponse[PropertyResponse]"},"PaginatedResponse_QualificationResponse_":{"properties":{"items":{"items":{"$ref":"#/components/schemas/QualificationResponse"},"type":"array","title":"Items"},"total":{"type":"integer","title":"Total"},"page":{"type":"integer","title":"Page"},"per_page":{"type":"integer","title":"Per Page"},"pages":{"type":"integer","title":"Pages"}},"type":"object","required":["items","total","page","per_page","pages"],"title":"PaginatedResponse[QualificationResponse]"},"PaginatedResponse_QuoteResponse_":{"properties":{"items":{"items":{"$ref":"#/components/schemas/QuoteResponse"},"type":"array","title":"Items"},"total":{"type":"integer","title":"Total"},"page":{"type":"integer","title":"Page"},"per_page":{"type":"integer","title":"Per Page"},"pages":{"type":"integer","title":"Pages"}},"type":"object","required":["items","total","page","per_page","pages"],"title":"PaginatedResponse[QuoteResponse]"},"PaginatedResponse_RFQResponse_":{"properties":{"items":{"items":{"$ref":"#/components/schemas/RFQResponse"},"type":"array","title":"Items"},"total":{"type":"integer","title":"Total"},"page":{"type":"integer","title":"Page"},"per_page":{"type":"integer","title":"Per Page"},"pages":{"type":"integer","title":"Pages"}},"type":"object","required":["items","total","page","per_page","pages"],"title":"PaginatedResponse[RFQResponse]"},"PaginatedResponse_RepairResponse_":{"properties":{"items":{"items":{"$ref":"#/components/schemas/RepairResponse"},"type":"array","title":"Items"},"total":{"type":"integer","title":"Total"},"page":{"type":"integer","title":"Page"},"per_page":{"type":"integer","title":"Per Page"},"pages":{"type":"integer","title":"Pages"}},"type":"object","required":["items","total","page","per_page","pages"],"title":"PaginatedResponse[RepairResponse]"},"PaginatedResponse_ReviewResponse_":{"properties":{"items":{"items":{"$ref":"#/components/schemas/ReviewResponse"},"type":"array","title":"Items"},"total":{"type":"integer","title":"Total"},"page":{"type":"integer","title":"Page"},"per_page":{"type":"integer","title":"Per Page"},"pages":{"type":"integer","title":"Pages"}},"type":"object","required":["items","total","page","per_page","pages"],"title":"PaginatedResponse[ReviewResponse]"},"PaginatedResponse_SubInvoiceResponse_":{"properties":{"items":{"items":{"$ref":"#/components/schemas/SubInvoiceResponse"},"type":"array","title":"Items"},"total":{"type":"integer","title":"Total"},"page":{"type":"integer","title":"Page"},"per_page":{"type":"integer","title":"Per Page"},"pages":{"type":"integer","title":"Pages"}},"type":"object","required":["items","total","page","per_page","pages"],"title":"PaginatedResponse[SubInvoiceResponse]"},"PaginatedResponse_SubcontractorResponse_":{"properties":{"items":{"items":{"$ref":"#/components/schemas/SubcontractorResponse"},"type":"array","title":"Items"},"total":{"type":"integer","title":"Total"},"page":{"type":"integer","title":"Page"},"per_page":{"type":"integer","title":"Per Page"},"pages":{"type":"integer","title":"Pages"}},"type":"object","required":["items","total","page","per_page","pages"],"title":"PaginatedResponse[SubcontractorResponse]"},"PaginatedResponse_TenderMatchWithOpportunity_":{"properties":{"items":{"items":{"$ref":"#/components/schemas/TenderMatchWithOpportunity"},"type":"array","title":"Items"},"total":{"type":"integer","title":"Total"},"page":{"type":"integer","title":"Page"},"per_page":{"type":"integer","title":"Per Page"},"pages":{"type":"integer","title":"Pages"}},"type":"object","required":["items","total","page","per_page","pages"],"title":"PaginatedResponse[TenderMatchWithOpportunity]"},"PaginatedResponse_TenderOpportunityResponse_":{"properties":{"items":{"items":{"$ref":"#/components/schemas/TenderOpportunityResponse"},"type":"array","title":"Items"},"total":{"type":"integer","title":"Total"},"page":{"type":"integer","title":"Page"},"per_page":{"type":"integer","title":"Per Page"},"pages":{"type":"integer","title":"Pages"}},"type":"object","required":["items","total","page","per_page","pages"],"title":"PaginatedResponse[TenderOpportunityResponse]"},"PaginatedResponse_TenderResponse_":{"properties":{"items":{"items":{"$ref":"#/components/schemas/TenderResponse"},"type":"array","title":"Items"},"total":{"type":"integer","title":"Total"},"page":{"type":"integer","title":"Page"},"per_page":{"type":"integer","title":"Per Page"},"pages":{"type":"integer","title":"Pages"}},"type":"object","required":["items","total","page","per_page","pages"],"title":"PaginatedResponse[TenderResponse]"},"PaginatedResponse_TimesheetEntryResponse_":{"properties":{"items":{"items":{"$ref":"#/components/schemas/TimesheetEntryResponse"},"type":"array","title":"Items"},"total":{"type":"integer","title":"Total"},"page":{"type":"integer","title":"Page"},"per_page":{"type":"integer","title":"Per Page"},"pages":{"type":"integer","title":"Pages"}},"type":"object","required":["items","total","page","per_page","pages"],"title":"PaginatedResponse[TimesheetEntryResponse]"},"PaginatedResponse_VehicleResponse_":{"properties":{"items":{"items":{"$ref":"#/components/schemas/VehicleResponse"},"type":"array","title":"Items"},"total":{"type":"integer","title":"Total"},"page":{"type":"integer","title":"Page"},"per_page":{"type":"integer","title":"Per Page"},"pages":{"type":"integer","title":"Pages"}},"type":"object","required":["items","total","page","per_page","pages"],"title":"PaginatedResponse[VehicleResponse]"},"PaginatedResponse_WorkerResponse_":{"properties":{"items":{"items":{"$ref":"#/components/schemas/app__schemas__training__WorkerResponse"},"type":"array","title":"Items"},"total":{"type":"integer","title":"Total"},"page":{"type":"integer","title":"Page"},"per_page":{"type":"integer","title":"Per Page"},"pages":{"type":"integer","title":"Pages"}},"type":"object","required":["items","total","page","per_page","pages"],"title":"PaginatedResponse[WorkerResponse]"},"PayFrequency":{"type":"string","enum":["weekly","fortnightly","monthly","four_weekly"],"title":"PayFrequency"},"PayLessNoticeRequest":{"properties":{"pay_less_amount":{"type":"number","minimum":0.0,"title":"Pay Less Amount"},"pay_less_reason":{"type":"string","title":"Pay Less Reason"}},"type":"object","required":["pay_less_amount","pay_less_reason"],"title":"PayLessNoticeRequest"},"PayType":{"type":"string","enum":["salary","hourly"],"title":"PayType"},"PaymentApplicationCreate":{"properties":{"job_id":{"type":"string","format":"uuid","title":"Job Id"},"application_date":{"type":"string","format":"date","title":"Application Date"},"period_from":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Period From"},"period_to":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Period To"},"gross_cumulative":{"type":"number","minimum":0.0,"title":"Gross Cumulative"},"retention_percentage":{"type":"number","maximum":100.0,"minimum":0.0,"title":"Retention Percentage","default":5.0},"is_final":{"type":"boolean","title":"Is Final","default":false},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"}},"type":"object","required":["job_id","application_date","gross_cumulative"],"title":"PaymentApplicationCreate"},"PaymentApplicationResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"company_id":{"type":"string","format":"uuid","title":"Company Id"},"job_id":{"type":"string","format":"uuid","title":"Job Id"},"invoice_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Invoice Id"},"application_number":{"type":"integer","title":"Application Number"},"reference":{"type":"string","title":"Reference"},"application_date":{"type":"string","format":"date","title":"Application Date"},"period_from":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Period From"},"period_to":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Period To"},"gross_cumulative":{"type":"number","title":"Gross Cumulative"},"retention_percentage":{"type":"number","title":"Retention Percentage"},"retention_amount":{"type":"number","title":"Retention Amount"},"previous_certified":{"type":"number","title":"Previous Certified"},"net_application":{"type":"number","title":"Net Application"},"status":{"type":"string","title":"Status"},"certified_amount":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Certified Amount"},"certified_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Certified Date"},"certified_by":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Certified By"},"pay_less_notice":{"type":"boolean","title":"Pay Less Notice"},"pay_less_amount":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Pay Less Amount"},"pay_less_reason":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Pay Less Reason"},"due_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Due Date"},"final_date_for_payment":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Final Date For Payment"},"payment_notice_amount":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Payment Notice Amount"},"payment_notice_served_on":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Payment Notice Served On"},"payment_notice_basis":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Payment Notice Basis"},"pay_less_served_on":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Pay Less Served On"},"pay_less_basis":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Pay Less Basis"},"is_final":{"type":"boolean","title":"Is Final"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"provider":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Provider"},"xero_invoice_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Xero Invoice Id"},"quickbooks_invoice_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Quickbooks Invoice Id"},"freshbooks_invoice_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Freshbooks Invoice Id"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"},"job_title":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Job Title"},"job_number":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Job Number"},"client_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Client Name"}},"type":"object","required":["id","company_id","job_id","invoice_id","application_number","reference","application_date","period_from","period_to","gross_cumulative","retention_percentage","retention_amount","previous_certified","net_application","status","certified_amount","certified_date","certified_by","pay_less_notice","pay_less_amount","pay_less_reason","is_final","notes","provider","xero_invoice_id","quickbooks_invoice_id","freshbooks_invoice_id","created_at","updated_at"],"title":"PaymentApplicationResponse"},"PaymentApplicationUpdate":{"properties":{"application_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Application Date"},"period_from":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Period From"},"period_to":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Period To"},"gross_cumulative":{"anyOf":[{"type":"number","minimum":0.0},{"type":"null"}],"title":"Gross Cumulative"},"retention_percentage":{"anyOf":[{"type":"number","maximum":100.0,"minimum":0.0},{"type":"null"}],"title":"Retention Percentage"},"is_final":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Final"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"}},"type":"object","title":"PaymentApplicationUpdate"},"PaymentMethod":{"type":"string","enum":["bank_transfer","card","direct_debit","cash","cheque","other"],"title":"PaymentMethod"},"PaymentPlanResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"invoice_id":{"type":"string","format":"uuid","title":"Invoice Id"},"company_id":{"type":"string","format":"uuid","title":"Company Id"},"installments":{"items":{"$ref":"#/components/schemas/InstallmentResponse"},"type":"array","title":"Installments"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"}},"type":"object","required":["id","invoice_id","company_id","installments","notes","created_at","updated_at"],"title":"PaymentPlanResponse"},"PaymentResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"invoice_id":{"type":"string","format":"uuid","title":"Invoice Id"},"amount":{"type":"number","title":"Amount"},"payment_date":{"type":"string","format":"date","title":"Payment Date"},"method":{"$ref":"#/components/schemas/PaymentMethod"},"reference":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Reference"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"is_voided":{"type":"boolean","title":"Is Voided"},"void_reason":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Void Reason"},"created_at":{"type":"string","format":"date-time","title":"Created At"}},"type":"object","required":["id","invoice_id","amount","payment_date","method","reference","notes","is_voided","void_reason","created_at"],"title":"PaymentResponse"},"PayrollGenerateRequest":{"properties":{"period_start":{"type":"string","format":"date","title":"Period Start"},"period_end":{"type":"string","format":"date","title":"Period End"},"pay_date":{"type":"string","format":"date","title":"Pay Date"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"}},"type":"object","required":["period_start","period_end","pay_date"],"title":"PayrollGenerateRequest"},"PayrollRunEntryResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"payroll_run_id":{"type":"string","format":"uuid","title":"Payroll Run Id"},"employee_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Employee Id"},"worker_name":{"type":"string","title":"Worker Name"},"employment_type":{"type":"string","title":"Employment Type"},"ni_number":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Ni Number"},"tax_code":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Tax Code"},"ni_category":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Ni Category"},"timesheet_hours":{"type":"number","title":"Timesheet Hours"},"overtime_hours":{"type":"number","title":"Overtime Hours"},"gross_pay":{"type":"number","title":"Gross Pay"},"employee_ni":{"type":"number","title":"Employee Ni"},"employer_ni":{"type":"number","title":"Employer Ni"},"paye_tax":{"type":"number","title":"Paye Tax"},"pension_employee":{"type":"number","title":"Pension Employee"},"pension_employer":{"type":"number","title":"Pension Employer"},"net_pay":{"type":"number","title":"Net Pay"},"created_at":{"type":"string","format":"date-time","title":"Created At"}},"type":"object","required":["id","payroll_run_id","employee_id","worker_name","employment_type","ni_number","tax_code","ni_category","timesheet_hours","overtime_hours","gross_pay","employee_ni","employer_ni","paye_tax","pension_employee","pension_employer","net_pay","created_at"],"title":"PayrollRunEntryResponse"},"PayrollRunResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"company_id":{"type":"string","format":"uuid","title":"Company Id"},"period_start":{"type":"string","format":"date","title":"Period Start"},"period_end":{"type":"string","format":"date","title":"Period End"},"pay_date":{"type":"string","format":"date","title":"Pay Date"},"status":{"type":"string","title":"Status"},"total_gross_pay":{"type":"number","title":"Total Gross Pay"},"total_employee_ni":{"type":"number","title":"Total Employee Ni"},"total_employer_ni":{"type":"number","title":"Total Employer Ni"},"total_paye_tax":{"type":"number","title":"Total Paye Tax"},"total_net_pay":{"type":"number","title":"Total Net Pay"},"entry_count":{"type":"integer","title":"Entry Count"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"entries":{"items":{"$ref":"#/components/schemas/PayrollRunEntryResponse"},"type":"array","title":"Entries","default":[]},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"}},"type":"object","required":["id","company_id","period_start","period_end","pay_date","status","total_gross_pay","total_employee_ni","total_employer_ni","total_paye_tax","total_net_pay","entry_count","notes","created_at","updated_at"],"title":"PayrollRunResponse"},"PerformanceReviewCreate":{"properties":{"employee_id":{"type":"string","format":"uuid","title":"Employee Id"},"reviewer_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Reviewer Id"},"review_period":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Review Period"},"review_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Review Date"},"overall_rating":{"anyOf":[{"type":"integer","maximum":5.0,"minimum":1.0},{"type":"null"}],"title":"Overall Rating"},"objectives_rating":{"anyOf":[{"type":"integer","maximum":5.0,"minimum":1.0},{"type":"null"}],"title":"Objectives Rating"},"skills_rating":{"anyOf":[{"type":"integer","maximum":5.0,"minimum":1.0},{"type":"null"}],"title":"Skills Rating"},"attitude_rating":{"anyOf":[{"type":"integer","maximum":5.0,"minimum":1.0},{"type":"null"}],"title":"Attitude Rating"},"strengths":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Strengths"},"development_areas":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Development Areas"},"objectives_next":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Objectives Next"},"manager_comments":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Manager Comments"},"employee_comments":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Employee Comments"},"status":{"type":"string","title":"Status","default":"draft"}},"type":"object","required":["employee_id"],"title":"PerformanceReviewCreate"},"PerformanceReviewResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"employee_id":{"type":"string","format":"uuid","title":"Employee Id"},"company_id":{"type":"string","format":"uuid","title":"Company Id"},"reviewer_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Reviewer Id"},"review_period":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Review Period"},"review_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Review Date"},"overall_rating":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Overall Rating"},"objectives_rating":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Objectives Rating"},"skills_rating":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Skills Rating"},"attitude_rating":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Attitude Rating"},"strengths":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Strengths"},"development_areas":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Development Areas"},"objectives_next":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Objectives Next"},"manager_comments":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Manager Comments"},"employee_comments":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Employee Comments"},"status":{"type":"string","title":"Status"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"}},"type":"object","required":["id","employee_id","company_id","reviewer_id","review_period","review_date","overall_rating","objectives_rating","skills_rating","attitude_rating","strengths","development_areas","objectives_next","manager_comments","employee_comments","status","created_at","updated_at"],"title":"PerformanceReviewResponse"},"PerformanceReviewUpdate":{"properties":{"reviewer_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Reviewer Id"},"review_period":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Review Period"},"review_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Review Date"},"overall_rating":{"anyOf":[{"type":"integer","maximum":5.0,"minimum":1.0},{"type":"null"}],"title":"Overall Rating"},"objectives_rating":{"anyOf":[{"type":"integer","maximum":5.0,"minimum":1.0},{"type":"null"}],"title":"Objectives Rating"},"skills_rating":{"anyOf":[{"type":"integer","maximum":5.0,"minimum":1.0},{"type":"null"}],"title":"Skills Rating"},"attitude_rating":{"anyOf":[{"type":"integer","maximum":5.0,"minimum":1.0},{"type":"null"}],"title":"Attitude Rating"},"strengths":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Strengths"},"development_areas":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Development Areas"},"objectives_next":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Objectives Next"},"manager_comments":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Manager Comments"},"employee_comments":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Employee Comments"},"status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Status"}},"type":"object","title":"PerformanceReviewUpdate"},"PermitCreate":{"properties":{"permit_number":{"type":"string","title":"Permit Number"},"permit_type":{"$ref":"#/components/schemas/PermitTypeEnum"},"issued_to":{"type":"string","title":"Issued To"},"issued_by":{"type":"string","title":"Issued By"},"approved_by":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Approved By"},"valid_from":{"type":"string","format":"date","title":"Valid From"},"valid_to":{"type":"string","format":"date","title":"Valid To"},"risk_level":{"type":"string","title":"Risk Level","default":"medium"},"precautions":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Precautions"},"ppe_required":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Ppe Required"},"location":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Location"},"job_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Job Id"}},"type":"object","required":["permit_number","permit_type","issued_to","issued_by","valid_from","valid_to"],"title":"PermitCreate"},"PermitTypeEnum":{"type":"string","enum":["hot_work","confined_space","electrical","working_at_height","excavation","other"],"title":"PermitTypeEnum"},"PermitUpdate":{"properties":{"permit_number":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Permit Number"},"issued_to":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Issued To"},"issued_by":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Issued By"},"approved_by":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Approved By"},"valid_from":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Valid From"},"valid_to":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Valid To"},"risk_level":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Risk Level"},"precautions":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Precautions"},"ppe_required":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Ppe Required"},"location":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Location"}},"type":"object","title":"PermitUpdate"},"PhotoAlbumCreate":{"properties":{"job_id":{"type":"string","format":"uuid","title":"Job Id"},"name":{"type":"string","title":"Name"},"stage":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Stage"},"album_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Album Date"}},"type":"object","required":["job_id","name"],"title":"PhotoAlbumCreate"},"PhotoAlbumResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"company_id":{"type":"string","format":"uuid","title":"Company Id"},"job_id":{"type":"string","format":"uuid","title":"Job Id"},"name":{"type":"string","title":"Name"},"stage":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Stage"},"album_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Album Date"},"photo_count":{"type":"integer","title":"Photo Count"},"created_at":{"type":"string","format":"date-time","title":"Created At"}},"type":"object","required":["id","company_id","job_id","name","stage","album_date","photo_count","created_at"],"title":"PhotoAlbumResponse"},"PhotoAlbumUpdate":{"properties":{"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name"},"stage":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Stage"},"album_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Album Date"}},"type":"object","title":"PhotoAlbumUpdate"},"PhotoLinkCreate":{"properties":{"linked_type":{"type":"string","title":"Linked Type"},"linked_id":{"type":"string","format":"uuid","title":"Linked Id"}},"type":"object","required":["linked_type","linked_id"],"title":"PhotoLinkCreate"},"PhotoLinkResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"photo_id":{"type":"string","format":"uuid","title":"Photo Id"},"linked_type":{"type":"string","title":"Linked Type"},"linked_id":{"type":"string","format":"uuid","title":"Linked Id"},"created_at":{"type":"string","format":"date-time","title":"Created At"}},"type":"object","required":["id","photo_id","linked_type","linked_id","created_at"],"title":"PhotoLinkResponse"},"PipelineItem":{"properties":{"status":{"type":"string","title":"Status"},"count":{"type":"integer","title":"Count"},"value":{"type":"number","title":"Value"}},"type":"object","required":["status","count","value"],"title":"PipelineItem"},"PlantEntryIn":{"properties":{"description":{"type":"string","title":"Description"},"hours":{"type":"number","title":"Hours"},"rate":{"type":"number","title":"Rate"},"amount":{"type":"number","title":"Amount"}},"type":"object","required":["description","hours","rate","amount"],"title":"PlantEntryIn"},"PlantItemCreate":{"properties":{"name":{"type":"string","maxLength":500,"minLength":1,"title":"Name"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"category":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Category"},"ownership_type":{"$ref":"#/components/schemas/PlantOwnershipType","default":"both"},"hire_rate":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Hire Rate"},"owned_rate":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Owned Rate"},"unit":{"type":"string","title":"Unit","default":"day"},"supplier_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Supplier Name"},"supplier_ref":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Supplier Ref"},"price_book_item_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Price Book Item Id"}},"type":"object","required":["name"],"title":"PlantItemCreate"},"PlantItemFleetUpdate":{"properties":{"serial_number":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Serial Number"},"current_location":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Current Location"},"asset_status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Asset Status"}},"type":"object","title":"PlantItemFleetUpdate"},"PlantItemResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"company_id":{"type":"string","format":"uuid","title":"Company Id"},"name":{"type":"string","title":"Name"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"category":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Category"},"ownership_type":{"$ref":"#/components/schemas/PlantOwnershipType"},"hire_rate":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Hire Rate"},"owned_rate":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Owned Rate"},"unit":{"type":"string","title":"Unit"},"supplier_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Supplier Name"},"supplier_ref":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Supplier Ref"},"price_book_item_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Price Book Item Id"},"is_active":{"type":"boolean","title":"Is Active"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"}},"type":"object","required":["id","company_id","name","description","category","ownership_type","hire_rate","owned_rate","unit","supplier_name","supplier_ref","price_book_item_id","is_active","created_at","updated_at"],"title":"PlantItemResponse"},"PlantItemUpdate":{"properties":{"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"category":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Category"},"ownership_type":{"anyOf":[{"$ref":"#/components/schemas/PlantOwnershipType"},{"type":"null"}]},"hire_rate":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Hire Rate"},"owned_rate":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Owned Rate"},"unit":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Unit"},"supplier_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Supplier Name"},"supplier_ref":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Supplier Ref"},"price_book_item_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Price Book Item Id"},"is_active":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Active"}},"type":"object","title":"PlantItemUpdate"},"PlantMaintenanceLogCreate":{"properties":{"service_type":{"type":"string","maxLength":50,"minLength":1,"title":"Service Type"},"done_date":{"type":"string","format":"date","title":"Done Date"},"done_by":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Done By"},"cost":{"anyOf":[{"type":"number"},{"type":"string"},{"type":"null"}],"title":"Cost"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"next_due_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Next Due Date"}},"type":"object","required":["service_type","done_date"],"title":"PlantMaintenanceLogCreate"},"PlantMaintenanceLogResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"plant_item_id":{"type":"string","format":"uuid","title":"Plant Item Id"},"service_type":{"type":"string","title":"Service Type"},"done_date":{"type":"string","format":"date","title":"Done Date"},"done_by":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Done By"},"cost":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cost"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"next_due_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Next Due Date"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"}},"type":"object","required":["id","plant_item_id","service_type","done_date","done_by","cost","notes","next_due_date","created_at","updated_at"],"title":"PlantMaintenanceLogResponse"},"PlantMaintenanceScheduleCreate":{"properties":{"service_type":{"type":"string","maxLength":50,"minLength":1,"title":"Service Type"},"interval_days":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Interval Days"},"last_done_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Last Done Date"},"next_due_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Next Due Date"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"}},"type":"object","required":["service_type"],"title":"PlantMaintenanceScheduleCreate"},"PlantMaintenanceScheduleResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"plant_item_id":{"type":"string","format":"uuid","title":"Plant Item Id"},"service_type":{"type":"string","title":"Service Type"},"interval_days":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Interval Days"},"last_done_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Last Done Date"},"next_due_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Next Due Date"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"}},"type":"object","required":["id","plant_item_id","service_type","interval_days","last_done_date","next_due_date","notes","created_at","updated_at"],"title":"PlantMaintenanceScheduleResponse"},"PlantMaintenanceScheduleUpdate":{"properties":{"service_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Service Type"},"interval_days":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Interval Days"},"last_done_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Last Done Date"},"next_due_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Next Due Date"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"}},"type":"object","title":"PlantMaintenanceScheduleUpdate"},"PlantOwnershipType":{"type":"string","enum":["hired","owned","both"],"title":"PlantOwnershipType"},"PlantUsageLogCheckIn":{"properties":{"checked_in_at":{"type":"string","format":"date-time","title":"Checked In At"},"hours_used":{"anyOf":[{"type":"number"},{"type":"string"},{"type":"null"}],"title":"Hours Used"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"}},"type":"object","required":["checked_in_at"],"title":"PlantUsageLogCheckIn"},"PlantUsageLogCreate":{"properties":{"job_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Job Id"},"operator_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Operator Name"},"location":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Location"},"checked_out_at":{"type":"string","format":"date-time","title":"Checked Out At"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"}},"type":"object","required":["checked_out_at"],"title":"PlantUsageLogCreate"},"PlantUsageLogResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"plant_item_id":{"type":"string","format":"uuid","title":"Plant Item Id"},"job_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Job Id"},"operator_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Operator Name"},"location":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Location"},"checked_out_at":{"type":"string","format":"date-time","title":"Checked Out At"},"checked_in_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Checked In At"},"hours_used":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Hours Used"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"created_at":{"type":"string","format":"date-time","title":"Created At"}},"type":"object","required":["id","plant_item_id","job_id","operator_name","location","checked_out_at","checked_in_at","hours_used","notes","created_at"],"title":"PlantUsageLogResponse"},"PolicyAckBody":{"properties":{"policy_names":{"items":{"type":"string"},"type":"array","title":"Policy Names"}},"type":"object","required":["policy_names"],"title":"PolicyAckBody"},"PolicyAcknowledgementCreate":{"properties":{"policy_name":{"type":"string","maxLength":255,"minLength":1,"title":"Policy Name"},"policy_version":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Policy Version"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"}},"type":"object","required":["policy_name"],"title":"PolicyAcknowledgementCreate"},"PolicySetupPayload":{"properties":{"company_type":{"type":"string","title":"Company Type","description":"e.g. Main Contractor, Subcontractor, Specialist Contractor"},"headcount":{"type":"string","title":"Headcount","description":"e.g. 1-5, 6-20, 21-50, 51-100, 100+"},"work_types":{"items":{"type":"string"},"type":"array","title":"Work Types"},"hazards":{"items":{"type":"string"},"type":"array","title":"Hazards"},"authorised_by":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Authorised By"}},"type":"object","required":["company_type","headcount"],"title":"PolicySetupPayload","description":"Payload for the AI-powered policy generation setup wizard."},"PortalDeclineRequest":{"properties":{"reason":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Reason"}},"type":"object","title":"PortalDeclineRequest"},"PortalInvoiceInfo":{"properties":{"invoice_number":{"type":"string","title":"Invoice Number"},"status":{"type":"string","title":"Status"},"amount_total":{"type":"number","title":"Amount Total"},"amount_paid":{"type":"number","title":"Amount Paid"},"amount_due":{"type":"number","title":"Amount Due"},"currency":{"type":"string","title":"Currency","default":"GBP"},"due_date":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Due Date"},"payments_enabled":{"type":"boolean","title":"Payments Enabled","default":false}},"type":"object","required":["invoice_number","status","amount_total","amount_paid","amount_due","due_date"],"title":"PortalInvoiceInfo"},"PortalLinkResponse":{"properties":{"token":{"type":"string","title":"Token"},"url":{"type":"string","title":"Url"}},"type":"object","required":["token","url"],"title":"PortalLinkResponse"},"PortalOptionSelection":{"properties":{"selected_line_item_ids":{"items":{"type":"string","format":"uuid"},"type":"array","title":"Selected Line Item Ids","default":[]}},"type":"object","title":"PortalOptionSelection","description":"Which optional lines the customer wants. Omitted optional lines are deselected."},"PortalPayIntentResponse":{"properties":{"client_secret":{"type":"string","title":"Client Secret"},"stripe_publishable_key":{"type":"string","title":"Stripe Publishable Key"},"amount_due":{"type":"number","title":"Amount Due"},"currency":{"type":"string","title":"Currency"}},"type":"object","required":["client_secret","stripe_publishable_key","amount_due","currency"],"title":"PortalPayIntentResponse"},"PortalQuoteLineItem":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"description":{"type":"string","title":"Description"},"quantity":{"type":"number","title":"Quantity"},"unit":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Unit"},"unit_price":{"type":"number","title":"Unit Price"},"total":{"type":"number","title":"Total"},"category":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Category"},"is_optional":{"type":"boolean","title":"Is Optional","default":false},"is_selected":{"type":"boolean","title":"Is Selected","default":true},"option_group":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Option Group"}},"type":"object","required":["id","description","quantity","unit","unit_price","total","category"],"title":"PortalQuoteLineItem"},"PortalQuoteResponse":{"properties":{"quote_id":{"type":"string","format":"uuid","title":"Quote Id"},"quote_number":{"type":"string","title":"Quote Number"},"title":{"type":"string","title":"Title"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"status":{"type":"string","title":"Status"},"subtotal":{"type":"number","title":"Subtotal"},"tax_rate":{"type":"number","title":"Tax Rate"},"tax_amount":{"type":"number","title":"Tax Amount"},"total":{"type":"number","title":"Total"},"currency":{"type":"string","title":"Currency"},"valid_until":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Valid Until"},"site_address":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Site Address"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"terms":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Terms"},"company_name":{"type":"string","title":"Company Name"},"deposit_net":{"type":"number","title":"Deposit Net","default":0.0},"deposit_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Deposit Type"},"deposit_value":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Deposit Value"},"line_items":{"items":{"$ref":"#/components/schemas/PortalQuoteLineItem"},"type":"array","title":"Line Items"},"is_signed":{"type":"boolean","title":"Is Signed"},"signer_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Signer Name"},"signed_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Signed At"},"invoice":{"anyOf":[{"$ref":"#/components/schemas/PortalInvoiceInfo"},{"type":"null"}]}},"type":"object","required":["quote_id","quote_number","title","description","status","subtotal","tax_rate","tax_amount","total","currency","valid_until","site_address","notes","terms","company_name","line_items","is_signed","signer_name","signed_at","invoice"],"title":"PortalQuoteResponse","description":"Public quote data returned to the client portal (no auth required)."},"PortalSignRequest":{"properties":{"signer_name":{"type":"string","maxLength":255,"minLength":1,"title":"Signer Name"},"signer_email":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Signer Email"},"signature_data":{"type":"string","minLength":10,"title":"Signature Data"}},"type":"object","required":["signer_name","signature_data"],"title":"PortalSignRequest"},"PortalVariationRequest":{"properties":{"title":{"type":"string","maxLength":500,"minLength":1,"title":"Title"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"requested_amount":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Requested Amount"}},"type":"object","required":["title"],"title":"PortalVariationRequest"},"PortfolioPhoto":{"properties":{"url":{"type":"string","title":"Url"},"caption":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Caption"},"is_before":{"type":"boolean","title":"Is Before","default":false}},"type":"object","required":["url"],"title":"PortfolioPhoto"},"PosterRatingResponse":{"properties":{"avg_rating":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Avg Rating"},"review_count":{"type":"integer","title":"Review Count"},"reviews":{"items":{"$ref":"#/components/schemas/EstijobReviewResponse"},"type":"array","title":"Reviews"}},"type":"object","required":["avg_rating","review_count","reviews"],"title":"PosterRatingResponse"},"PredictProfitabilityBody":{"properties":{"job_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Job Id"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"value":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Value"},"job_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Job Type"}},"type":"object","title":"PredictProfitabilityBody"},"PrefillRequest":{"properties":{"source":{"type":"string","title":"Source","default":"estisearch"},"address":{"type":"string","title":"Address"},"postcode":{"type":"string","title":"Postcode"},"title_number":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Title Number"},"site_area_sqm":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Site Area Sqm"},"planning_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Planning Type"},"planning_reference":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Planning Reference"},"unit_count":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Unit Count"},"storeys":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Storeys"},"land_value":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Land Value"}},"type":"object","required":["address","postcode"],"title":"PrefillRequest"},"PriceBookItemCreate":{"properties":{"name":{"type":"string","maxLength":500,"minLength":1,"title":"Name"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"category":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Category"},"unit":{"type":"string","title":"Unit","default":"each"},"unit_price":{"type":"number","minimum":0.0,"title":"Unit Price","default":0.0},"sku":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Sku"},"supplier_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Supplier Name"},"supplier_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Supplier Url"},"supplier_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Supplier Id"},"source":{"$ref":"#/components/schemas/PriceBookSource","default":"manual"}},"type":"object","required":["name"],"title":"PriceBookItemCreate"},"PriceBookItemResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"company_id":{"type":"string","format":"uuid","title":"Company Id"},"name":{"type":"string","title":"Name"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"category":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Category"},"unit":{"type":"string","title":"Unit"},"unit_price":{"type":"number","title":"Unit Price"},"sku":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Sku"},"supplier_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Supplier Name"},"supplier_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Supplier Url"},"supplier_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Supplier Id"},"source":{"$ref":"#/components/schemas/PriceBookSource"},"last_updated_at":{"type":"string","format":"date-time","title":"Last Updated At"},"price_last_scraped_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Price Last Scraped At"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"}},"type":"object","required":["id","company_id","name","description","category","unit","unit_price","sku","supplier_name","supplier_url","supplier_id","source","last_updated_at","price_last_scraped_at","created_at","updated_at"],"title":"PriceBookItemResponse"},"PriceBookItemUpdate":{"properties":{"name":{"anyOf":[{"type":"string","maxLength":500,"minLength":1},{"type":"null"}],"title":"Name"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"category":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Category"},"unit":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Unit"},"unit_price":{"anyOf":[{"type":"number","minimum":0.0},{"type":"null"}],"title":"Unit Price"},"sku":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Sku"},"supplier_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Supplier Name"},"supplier_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Supplier Url"},"supplier_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Supplier Id"}},"type":"object","title":"PriceBookItemUpdate"},"PriceBookSource":{"type":"string","enum":["manual","supplier_search","scraped"],"title":"PriceBookSource"},"PriceHistoryPointResponse":{"properties":{"recorded_at":{"type":"string","format":"date-time","title":"Recorded At"},"price_ex_vat":{"type":"number","title":"Price Ex Vat"},"supplier_key":{"type":"string","title":"Supplier Key"}},"type":"object","required":["recorded_at","price_ex_vat","supplier_key"],"title":"PriceHistoryPointResponse"},"PriceRange":{"properties":{"low_pence":{"type":"integer","title":"Low Pence"},"mid_pence":{"type":"integer","title":"Mid Pence"},"high_pence":{"type":"integer","title":"High Pence"}},"type":"object","required":["low_pence","mid_pence","high_pence"],"title":"PriceRange"},"PriceTrendResponse":{"properties":{"direction":{"type":"string","title":"Direction"},"change_pct_4w":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Change Pct 4W"},"change_pct_12w":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Change Pct 12W"},"lowest_price":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Lowest Price"},"highest_price":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Highest Price"},"cheapest_supplier":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cheapest Supplier"},"ai_summary":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Ai Summary"},"week_start":{"type":"string","format":"date","title":"Week Start"}},"type":"object","required":["direction","week_start"],"title":"PriceTrendResponse"},"PricingConfigUpdate":{"properties":{"label":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Label"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"price_pence":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Price Pence"},"stripe_price_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Stripe Price Id"},"is_active":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Active"}},"type":"object","title":"PricingConfigUpdate"},"ProfileScoreResponse":{"properties":{"score":{"type":"integer","title":"Score"},"band":{"additionalProperties":{"type":"string"},"type":"object","title":"Band"},"breakdown":{"additionalProperties":{"type":"boolean"},"type":"object","title":"Breakdown"}},"type":"object","required":["score","band","breakdown"],"title":"ProfileScoreResponse"},"ProgressCreateRequest":{"properties":{"listing_id":{"type":"string","format":"uuid","title":"Listing Id"},"title":{"type":"string","title":"Title"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"photos":{"items":{"type":"string"},"type":"array","title":"Photos"},"stage":{"type":"string","enum":["before","during","after"],"title":"Stage"}},"type":"object","required":["listing_id","title","photos","stage"],"title":"ProgressCreateRequest"},"ProgressResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"listing_id":{"type":"string","format":"uuid","title":"Listing Id"},"profile_id":{"type":"string","format":"uuid","title":"Profile Id"},"title":{"type":"string","title":"Title"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"photos":{"items":{"type":"string"},"type":"array","title":"Photos"},"stage":{"type":"string","title":"Stage"},"created_at":{"type":"string","title":"Created At"}},"type":"object","required":["id","listing_id","profile_id","title","photos","stage","created_at"],"title":"ProgressResponse"},"PropertyCreate":{"properties":{"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name"},"address_line1":{"type":"string","maxLength":255,"minLength":1,"title":"Address Line1"},"address_line2":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Address Line2"},"city":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"City"},"postcode":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Postcode"},"property_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Property Type"},"client_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Client Id"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"}},"type":"object","required":["address_line1"],"title":"PropertyCreate"},"PropertyResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"company_id":{"type":"string","format":"uuid","title":"Company Id"},"reference":{"type":"string","title":"Reference"},"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name"},"address_line1":{"type":"string","title":"Address Line1"},"address_line2":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Address Line2"},"city":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"City"},"postcode":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Postcode"},"property_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Property Type"},"client_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Client Id"},"report_token":{"type":"string","title":"Report Token"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"is_active":{"type":"boolean","title":"Is Active"},"open_repairs":{"type":"integer","title":"Open Repairs","default":0},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"}},"type":"object","required":["id","company_id","reference","name","address_line1","address_line2","city","postcode","property_type","client_id","report_token","notes","is_active","created_at","updated_at"],"title":"PropertyResponse"},"PropertyUpdate":{"properties":{"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name"},"address_line1":{"anyOf":[{"type":"string","maxLength":255,"minLength":1},{"type":"null"}],"title":"Address Line1"},"address_line2":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Address Line2"},"city":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"City"},"postcode":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Postcode"},"property_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Property Type"},"client_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Client Id"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"is_active":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Active"}},"type":"object","title":"PropertyUpdate"},"PublicSignPageResponse":{"properties":{"document_title":{"type":"string","title":"Document Title"},"document_html":{"type":"string","title":"Document Html"},"status":{"type":"string","title":"Status"},"expires_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Expires At"}},"type":"object","required":["document_title","document_html","status"],"title":"PublicSignPageResponse"},"PunchListCreate":{"properties":{"job_id":{"type":"string","format":"uuid","title":"Job Id"},"title":{"type":"string","title":"Title"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"}},"type":"object","required":["job_id","title"],"title":"PunchListCreate"},"PunchListResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"company_id":{"type":"string","format":"uuid","title":"Company Id"},"job_id":{"type":"string","format":"uuid","title":"Job Id"},"title":{"type":"string","title":"Title"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"status":{"type":"string","title":"Status"},"created_by_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Created By Id"},"closed_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Closed At"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"defect_count":{"type":"integer","title":"Defect Count","default":0},"open_count":{"type":"integer","title":"Open Count","default":0}},"type":"object","required":["id","company_id","job_id","title","description","status","created_by_id","closed_at","created_at"],"title":"PunchListResponse"},"PunchListUpdate":{"properties":{"title":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Title"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Status"}},"type":"object","title":"PunchListUpdate"},"PushSubscribeRequest":{"properties":{"endpoint":{"type":"string","title":"Endpoint"},"p256dh":{"type":"string","title":"P256Dh"},"auth":{"type":"string","title":"Auth"}},"type":"object","required":["endpoint","p256dh","auth"],"title":"PushSubscribeRequest"},"PushToQuoteBody":{"properties":{"quote_id":{"type":"string","format":"uuid","title":"Quote Id"}},"type":"object","required":["quote_id"],"title":"PushToQuoteBody"},"QAChecklistCreate":{"properties":{"job_id":{"type":"string","format":"uuid","title":"Job Id"},"name":{"type":"string","title":"Name"},"trade":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Trade"},"location":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Location"},"inspector_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Inspector Name"},"inspection_date":{"type":"string","format":"date","title":"Inspection Date"},"template_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Template Id"}},"type":"object","required":["job_id","name","inspection_date"],"title":"QAChecklistCreate"},"QAChecklistDetail":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"job_id":{"type":"string","format":"uuid","title":"Job Id"},"checklist_number":{"type":"integer","title":"Checklist Number"},"name":{"type":"string","title":"Name"},"trade":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Trade"},"location":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Location"},"inspection_date":{"type":"string","format":"date","title":"Inspection Date"},"status":{"type":"string","title":"Status"},"pass_count":{"type":"integer","title":"Pass Count"},"fail_count":{"type":"integer","title":"Fail Count"},"na_count":{"type":"integer","title":"Na Count"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"company_id":{"type":"string","format":"uuid","title":"Company Id"},"template_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Template Id"},"inspector_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Inspector Name"},"sign_off_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Sign Off Name"},"sign_off_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Sign Off Date"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"items":{"items":{"$ref":"#/components/schemas/QAChecklistItemResponse"},"type":"array","title":"Items"},"job_number":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Job Number"},"job_title":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Job Title"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"}},"type":"object","required":["id","job_id","checklist_number","name","trade","location","inspection_date","status","pass_count","fail_count","na_count","created_at","company_id","template_id","inspector_name","sign_off_name","sign_off_date","notes","items","job_number","job_title","updated_at"],"title":"QAChecklistDetail"},"QAChecklistItemResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"template_item_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Template Item Id"},"position":{"type":"integer","title":"Position"},"description":{"type":"string","title":"Description"},"category":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Category"},"result":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Result"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"photo_path":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Photo Path"},"photo_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Photo Url"}},"type":"object","required":["id","template_item_id","position","description","category","result","notes","photo_path"],"title":"QAChecklistItemResponse"},"QAChecklistItemUpdate":{"properties":{"result":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Result"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"}},"type":"object","title":"QAChecklistItemUpdate"},"QAChecklistSummary":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"job_id":{"type":"string","format":"uuid","title":"Job Id"},"checklist_number":{"type":"integer","title":"Checklist Number"},"name":{"type":"string","title":"Name"},"trade":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Trade"},"location":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Location"},"inspection_date":{"type":"string","format":"date","title":"Inspection Date"},"status":{"type":"string","title":"Status"},"pass_count":{"type":"integer","title":"Pass Count"},"fail_count":{"type":"integer","title":"Fail Count"},"na_count":{"type":"integer","title":"Na Count"},"created_at":{"type":"string","format":"date-time","title":"Created At"}},"type":"object","required":["id","job_id","checklist_number","name","trade","location","inspection_date","status","pass_count","fail_count","na_count","created_at"],"title":"QAChecklistSummary"},"QAChecklistUpdate":{"properties":{"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name"},"trade":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Trade"},"location":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Location"},"inspector_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Inspector Name"},"inspection_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Inspection Date"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"}},"type":"object","title":"QAChecklistUpdate"},"QATemplateCreate":{"properties":{"name":{"type":"string","title":"Name"},"trade":{"type":"string","title":"Trade"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"items":{"items":{"$ref":"#/components/schemas/QATemplateItemCreate"},"type":"array","title":"Items","default":[]}},"type":"object","required":["name","trade"],"title":"QATemplateCreate"},"QATemplateDetail":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"company_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Company Id"},"trade":{"type":"string","title":"Trade"},"name":{"type":"string","title":"Name"},"is_system":{"type":"boolean","title":"Is System"},"item_count":{"type":"integer","title":"Item Count"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"items":{"items":{"$ref":"#/components/schemas/QATemplateItemResponse"},"type":"array","title":"Items"}},"type":"object","required":["id","company_id","trade","name","is_system","item_count","description","items"],"title":"QATemplateDetail"},"QATemplateItemCreate":{"properties":{"description":{"type":"string","title":"Description"},"category":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Category"},"required":{"type":"boolean","title":"Required","default":true}},"type":"object","required":["description"],"title":"QATemplateItemCreate"},"QATemplateItemResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"position":{"type":"integer","title":"Position"},"description":{"type":"string","title":"Description"},"category":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Category"},"required":{"type":"boolean","title":"Required"}},"type":"object","required":["id","position","description","category","required"],"title":"QATemplateItemResponse"},"QATemplateSummary":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"company_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Company Id"},"trade":{"type":"string","title":"Trade"},"name":{"type":"string","title":"Name"},"is_system":{"type":"boolean","title":"Is System"},"item_count":{"type":"integer","title":"Item Count"}},"type":"object","required":["id","company_id","trade","name","is_system","item_count"],"title":"QATemplateSummary"},"QATemplateUpdate":{"properties":{"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name"},"trade":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Trade"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"}},"type":"object","title":"QATemplateUpdate"},"QRRAMSAcceptRequest":{"properties":{"worker_name":{"type":"string","title":"Worker Name"},"person_company":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Person Company"}},"type":"object","required":["worker_name"],"title":"QRRAMSAcceptRequest"},"QRRAMSResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"title":{"type":"string","title":"Title"},"reference":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Reference"},"version":{"type":"integer","title":"Version"},"scope_of_works":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Scope Of Works"},"hazards":{"items":{},"type":"array","title":"Hazards","default":[]},"control_measures":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Control Measures"},"method_statement":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Method Statement"},"ppe_required":{"items":{},"type":"array","title":"Ppe Required","default":[]},"emergency_arrangements":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Emergency Arrangements"}},"type":"object","required":["id","title","version"],"title":"QRRAMSResponse","description":"The job's current RAMS version, rendered read-only on the scan page."},"QRScanInfoResponse":{"properties":{"job_name":{"type":"string","title":"Job Name"},"job_number":{"type":"string","title":"Job Number"},"company_name":{"type":"string","title":"Company Name"},"radius_metres":{"type":"integer","title":"Radius Metres"},"gate_induction":{"type":"string","title":"Gate Induction","default":"off"},"gate_cscs":{"type":"string","title":"Gate Cscs","default":"off"},"gate_rams":{"type":"string","title":"Gate Rams","default":"off"},"has_active_rams":{"type":"boolean","title":"Has Active Rams","default":false}},"type":"object","required":["job_name","job_number","company_name","radius_metres"],"title":"QRScanInfoResponse","description":"Public info returned when a worker loads the scan page."},"QRScanRequest":{"properties":{"worker_name":{"type":"string","title":"Worker Name"},"latitude":{"type":"number","title":"Latitude"},"longitude":{"type":"number","title":"Longitude"},"action":{"type":"string","enum":["in","out"],"title":"Action"},"break_minutes":{"type":"integer","maximum":1440.0,"minimum":0.0,"title":"Break Minutes","default":0}},"type":"object","required":["worker_name","latitude","longitude","action"],"title":"QRScanRequest"},"QRScanResponse":{"properties":{"message":{"type":"string","title":"Message"},"action":{"type":"string","title":"Action"},"attendance_record_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Attendance Record Id"},"timesheet_created":{"type":"boolean","title":"Timesheet Created","default":false},"warnings":{"items":{"type":"string"},"type":"array","title":"Warnings","default":[]},"checks":{"items":{"type":"object"},"type":"array","title":"Checks","default":[]}},"type":"object","required":["message","action"],"title":"QRScanResponse"},"QualificationCreate":{"properties":{"worker_id":{"type":"string","format":"uuid","title":"Worker Id"},"qualification_type":{"$ref":"#/components/schemas/QualificationType"},"card_number":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Card Number"},"issue_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Issue Date"},"expiry_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Expiry Date"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"}},"type":"object","required":["worker_id","qualification_type"],"title":"QualificationCreate"},"QualificationResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"worker_id":{"type":"string","format":"uuid","title":"Worker Id"},"worker_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Worker Name"},"qualification_type":{"$ref":"#/components/schemas/QualificationType"},"card_number":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Card Number"},"issue_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Issue Date"},"expiry_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Expiry Date"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"is_active":{"type":"boolean","title":"Is Active"},"days_until_expiry":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Days Until Expiry"},"cscs_verified_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Cscs Verified At"},"cscs_verification_status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cscs Verification Status"},"document_path":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Document Path"},"document_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Document Name"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"}},"type":"object","required":["id","worker_id","qualification_type","card_number","issue_date","expiry_date","notes","is_active","created_at","updated_at"],"title":"QualificationResponse"},"QualificationSummary":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"qualification_type":{"$ref":"#/components/schemas/QualificationType"},"card_number":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Card Number"},"issue_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Issue Date"},"expiry_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Expiry Date"},"is_active":{"type":"boolean","title":"Is Active"},"document_path":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Document Path"},"document_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Document Name"}},"type":"object","required":["id","qualification_type","expiry_date","is_active"],"title":"QualificationSummary"},"QualificationType":{"type":"string","enum":["cscs","cpcs","smsts","sssts","first_aid","pasma","ipaf","asbestos","ecs","npors","gas_safe","eighteenth_edition","cg_2391","face_fit","manual_handling","working_at_height","confined_space","abrasive_wheels","citb_hse_test","fire_marshal","other"],"title":"QualificationType"},"QualificationUpdate":{"properties":{"qualification_type":{"anyOf":[{"$ref":"#/components/schemas/QualificationType"},{"type":"null"}]},"card_number":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Card Number"},"issue_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Issue Date"},"expiry_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Expiry Date"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"is_active":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Active"}},"type":"object","title":"QualificationUpdate"},"QuickApplyDefaultsResponse":{"properties":{"suggested_amount":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Suggested Amount"},"default_message":{"type":"string","title":"Default Message"},"line_items":{"items":{"type":"object"},"type":"array","title":"Line Items"}},"type":"object","required":["suggested_amount","default_message","line_items"],"title":"QuickApplyDefaultsResponse"},"QuoteConversionMonth":{"properties":{"month":{"type":"string","title":"Month"},"accepted":{"type":"integer","title":"Accepted"},"lost":{"type":"integer","title":"Lost"},"win_rate":{"type":"number","title":"Win Rate"},"avg_won_value":{"type":"number","title":"Avg Won Value"},"avg_days_to_acceptance":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Avg Days To Acceptance"}},"type":"object","required":["month","accepted","lost","win_rate","avg_won_value","avg_days_to_acceptance"],"title":"QuoteConversionMonth"},"QuoteConversionResponse":{"properties":{"months":{"items":{"$ref":"#/components/schemas/QuoteConversionMonth"},"type":"array","title":"Months"},"overall_win_rate":{"type":"number","title":"Overall Win Rate"},"overall_avg_value":{"type":"number","title":"Overall Avg Value"}},"type":"object","required":["months","overall_win_rate","overall_avg_value"],"title":"QuoteConversionResponse"},"QuoteCreateRequest":{"properties":{"title":{"type":"string","maxLength":500,"minLength":1,"title":"Title"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"client_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Client Id"},"tender_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Tender Id"},"tax_rate":{"type":"number","maximum":100.0,"minimum":0.0,"title":"Tax Rate","default":20.0},"valid_until":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Valid Until"},"site_address":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Site Address"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"terms":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Terms"},"line_items":{"items":{"$ref":"#/components/schemas/QuoteLineItemCreate"},"type":"array","title":"Line Items","default":[]},"currency":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Currency"},"deposit_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Deposit Type"},"deposit_value":{"anyOf":[{"type":"number","minimum":0.0},{"type":"null"}],"title":"Deposit Value"}},"type":"object","required":["title"],"title":"QuoteCreateRequest"},"QuoteFollowUpResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"quote_id":{"type":"string","format":"uuid","title":"Quote Id"},"step":{"type":"integer","title":"Step"},"kind":{"type":"string","title":"Kind"},"recipient":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Recipient"},"sent_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Sent At"},"error":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error"},"created_at":{"type":"string","format":"date-time","title":"Created At"}},"type":"object","required":["id","quote_id","step","kind","recipient","sent_at","error","created_at"],"title":"QuoteFollowUpResponse"},"QuoteFollowUpSettingsResponse":{"properties":{"enabled":{"type":"boolean","title":"Enabled"},"follow_up_days":{"items":{"type":"integer"},"type":"array","title":"Follow Up Days"},"expiry_warning_days":{"type":"integer","title":"Expiry Warning Days"},"custom_message":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Custom Message"}},"type":"object","required":["enabled","follow_up_days","expiry_warning_days"],"title":"QuoteFollowUpSettingsResponse"},"QuoteFollowUpSettingsUpdate":{"properties":{"enabled":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Enabled"},"follow_up_days":{"anyOf":[{"items":{"type":"integer"},"type":"array"},{"type":"null"}],"title":"Follow Up Days"},"expiry_warning_days":{"anyOf":[{"type":"integer","maximum":60.0,"minimum":0.0},{"type":"null"}],"title":"Expiry Warning Days"},"custom_message":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Custom Message"}},"type":"object","title":"QuoteFollowUpSettingsUpdate"},"QuoteLineItemCreate":{"properties":{"description":{"type":"string","minLength":1,"title":"Description"},"quantity":{"type":"number","minimum":0.0,"title":"Quantity","default":1.0},"unit":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Unit"},"unit_price":{"type":"number","minimum":0.0,"title":"Unit Price","default":0.0},"category":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Category"},"sort_order":{"type":"integer","title":"Sort Order","default":0},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"is_optional":{"type":"boolean","title":"Is Optional","default":false},"is_selected":{"type":"boolean","title":"Is Selected","default":true},"option_group":{"anyOf":[{"type":"string","maxLength":100},{"type":"null"}],"title":"Option Group"}},"type":"object","required":["description"],"title":"QuoteLineItemCreate"},"QuoteLineItemResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"description":{"type":"string","title":"Description"},"quantity":{"type":"number","title":"Quantity"},"unit":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Unit"},"unit_price":{"type":"number","title":"Unit Price"},"total":{"type":"number","title":"Total"},"category":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Category"},"sort_order":{"type":"integer","title":"Sort Order"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"is_optional":{"type":"boolean","title":"Is Optional"},"is_selected":{"type":"boolean","title":"Is Selected"},"option_group":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Option Group"}},"type":"object","required":["id","description","quantity","unit","unit_price","total","category","sort_order","notes","is_optional","is_selected","option_group"],"title":"QuoteLineItemResponse"},"QuoteOptionSelection":{"properties":{"selected_line_item_ids":{"items":{"type":"string","format":"uuid"},"type":"array","title":"Selected Line Item Ids","default":[]}},"type":"object","title":"QuoteOptionSelection","description":"Which optional lines the customer wants. Omitted lines are deselected."},"QuoteResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"company_id":{"type":"string","format":"uuid","title":"Company Id"},"tender_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Tender Id"},"client_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Client Id"},"quote_number":{"type":"string","title":"Quote Number"},"title":{"type":"string","title":"Title"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"status":{"$ref":"#/components/schemas/QuoteStatus"},"subtotal":{"type":"number","title":"Subtotal"},"tax_rate":{"type":"number","title":"Tax Rate"},"tax_amount":{"type":"number","title":"Tax Amount"},"total":{"type":"number","title":"Total"},"valid_until":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Valid Until"},"sent_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Sent At"},"accepted_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Accepted At"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"terms":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Terms"},"site_address":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Site Address"},"is_archived":{"type":"boolean","title":"Is Archived"},"custom_fields":{"type":"object","title":"Custom Fields"},"currency":{"type":"string","title":"Currency"},"deposit_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Deposit Type"},"deposit_value":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Deposit Value"},"deposit_invoice_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Deposit Invoice Id"},"deposit_net":{"type":"number","title":"Deposit Net","default":0.0},"line_items":{"items":{"$ref":"#/components/schemas/QuoteLineItemResponse"},"type":"array","title":"Line Items"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"}},"type":"object","required":["id","company_id","tender_id","client_id","quote_number","title","description","status","subtotal","tax_rate","tax_amount","total","valid_until","sent_at","accepted_at","notes","terms","site_address","is_archived","custom_fields","currency","line_items","created_at","updated_at"],"title":"QuoteResponse"},"QuoteStatus":{"type":"string","enum":["draft","sent","accepted","declined","expired","converted"],"title":"QuoteStatus"},"QuoteTemplateCreate":{"properties":{"name":{"type":"string","maxLength":100,"minLength":1,"title":"Name"},"title":{"type":"string","maxLength":500,"title":"Title","default":""},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"tax_rate":{"type":"number","maximum":100.0,"minimum":0.0,"title":"Tax Rate","default":20.0},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"terms":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Terms"},"site_address":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Site Address"},"custom_fields":{"type":"object","title":"Custom Fields"},"line_items":{"items":{"$ref":"#/components/schemas/QuoteTemplateLineItemIn"},"type":"array","title":"Line Items"}},"type":"object","required":["name"],"title":"QuoteTemplateCreate"},"QuoteTemplateLineItemIn":{"properties":{"description":{"type":"string","minLength":1,"title":"Description"},"quantity":{"type":"number","minimum":0.0,"title":"Quantity","default":1.0},"unit":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Unit"},"unit_price":{"type":"number","minimum":0.0,"title":"Unit Price","default":0.0},"category":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Category"},"sort_order":{"type":"integer","title":"Sort Order","default":0}},"type":"object","required":["description"],"title":"QuoteTemplateLineItemIn"},"QuoteTemplateLineItemOut":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"description":{"type":"string","title":"Description"},"quantity":{"type":"number","title":"Quantity"},"unit":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Unit"},"unit_price":{"type":"number","title":"Unit Price"},"category":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Category"},"sort_order":{"type":"integer","title":"Sort Order"}},"type":"object","required":["id","description","quantity","unit","unit_price","category","sort_order"],"title":"QuoteTemplateLineItemOut"},"QuoteTemplateResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"company_id":{"type":"string","format":"uuid","title":"Company Id"},"name":{"type":"string","title":"Name"},"title":{"type":"string","title":"Title"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"tax_rate":{"type":"number","title":"Tax Rate"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"terms":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Terms"},"site_address":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Site Address"},"custom_fields":{"type":"object","title":"Custom Fields"},"is_active":{"type":"boolean","title":"Is Active"},"line_items":{"items":{"$ref":"#/components/schemas/QuoteTemplateLineItemOut"},"type":"array","title":"Line Items"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"}},"type":"object","required":["id","company_id","name","title","description","tax_rate","notes","terms","site_address","custom_fields","is_active","line_items","created_at","updated_at"],"title":"QuoteTemplateResponse"},"QuoteTemplateUpdate":{"properties":{"name":{"anyOf":[{"type":"string","maxLength":100,"minLength":1},{"type":"null"}],"title":"Name"},"title":{"anyOf":[{"type":"string","maxLength":500},{"type":"null"}],"title":"Title"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"tax_rate":{"anyOf":[{"type":"number","maximum":100.0,"minimum":0.0},{"type":"null"}],"title":"Tax Rate"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"terms":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Terms"},"site_address":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Site Address"},"custom_fields":{"anyOf":[{"type":"object"},{"type":"null"}],"title":"Custom Fields"},"is_active":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Active"},"line_items":{"anyOf":[{"items":{"$ref":"#/components/schemas/QuoteTemplateLineItemIn"},"type":"array"},{"type":"null"}],"title":"Line Items"}},"type":"object","title":"QuoteTemplateUpdate"},"QuoteUpdateRequest":{"properties":{"title":{"anyOf":[{"type":"string","maxLength":500,"minLength":1},{"type":"null"}],"title":"Title"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"client_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Client Id"},"tax_rate":{"anyOf":[{"type":"number","maximum":100.0,"minimum":0.0},{"type":"null"}],"title":"Tax Rate"},"valid_until":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Valid Until"},"site_address":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Site Address"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"terms":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Terms"},"line_items":{"anyOf":[{"items":{"$ref":"#/components/schemas/QuoteLineItemCreate"},"type":"array"},{"type":"null"}],"title":"Line Items"},"deposit_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Deposit Type"},"deposit_value":{"anyOf":[{"type":"number","minimum":0.0},{"type":"null"}],"title":"Deposit Value"}},"type":"object","title":"QuoteUpdateRequest"},"RAMSCreate":{"properties":{"title":{"type":"string","maxLength":500,"minLength":1,"title":"Title"},"job_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Job Id"},"reference":{"anyOf":[{"type":"string","maxLength":50},{"type":"null"}],"title":"Reference"},"author_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Author Name"},"scope_of_works":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Scope Of Works"},"hazards":{"items":{"$ref":"#/components/schemas/RAMSHazard"},"type":"array","title":"Hazards","default":[]},"control_measures":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Control Measures"},"method_statement":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Method Statement"},"ppe_required":{"items":{"type":"string"},"type":"array","title":"Ppe Required","default":[]},"emergency_arrangements":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Emergency Arrangements"},"review_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Review Date"}},"type":"object","required":["title"],"title":"RAMSCreate"},"RAMSHazard":{"properties":{"hazard":{"type":"string","title":"Hazard"},"who_at_risk":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Who At Risk"},"likelihood":{"anyOf":[{"type":"integer","maximum":5.0,"minimum":1.0},{"type":"null"}],"title":"Likelihood"},"severity":{"anyOf":[{"type":"integer","maximum":5.0,"minimum":1.0},{"type":"null"}],"title":"Severity"},"control_measures":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Control Measures"},"residual_rating":{"anyOf":[{"type":"integer","maximum":25.0,"minimum":1.0},{"type":"null"}],"title":"Residual Rating"}},"type":"object","required":["hazard"],"title":"RAMSHazard"},"RAMSResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"company_id":{"type":"string","format":"uuid","title":"Company Id"},"job_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Job Id"},"rams_group_id":{"type":"string","format":"uuid","title":"Rams Group Id"},"supersedes_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Supersedes Id"},"reference":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Reference"},"title":{"type":"string","title":"Title"},"version":{"type":"integer","title":"Version"},"author_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Author Name"},"scope_of_works":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Scope Of Works"},"hazards":{"items":{},"type":"array","title":"Hazards"},"control_measures":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Control Measures"},"method_statement":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Method Statement"},"ppe_required":{"items":{},"type":"array","title":"Ppe Required"},"emergency_arrangements":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Emergency Arrangements"},"review_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Review Date"},"status":{"$ref":"#/components/schemas/RAMSStatus"},"issued_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Issued At"},"superseded_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Superseded At"},"signoffs":{"items":{"$ref":"#/components/schemas/RAMSSignoffResponse"},"type":"array","title":"Signoffs","default":[]},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"}},"type":"object","required":["id","company_id","job_id","rams_group_id","supersedes_id","reference","title","version","author_name","scope_of_works","hazards","control_measures","method_statement","ppe_required","emergency_arrangements","review_date","status","issued_at","superseded_at","created_at","updated_at"],"title":"RAMSResponse"},"RAMSSignoffCreate":{"properties":{"person_name":{"type":"string","maxLength":255,"minLength":1,"title":"Person Name"},"person_company":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Person Company"},"person_role":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Person Role"},"worker_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Worker Id"},"method":{"$ref":"#/components/schemas/SignoffMethod","default":"in_app"},"signature":{"anyOf":[{"type":"object"},{"type":"null"}],"title":"Signature"}},"type":"object","required":["person_name"],"title":"RAMSSignoffCreate"},"RAMSSignoffResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"rams_id":{"type":"string","format":"uuid","title":"Rams Id"},"worker_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Worker Id"},"person_name":{"type":"string","title":"Person Name"},"person_company":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Person Company"},"person_role":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Person Role"},"signed_at":{"type":"string","format":"date-time","title":"Signed At"},"method":{"$ref":"#/components/schemas/SignoffMethod"},"created_at":{"type":"string","format":"date-time","title":"Created At"}},"type":"object","required":["id","rams_id","worker_id","person_name","person_company","person_role","signed_at","method","created_at"],"title":"RAMSSignoffResponse"},"RAMSStatus":{"type":"string","enum":["draft","issued","superseded","archived"],"title":"RAMSStatus"},"RAMSUpdate":{"properties":{"title":{"anyOf":[{"type":"string","maxLength":500,"minLength":1},{"type":"null"}],"title":"Title"},"reference":{"anyOf":[{"type":"string","maxLength":50},{"type":"null"}],"title":"Reference"},"author_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Author Name"},"scope_of_works":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Scope Of Works"},"hazards":{"anyOf":[{"items":{"$ref":"#/components/schemas/RAMSHazard"},"type":"array"},{"type":"null"}],"title":"Hazards"},"control_measures":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Control Measures"},"method_statement":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Method Statement"},"ppe_required":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Ppe Required"},"emergency_arrangements":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Emergency Arrangements"},"review_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Review Date"}},"type":"object","title":"RAMSUpdate"},"RFICreate":{"properties":{"title":{"type":"string","maxLength":255,"minLength":1,"title":"Title"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"urgency":{"type":"string","title":"Urgency","default":"medium"},"job_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Job Id"},"tender_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Tender Id"},"recipient_user_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Recipient User Id"},"recipient_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Recipient Name"},"recipient_type":{"type":"string","title":"Recipient Type","default":"client"},"recipient_email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Recipient Email"},"due_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Due Date"}},"type":"object","required":["title"],"title":"RFICreate"},"RFIDetail":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"company_id":{"type":"string","format":"uuid","title":"Company Id"},"job_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Job Id"},"tender_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Tender Id"},"rfi_number":{"type":"integer","title":"Rfi Number"},"title":{"type":"string","title":"Title"},"urgency":{"type":"string","title":"Urgency"},"status":{"type":"string","title":"Status"},"recipient_user_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Recipient User Id"},"recipient_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Recipient Name"},"recipient_type":{"type":"string","title":"Recipient Type"},"due_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Due Date"},"is_overdue":{"type":"boolean","title":"Is Overdue","default":false},"response_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Response Date"},"programme_impact_days":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Programme Impact Days"},"cost_impact":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Cost Impact"},"attachment_count":{"type":"integer","title":"Attachment Count","default":0},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"recipient_email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Recipient Email"},"sent_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Sent Date"},"response":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Response"},"attachments":{"items":{"type":"object"},"type":"array","title":"Attachments","default":[]},"job_number":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Job Number"},"job_title":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Job Title"},"tender_reference":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Tender Reference"}},"type":"object","required":["id","company_id","job_id","tender_id","rfi_number","title","urgency","status","recipient_name","recipient_type","due_date","response_date","programme_impact_days","cost_impact","created_at","updated_at","description","recipient_email","sent_date","response"],"title":"RFIDetail"},"RFISummary":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"company_id":{"type":"string","format":"uuid","title":"Company Id"},"job_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Job Id"},"tender_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Tender Id"},"rfi_number":{"type":"integer","title":"Rfi Number"},"title":{"type":"string","title":"Title"},"urgency":{"type":"string","title":"Urgency"},"status":{"type":"string","title":"Status"},"recipient_user_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Recipient User Id"},"recipient_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Recipient Name"},"recipient_type":{"type":"string","title":"Recipient Type"},"due_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Due Date"},"is_overdue":{"type":"boolean","title":"Is Overdue","default":false},"response_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Response Date"},"programme_impact_days":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Programme Impact Days"},"cost_impact":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Cost Impact"},"attachment_count":{"type":"integer","title":"Attachment Count","default":0},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"}},"type":"object","required":["id","company_id","job_id","tender_id","rfi_number","title","urgency","status","recipient_name","recipient_type","due_date","response_date","programme_impact_days","cost_impact","created_at","updated_at"],"title":"RFISummary"},"RFIUpdate":{"properties":{"title":{"anyOf":[{"type":"string","maxLength":255,"minLength":1},{"type":"null"}],"title":"Title"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"urgency":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Urgency"},"job_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Job Id"},"tender_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Tender Id"},"recipient_user_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Recipient User Id"},"recipient_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Recipient Name"},"recipient_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Recipient Type"},"recipient_email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Recipient Email"},"due_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Due Date"}},"type":"object","title":"RFIUpdate"},"RFQCreate":{"properties":{"title":{"type":"string","maxLength":500,"minLength":1,"title":"Title"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"tender_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Tender Id"},"quote_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Quote Id"},"due_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Due Date"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"line_items":{"items":{"$ref":"#/components/schemas/RFQLineItemCreate"},"type":"array","title":"Line Items","default":[]}},"type":"object","required":["title"],"title":"RFQCreate"},"RFQInvitationResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"rfq_id":{"type":"string","format":"uuid","title":"Rfq Id"},"subcontractor_id":{"type":"string","format":"uuid","title":"Subcontractor Id"},"subcontractor":{"$ref":"#/components/schemas/SubcontractorResponse"},"status":{"$ref":"#/components/schemas/InvitationStatus"},"total_price":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Total Price"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"submitted_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Submitted At"},"accepted_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Accepted At"},"line_items":{"items":{"$ref":"#/components/schemas/InvitationLineItemResponse"},"type":"array","title":"Line Items","default":[]},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"}},"type":"object","required":["id","rfq_id","subcontractor_id","subcontractor","status","total_price","notes","submitted_at","accepted_at","created_at","updated_at"],"title":"RFQInvitationResponse"},"RFQLineItemCreate":{"properties":{"description":{"type":"string","minLength":1,"title":"Description"},"quantity":{"type":"number","title":"Quantity","default":1.0},"unit":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Unit"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"sort_order":{"type":"integer","title":"Sort Order","default":0}},"type":"object","required":["description"],"title":"RFQLineItemCreate"},"RFQLineItemResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"rfq_id":{"type":"string","format":"uuid","title":"Rfq Id"},"description":{"type":"string","title":"Description"},"quantity":{"type":"number","title":"Quantity"},"unit":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Unit"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"sort_order":{"type":"integer","title":"Sort Order"}},"type":"object","required":["id","rfq_id","description","quantity","unit","notes","sort_order"],"title":"RFQLineItemResponse"},"RFQResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"company_id":{"type":"string","format":"uuid","title":"Company Id"},"rfq_number":{"type":"string","title":"Rfq Number"},"title":{"type":"string","title":"Title"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"tender_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Tender Id"},"quote_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Quote Id"},"due_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Due Date"},"status":{"$ref":"#/components/schemas/RFQStatus"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"line_items":{"items":{"$ref":"#/components/schemas/RFQLineItemResponse"},"type":"array","title":"Line Items","default":[]},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"}},"type":"object","required":["id","company_id","rfq_number","title","description","tender_id","quote_id","due_date","status","notes","created_at","updated_at"],"title":"RFQResponse"},"RFQStatus":{"type":"string","enum":["draft","sent","closed"],"title":"RFQStatus"},"RFQUpdate":{"properties":{"title":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Title"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"tender_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Tender Id"},"quote_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Quote Id"},"due_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Due Date"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"status":{"anyOf":[{"$ref":"#/components/schemas/RFQStatus"},{"type":"null"}]}},"type":"object","title":"RFQUpdate"},"RecordInspectionRequest":{"properties":{"inspection_date":{"type":"string","format":"date","title":"Inspection Date"},"certificate_reference":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Certificate Reference"},"certificate_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Certificate Url"},"inspector_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Inspector Name"}},"type":"object","required":["inspection_date"],"title":"RecordInspectionRequest"},"RecordPaymentRequest":{"properties":{"amount":{"type":"number","exclusiveMinimum":0.0,"title":"Amount"},"payment_date":{"type":"string","format":"date","title":"Payment Date"},"method":{"$ref":"#/components/schemas/PaymentMethod","default":"bank_transfer"},"reference":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Reference"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"}},"type":"object","required":["amount","payment_date"],"title":"RecordPaymentRequest"},"RecurringInvoiceIn":{"properties":{"client_id":{"type":"string","format":"uuid","title":"Client Id"},"job_id":{"type":"string","format":"uuid","title":"Job Id"},"title":{"type":"string","title":"Title"},"frequency":{"$ref":"#/components/schemas/InvoiceFrequency"},"next_due_date":{"type":"string","format":"date","title":"Next Due Date"},"line_items":{"items":{"$ref":"#/components/schemas/LineItemIn"},"type":"array","title":"Line Items","default":[]},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"}},"type":"object","required":["client_id","job_id","title","frequency","next_due_date"],"title":"RecurringInvoiceIn"},"RecurringInvoicePatch":{"properties":{"title":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Title"},"frequency":{"anyOf":[{"$ref":"#/components/schemas/InvoiceFrequency"},{"type":"null"}]},"next_due_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Next Due Date"},"line_items":{"anyOf":[{"items":{"$ref":"#/components/schemas/LineItemIn"},"type":"array"},{"type":"null"}],"title":"Line Items"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"is_active":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Active"}},"type":"object","title":"RecurringInvoicePatch"},"RefreshRequest":{"properties":{"refresh_token":{"type":"string","title":"Refresh Token"}},"type":"object","required":["refresh_token"],"title":"RefreshRequest"},"RefundRequest":{"properties":{"reference":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Reference"}},"type":"object","title":"RefundRequest"},"RegisterRequest":{"properties":{"email":{"type":"string","format":"email","title":"Email"},"password":{"type":"string","maxLength":128,"minLength":8,"title":"Password"},"first_name":{"type":"string","maxLength":100,"minLength":1,"title":"First Name"},"last_name":{"type":"string","maxLength":100,"minLength":1,"title":"Last Name"},"company_name":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Company Name"},"country":{"anyOf":[{"type":"string","maxLength":100},{"type":"null"}],"title":"Country"},"industry":{"anyOf":[{"type":"string","maxLength":100},{"type":"null"}],"title":"Industry"},"plan_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Plan Id"},"company_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Company Type"},"primary_trade":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Primary Trade"},"referral_source":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Referral Source"},"referral_code":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Referral Code"}},"type":"object","required":["email","password","first_name","last_name"],"title":"RegisterRequest"},"RejectIdBody":{"properties":{"reason":{"type":"string","title":"Reason"}},"type":"object","required":["reason"],"title":"RejectIdBody"},"RejectLeaveBody":{"properties":{"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"}},"type":"object","title":"RejectLeaveBody"},"RejectRequest":{"properties":{"reason":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Reason"}},"type":"object","title":"RejectRequest"},"RelatedArticle":{"properties":{"slug":{"type":"string","title":"Slug"},"title":{"type":"string","title":"Title"}},"type":"object","required":["slug","title"],"title":"RelatedArticle"},"ReorderRow":{"properties":{"item_id":{"type":"string","format":"uuid","title":"Item Id"},"sku":{"type":"string","title":"Sku"},"name":{"type":"string","title":"Name"},"total_quantity":{"type":"number","title":"Total Quantity"},"reorder_level":{"type":"integer","title":"Reorder Level"},"shortfall":{"type":"number","title":"Shortfall"}},"type":"object","required":["item_id","sku","name","total_quantity","reorder_level","shortfall"],"title":"ReorderRow"},"RepairAssign":{"properties":{"assigned_contractor_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Assigned Contractor Id"},"assigned_operative":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Assigned Operative"}},"type":"object","title":"RepairAssign"},"RepairComplete":{"properties":{"resolution_notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Resolution Notes"},"cost":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Cost"}},"type":"object","title":"RepairComplete"},"RepairCreate":{"properties":{"property_id":{"type":"string","format":"uuid","title":"Property Id"},"title":{"type":"string","maxLength":500,"minLength":1,"title":"Title"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"category":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Category"},"priority":{"anyOf":[{"$ref":"#/components/schemas/RepairPriority"},{"type":"null"}]},"reporter_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Reporter Name"},"reporter_contact":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Reporter Contact"},"access_notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Notes"},"photo_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Photo Url"}},"type":"object","required":["property_id","title"],"title":"RepairCreate"},"RepairPriority":{"type":"string","enum":["emergency","urgent","routine","planned"],"title":"RepairPriority"},"RepairResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"company_id":{"type":"string","format":"uuid","title":"Company Id"},"property_id":{"type":"string","format":"uuid","title":"Property Id"},"repair_number":{"type":"string","title":"Repair Number"},"title":{"type":"string","title":"Title"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"category":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Category"},"photo_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Photo Url"},"priority":{"anyOf":[{"$ref":"#/components/schemas/RepairPriority"},{"type":"null"}]},"status":{"$ref":"#/components/schemas/RepairStatus"},"reported_via":{"$ref":"#/components/schemas/ReportedVia"},"reporter_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Reporter Name"},"reporter_contact":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Reporter Contact"},"access_notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Notes"},"reported_at":{"type":"string","format":"date-time","title":"Reported At"},"responded_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Responded At"},"completed_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Completed At"},"sla_response_due":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Sla Response Due"},"sla_completion_due":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Sla Completion Due"},"assigned_contractor_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Assigned Contractor Id"},"assigned_operative":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Assigned Operative"},"assigned_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Assigned At"},"resolution_notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Resolution Notes"},"cost":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Cost"},"linked_job_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Linked Job Id"},"linked_invoice_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Linked Invoice Id"},"response_overdue":{"type":"boolean","title":"Response Overdue","default":false},"completion_overdue":{"type":"boolean","title":"Completion Overdue","default":false},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"}},"type":"object","required":["id","company_id","property_id","repair_number","title","description","category","photo_url","priority","status","reported_via","reporter_name","reporter_contact","access_notes","reported_at","responded_at","completed_at","sla_response_due","sla_completion_due","assigned_contractor_id","assigned_operative","assigned_at","resolution_notes","cost","linked_job_id","linked_invoice_id","created_at","updated_at"],"title":"RepairResponse"},"RepairSorLineCreate":{"properties":{"sor_item_id":{"type":"string","format":"uuid","title":"Sor Item Id"},"quantity":{"type":"number","exclusiveMinimum":0.0,"title":"Quantity","default":1.0},"uplift_percent":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Uplift Percent"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"}},"type":"object","required":["sor_item_id"],"title":"RepairSorLineCreate"},"RepairSorLineResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"repair_id":{"type":"string","format":"uuid","title":"Repair Id"},"sor_item_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Sor Item Id"},"code":{"type":"string","title":"Code"},"description":{"type":"string","title":"Description"},"unit":{"$ref":"#/components/schemas/SorUnit"},"quantity":{"type":"number","title":"Quantity"},"base_rate":{"type":"number","title":"Base Rate"},"uplift_percent":{"type":"number","title":"Uplift Percent"},"line_total":{"type":"number","title":"Line Total"},"smv_minutes":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Smv Minutes"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"}},"type":"object","required":["id","repair_id","sor_item_id","code","description","unit","quantity","base_rate","uplift_percent","line_total","smv_minutes","notes"],"title":"RepairSorLineResponse"},"RepairSorSummary":{"properties":{"repair_id":{"type":"string","format":"uuid","title":"Repair Id"},"lines":{"items":{"$ref":"#/components/schemas/RepairSorLineResponse"},"type":"array","title":"Lines"},"total":{"type":"number","title":"Total"},"total_smv_minutes":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Total Smv Minutes"}},"type":"object","required":["repair_id","lines","total"],"title":"RepairSorSummary"},"RepairStatus":{"type":"string","enum":["reported","triaged","assigned","in_progress","completed","cancelled"],"title":"RepairStatus"},"RepairTriage":{"properties":{"priority":{"$ref":"#/components/schemas/RepairPriority"}},"type":"object","required":["priority"],"title":"RepairTriage"},"RepairUpdate":{"properties":{"title":{"anyOf":[{"type":"string","maxLength":500,"minLength":1},{"type":"null"}],"title":"Title"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"category":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Category"},"access_notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Notes"},"photo_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Photo Url"},"resolution_notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Resolution Notes"},"cost":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Cost"}},"type":"object","title":"RepairUpdate"},"ReplyBody":{"properties":{"body":{"type":"string","title":"Body"}},"type":"object","required":["body"],"title":"ReplyBody"},"ReportRunRequest":{"properties":{"columns":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Columns"},"filters":{"anyOf":[{"items":{"type":"object"},"type":"array"},{"type":"null"}],"title":"Filters"},"sort_by":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Sort By"},"sort_dir":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Sort Dir"},"limit":{"type":"integer","title":"Limit","default":500},"offset":{"type":"integer","title":"Offset","default":0}},"type":"object","title":"ReportRunRequest","description":"Optional overrides when running a report."},"ReportScheduleCreate":{"properties":{"report_type":{"type":"string","title":"Report Type"},"frequency":{"type":"string","title":"Frequency"},"recipients":{"items":{"type":"string"},"type":"array","title":"Recipients","default":[]}},"type":"object","required":["report_type","frequency"],"title":"ReportScheduleCreate"},"ReportScheduleResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"company_id":{"type":"string","format":"uuid","title":"Company Id"},"report_type":{"type":"string","title":"Report Type"},"frequency":{"type":"string","title":"Frequency"},"recipients":{"items":{"type":"string"},"type":"array","title":"Recipients"},"is_active":{"type":"boolean","title":"Is Active"},"last_sent_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Sent At"},"created_at":{"type":"string","format":"date-time","title":"Created At"}},"type":"object","required":["id","company_id","report_type","frequency","recipients","is_active","last_sent_at","created_at"],"title":"ReportScheduleResponse"},"ReportScheduleUpdate":{"properties":{"report_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Report Type"},"frequency":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Frequency"},"recipients":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Recipients"},"is_active":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Active"}},"type":"object","title":"ReportScheduleUpdate"},"ReportedVia":{"type":"string","enum":["staff","resident_portal"],"title":"ReportedVia"},"RescheduleRequest":{"properties":{"start_date":{"type":"string","format":"date","title":"Start Date"},"end_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"End Date"}},"type":"object","required":["start_date"],"title":"RescheduleRequest"},"ResetPasswordRequest":{"properties":{"token":{"type":"string","title":"Token"},"password":{"type":"string","maxLength":128,"minLength":8,"title":"Password"}},"type":"object","required":["token","password"],"title":"ResetPasswordRequest"},"ResidentPropertyInfo":{"properties":{"reference":{"type":"string","title":"Reference"},"address_line1":{"type":"string","title":"Address Line1"},"postcode":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Postcode"},"managed_by":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Managed By"}},"type":"object","required":["reference","address_line1","postcode"],"title":"ResidentPropertyInfo","description":"Minimal, non-sensitive property info shown on the public report page."},"ResidentReportRequest":{"properties":{"title":{"type":"string","maxLength":500,"minLength":1,"title":"Title"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"category":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Category"},"reporter_name":{"type":"string","maxLength":255,"minLength":1,"title":"Reporter Name"},"reporter_contact":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Reporter Contact"},"access_notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Notes"},"photo_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Photo Url"}},"type":"object","required":["title","reporter_name"],"title":"ResidentReportRequest"},"ResidentReportResponse":{"properties":{"repair_number":{"type":"string","title":"Repair Number"},"message":{"type":"string","title":"Message"}},"type":"object","required":["repair_number","message"],"title":"ResidentReportResponse"},"RespondRequest":{"properties":{"response":{"type":"string","title":"Response"},"response_date":{"type":"string","format":"date","title":"Response Date"},"programme_impact_days":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Programme Impact Days"},"cost_impact":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Cost Impact"}},"type":"object","required":["response","response_date"],"title":"RespondRequest"},"RetentionDashboardResponse":{"properties":{"total_held":{"type":"number","title":"Total Held"},"due_within_30_days":{"type":"number","title":"Due Within 30 Days"},"due_within_90_days":{"type":"number","title":"Due Within 90 Days"},"released_this_year":{"type":"number","title":"Released This Year"},"upcoming_releases":{"items":{"$ref":"#/components/schemas/UpcomingRetentionRelease"},"type":"array","title":"Upcoming Releases"}},"type":"object","required":["total_held","due_within_30_days","due_within_90_days","released_this_year","upcoming_releases"],"title":"RetentionDashboardResponse"},"RetentionPolicyCreate":{"properties":{"entity_type":{"type":"string","maxLength":100,"title":"Entity Type","description":"Entity type: quotes, invoices, timesheets, etc."},"retention_days":{"type":"integer","maximum":3650.0,"minimum":30.0,"title":"Retention Days","description":"Retention period in days (30-3650)"},"is_active":{"type":"boolean","title":"Is Active","default":true}},"type":"object","required":["entity_type","retention_days"],"title":"RetentionPolicyCreate"},"RetentionPolicyResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"entity_type":{"type":"string","title":"Entity Type"},"retention_days":{"type":"integer","title":"Retention Days"},"is_active":{"type":"boolean","title":"Is Active"},"created_at":{"type":"string","format":"date-time","title":"Created At"}},"type":"object","required":["id","entity_type","retention_days","is_active","created_at"],"title":"RetentionPolicyResponse"},"RetentionReleaseCreate":{"properties":{"release_date":{"type":"string","format":"date","title":"Release Date"},"release_type":{"type":"string","title":"Release Type","default":"practical_completion"},"amount":{"type":"number","exclusiveMinimum":0.0,"title":"Amount"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"}},"type":"object","required":["release_date","amount"],"title":"RetentionReleaseCreate"},"RetentionReleaseResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"company_id":{"type":"string","format":"uuid","title":"Company Id"},"job_id":{"type":"string","format":"uuid","title":"Job Id"},"invoice_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Invoice Id"},"release_date":{"type":"string","format":"date","title":"Release Date"},"release_type":{"type":"string","title":"Release Type"},"amount":{"type":"number","title":"Amount"},"total_retention_held":{"type":"number","title":"Total Retention Held"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"provider":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Provider"},"xero_invoice_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Xero Invoice Id"},"quickbooks_invoice_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Quickbooks Invoice Id"},"freshbooks_invoice_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Freshbooks Invoice Id"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"}},"type":"object","required":["id","company_id","job_id","invoice_id","release_date","release_type","amount","total_retention_held","notes","provider","xero_invoice_id","quickbooks_invoice_id","freshbooks_invoice_id","created_at","updated_at"],"title":"RetentionReleaseResponse"},"RetentionSummary":{"properties":{"total_held":{"type":"number","title":"Total Held"},"total_released":{"type":"number","title":"Total Released"},"balance":{"type":"number","title":"Balance"},"releases":{"items":{"$ref":"#/components/schemas/RetentionReleaseResponse"},"type":"array","title":"Releases"}},"type":"object","required":["total_held","total_released","balance","releases"],"title":"RetentionSummary"},"ReviewCreate":{"properties":{"profile_id":{"type":"string","format":"uuid","title":"Profile Id"},"listing_id":{"type":"string","format":"uuid","title":"Listing Id"},"rating":{"type":"integer","title":"Rating"},"body":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Body"},"direction":{"type":"string","title":"Direction","default":"poster_to_contractor"}},"type":"object","required":["profile_id","listing_id","rating"],"title":"ReviewCreate"},"ReviewResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"reviewee_profile_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Reviewee Profile Id"},"listing_id":{"type":"string","format":"uuid","title":"Listing Id"},"rating":{"type":"integer","title":"Rating"},"body":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Body"},"direction":{"type":"string","title":"Direction"},"created_at":{"type":"string","format":"date-time","title":"Created At"}},"type":"object","required":["id","reviewee_profile_id","listing_id","rating","body","direction","created_at"],"title":"ReviewResponse"},"RevisionUpdate":{"properties":{"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"issue_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Issue Date"},"reason_for_issue":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Reason For Issue"}},"type":"object","title":"RevisionUpdate","description":"Metadata corrections on a revision. The supersession state is not settable here —\nit only ever changes by issuing a newer revision or reinstating this one."},"RevokeCreditRequest":{"properties":{"company_id":{"type":"string","format":"uuid","title":"Company Id"},"amount":{"anyOf":[{"type":"number","exclusiveMinimum":0.0},{"type":"string"}],"title":"Amount"},"internal_note":{"type":"string","maxLength":2000,"minLength":1,"title":"Internal Note"}},"type":"object","required":["company_id","amount","internal_note"],"title":"RevokeCreditRequest"},"RowError":{"properties":{"row":{"type":"integer","title":"Row"},"error":{"type":"string","title":"Error"}},"type":"object","required":["row","error"],"title":"RowError"},"SSOExchangeRequest":{"properties":{"sso_token":{"type":"string","title":"Sso Token"}},"type":"object","required":["sso_token"],"title":"SSOExchangeRequest"},"SSOTokenRequest":{"properties":{"target_product":{"type":"string","title":"Target Product"}},"type":"object","required":["target_product"],"title":"SSOTokenRequest"},"SSOTokenResponse":{"properties":{"sso_token":{"type":"string","title":"Sso Token"},"redirect_url":{"type":"string","title":"Redirect Url"},"expires_in":{"type":"integer","title":"Expires In"}},"type":"object","required":["sso_token","redirect_url","expires_in"],"title":"SSOTokenResponse"},"ScenarioRequest":{"properties":{"conservative_gdv_factor":{"type":"number","title":"Conservative Gdv Factor","description":"e.g. 0.90 = 10% below base","default":0.9},"optimistic_gdv_factor":{"type":"number","title":"Optimistic Gdv Factor","description":"e.g. 1.10 = 10% above base","default":1.1}},"type":"object","title":"ScenarioRequest","description":"Request body for scenario computation."},"ScheduleAssignmentCreate":{"properties":{"job_id":{"type":"string","format":"uuid","title":"Job Id"},"user_id":{"type":"string","format":"uuid","title":"User Id"},"start_date":{"type":"string","format":"date","title":"Start Date"},"end_date":{"type":"string","format":"date","title":"End Date"},"start_time":{"anyOf":[{"type":"string","format":"time"},{"type":"null"}],"title":"Start Time"},"end_time":{"anyOf":[{"type":"string","format":"time"},{"type":"null"}],"title":"End Time"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"}},"type":"object","required":["job_id","user_id","start_date","end_date"],"title":"ScheduleAssignmentCreate"},"ScheduleAssignmentResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"job_id":{"type":"string","format":"uuid","title":"Job Id"},"user_id":{"type":"string","format":"uuid","title":"User Id"},"start_date":{"type":"string","format":"date","title":"Start Date"},"end_date":{"type":"string","format":"date","title":"End Date"},"start_time":{"anyOf":[{"type":"string","format":"time"},{"type":"null"}],"title":"Start Time"},"end_time":{"anyOf":[{"type":"string","format":"time"},{"type":"null"}],"title":"End Time"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"created_at":{"type":"string","format":"date-time","title":"Created At"}},"type":"object","required":["id","job_id","user_id","start_date","end_date","created_at"],"title":"ScheduleAssignmentResponse"},"ScheduleAssignmentUpdate":{"properties":{"job_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Job Id"},"user_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"User Id"},"start_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Start Date"},"end_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"End Date"},"start_time":{"anyOf":[{"type":"string","format":"time"},{"type":"null"}],"title":"Start Time"},"end_time":{"anyOf":[{"type":"string","format":"time"},{"type":"null"}],"title":"End Time"},"clear_times":{"type":"boolean","title":"Clear Times","default":false},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"}},"type":"object","title":"ScheduleAssignmentUpdate"},"ScheduleCreate":{"properties":{"name":{"type":"string","maxLength":255,"minLength":1,"title":"Name"},"version":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Version"},"source":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"effective_from":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Effective From"},"effective_to":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Effective To"}},"type":"object","required":["name"],"title":"ScheduleCreate"},"ScheduleGridResponse":{"properties":{"users":{"items":{"$ref":"#/components/schemas/ScheduleUserItem"},"type":"array","title":"Users"},"jobs":{"items":{"$ref":"#/components/schemas/ScheduleJobItem"},"type":"array","title":"Jobs"},"assignments":{"items":{"$ref":"#/components/schemas/ScheduleAssignmentResponse"},"type":"array","title":"Assignments"}},"type":"object","required":["users","jobs","assignments"],"title":"ScheduleGridResponse"},"ScheduleJobItem":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"title":{"type":"string","title":"Title"},"job_number":{"type":"string","title":"Job Number"},"status":{"type":"string","title":"Status"}},"type":"object","required":["id","title","job_number","status"],"title":"ScheduleJobItem"},"ScheduleResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"company_id":{"type":"string","format":"uuid","title":"Company Id"},"name":{"type":"string","title":"Name"},"version":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Version"},"source":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"effective_from":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Effective From"},"effective_to":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Effective To"},"is_active":{"type":"boolean","title":"Is Active"},"item_count":{"type":"integer","title":"Item Count","default":0},"created_at":{"type":"string","format":"date-time","title":"Created At"}},"type":"object","required":["id","company_id","name","version","source","description","effective_from","effective_to","is_active","created_at"],"title":"ScheduleResponse"},"ScheduleUserItem":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"full_name":{"type":"string","title":"Full Name"},"role":{"type":"string","title":"Role"}},"type":"object","required":["id","full_name","role"],"title":"ScheduleUserItem"},"SchemeResponse":{"properties":{"key":{"type":"string","title":"Key"},"name":{"type":"string","title":"Name"},"icon":{"type":"string","title":"Icon"}},"type":"object","required":["key","name","icon"],"title":"SchemeResponse"},"ScopeCheckRequest":{"properties":{"existing_categories":{"items":{"type":"string"},"type":"array","maxItems":50,"title":"Existing Categories"},"project_type":{"type":"string","pattern":"^(residential|commercial|mixed)$","title":"Project Type"},"region":{"type":"string","maxLength":50,"title":"Region"}},"type":"object","required":["existing_categories","project_type","region"],"title":"ScopeCheckRequest"},"SearchResultItem":{"properties":{"id":{"type":"string","title":"Id"},"label":{"type":"string","title":"Label"},"sublabel":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Sublabel"},"url":{"type":"string","title":"Url"}},"type":"object","required":["id","label","url"],"title":"SearchResultItem"},"SearchResults":{"properties":{"clients":{"items":{"$ref":"#/components/schemas/SearchResultItem"},"type":"array","title":"Clients"},"tenders":{"items":{"$ref":"#/components/schemas/SearchResultItem"},"type":"array","title":"Tenders"},"quotes":{"items":{"$ref":"#/components/schemas/SearchResultItem"},"type":"array","title":"Quotes"},"jobs":{"items":{"$ref":"#/components/schemas/SearchResultItem"},"type":"array","title":"Jobs"}},"type":"object","required":["clients","tenders","quotes","jobs"],"title":"SearchResults"},"SecurityEventResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"user_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"User Id"},"event_type":{"type":"string","title":"Event Type"},"ip_address":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Ip Address"},"user_agent":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"User Agent"},"metadata_":{"anyOf":[{"type":"object"},{"type":"null"}],"title":"Metadata"},"severity":{"type":"string","title":"Severity"},"created_at":{"type":"string","format":"date-time","title":"Created At"}},"type":"object","required":["id","event_type","severity","created_at"],"title":"SecurityEventResponse"},"SecurityEventType":{"type":"string","enum":["FAILED_LOGIN","NEW_DEVICE","NEW_LOCATION","BULK_EXPORT","MASS_DELETE","PASSWORD_CHANGE","TWO_FA_ENABLED","TWO_FA_DISABLED","ADMIN_LOGIN","SUSPICIOUS_ACTIVITY","API_KEY_CREATED","IP_BLOCKED"],"title":"SecurityEventType"},"SendInvoiceRequest":{"properties":{"recipient":{"anyOf":[{"type":"string","format":"email"},{"type":"null"}],"title":"Recipient"}},"type":"object","title":"SendInvoiceRequest"},"SendMessageRequest":{"properties":{"kind":{"$ref":"#/components/schemas/MessageKind"},"channel":{"$ref":"#/components/schemas/MessageChannel","default":"sms"},"body":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Body"},"recipient":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Recipient"}},"type":"object","required":["kind"],"title":"SendMessageRequest"},"SensitivityRequest":{"properties":{"items":{"items":{"type":"object"},"type":"array","title":"Items"},"scenarios":{"items":{"$ref":"#/components/schemas/SensitivityScenario"},"type":"array","maxItems":10,"title":"Scenarios"}},"type":"object","required":["items","scenarios"],"title":"SensitivityRequest"},"SensitivityScenario":{"properties":{"material":{"type":"string","maxLength":100,"title":"Material"},"change_percent":{"type":"number","maximum":500.0,"minimum":-100.0,"title":"Change Percent"}},"type":"object","required":["material","change_percent"],"title":"SensitivityScenario"},"ServiceStatus":{"properties":{"name":{"type":"string","title":"Name"},"status":{"type":"string","title":"Status"},"latency_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Latency Ms"},"detail":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Detail"}},"type":"object","required":["name","status"],"title":"ServiceStatus"},"SessionResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"device":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Device"},"ip":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Ip"},"last_seen_at":{"type":"string","format":"date-time","title":"Last Seen At"},"is_active":{"type":"boolean","title":"Is Active"},"created_at":{"type":"string","format":"date-time","title":"Created At"}},"type":"object","required":["id","device","ip","last_seen_at","is_active","created_at"],"title":"SessionResponse"},"SignOffRequest":{"properties":{"sign_off_name":{"type":"string","title":"Sign Off Name"},"sign_off_date":{"type":"string","format":"date","title":"Sign Off Date"}},"type":"object","required":["sign_off_name","sign_off_date"],"title":"SignOffRequest"},"SignSubmitRequest":{"properties":{"signer_name":{"type":"string","maxLength":255,"minLength":1,"title":"Signer Name"},"signature_data":{"type":"string","title":"Signature Data"}},"type":"object","required":["signer_name","signature_data"],"title":"SignSubmitRequest"},"SignoffMethod":{"type":"string","enum":["qr_scan","in_app","paper"],"title":"SignoffMethod"},"SiteAccessCheckItem":{"properties":{"key":{"type":"string","title":"Key"},"label":{"type":"string","title":"Label"},"passed":{"type":"boolean","title":"Passed"},"mode":{"type":"string","title":"Mode"},"detail":{"type":"string","title":"Detail"}},"type":"object","required":["key","label","passed","mode","detail"],"title":"SiteAccessCheckItem"},"SiteAccessCheckResponse":{"properties":{"allowed":{"type":"boolean","title":"Allowed"},"checks":{"items":{"$ref":"#/components/schemas/SiteAccessCheckItem"},"type":"array","title":"Checks","default":[]},"blocks":{"items":{"type":"string"},"type":"array","title":"Blocks","default":[]},"warnings":{"items":{"type":"string"},"type":"array","title":"Warnings","default":[]}},"type":"object","required":["allowed"],"title":"SiteAccessCheckResponse"},"SiteDiaryEntryCreate":{"properties":{"job_id":{"type":"string","format":"uuid","title":"Job Id"},"entry_date":{"type":"string","format":"date","title":"Entry Date"},"weather":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Weather"},"temperature":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Temperature"},"workers_on_site":{"type":"integer","minimum":0.0,"title":"Workers On Site","default":0},"plant_on_site":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Plant On Site"},"work_carried_out":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Work Carried Out"},"delays":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Delays"},"visitors":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Visitors"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"created_by_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Created By Name"}},"type":"object","required":["job_id","entry_date"],"title":"SiteDiaryEntryCreate"},"SiteDiaryEntryResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"job_id":{"type":"string","format":"uuid","title":"Job Id"},"entry_date":{"type":"string","format":"date","title":"Entry Date"},"weather":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Weather"},"temperature":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Temperature"},"workers_on_site":{"type":"integer","title":"Workers On Site"},"plant_on_site":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Plant On Site"},"work_carried_out":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Work Carried Out"},"delays":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Delays"},"visitors":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Visitors"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"created_by_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Created By Name"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"}},"type":"object","required":["id","job_id","entry_date","weather","temperature","workers_on_site","plant_on_site","work_carried_out","delays","visitors","notes","created_by_name","created_at","updated_at"],"title":"SiteDiaryEntryResponse"},"SiteDiaryEntryUpdate":{"properties":{"entry_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Entry Date"},"weather":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Weather"},"temperature":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Temperature"},"workers_on_site":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Workers On Site"},"plant_on_site":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Plant On Site"},"work_carried_out":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Work Carried Out"},"delays":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Delays"},"visitors":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Visitors"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"created_by_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Created By Name"}},"type":"object","title":"SiteDiaryEntryUpdate"},"SiteGateConfig":{"properties":{"gate_induction":{"$ref":"#/components/schemas/SiteGateMode"},"gate_cscs":{"$ref":"#/components/schemas/SiteGateMode"},"gate_rams":{"$ref":"#/components/schemas/SiteGateMode"},"active_rams_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Active Rams Id"}},"type":"object","required":["gate_induction","gate_cscs","gate_rams"],"title":"SiteGateConfig"},"SiteGateConfigUpdate":{"properties":{"gate_induction":{"anyOf":[{"$ref":"#/components/schemas/SiteGateMode"},{"type":"null"}]},"gate_cscs":{"anyOf":[{"$ref":"#/components/schemas/SiteGateMode"},{"type":"null"}]},"gate_rams":{"anyOf":[{"$ref":"#/components/schemas/SiteGateMode"},{"type":"null"}]},"active_rams_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Active Rams Id"}},"type":"object","title":"SiteGateConfigUpdate"},"SiteGateMode":{"type":"string","enum":["off","warn","block"],"title":"SiteGateMode","description":"How a failed site-entry check behaves on a QR clock-on.\n\nDefaults to OFF everywhere: a two-man builder will not want to be locked out of\ntheir own site, while a principal contractor will set BLOCK on day one."},"SitePhotoCaptureCorrection":{"properties":{"reason":{"type":"string","maxLength":500,"minLength":10,"title":"Reason"},"taken_at":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Taken At"},"latitude":{"anyOf":[{"type":"number","maximum":90.0,"minimum":-90.0},{"type":"null"}],"title":"Latitude"},"longitude":{"anyOf":[{"type":"number","maximum":180.0,"minimum":-180.0},{"type":"null"}],"title":"Longitude"}},"type":"object","required":["reason"],"title":"SitePhotoCaptureCorrection","description":"An audited correction to capture metadata.\n\nCameras do get set to the wrong date and phones do record a fix from the previous site,\nso a correction path has to exist — but every correction is recorded with the old and new\nvalues and the reason given, so the photo's history is visible rather than rewritten."},"SitePhotoResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"company_id":{"type":"string","format":"uuid","title":"Company Id"},"job_id":{"type":"string","format":"uuid","title":"Job Id"},"uploaded_by_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Uploaded By Id"},"storage_path":{"type":"string","title":"Storage Path"},"filename":{"type":"string","title":"Filename"},"mime_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Mime Type"},"file_size":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"File Size"},"caption":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Caption"},"location":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Location"},"trade":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Trade"},"taken_at":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Taken At"},"latitude":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Latitude"},"longitude":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Longitude"},"album_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Album Id"},"before_after":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Before After"},"comparison_group":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Comparison Group"},"is_client_visible":{"type":"boolean","title":"Is Client Visible"},"created_at":{"type":"string","format":"date-time","title":"Created At"}},"type":"object","required":["id","company_id","job_id","uploaded_by_id","storage_path","filename","mime_type","file_size","caption","location","trade","taken_at","latitude","longitude","album_id","before_after","comparison_group","is_client_visible","created_at"],"title":"SitePhotoResponse"},"SitePhotoUpdate":{"properties":{"caption":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Caption"},"location":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Location"},"trade":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Trade"},"album_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Album Id"},"before_after":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Before After"},"comparison_group":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Comparison Group"},"is_client_visible":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Client Visible"}},"additionalProperties":false,"type":"object","title":"SitePhotoUpdate","description":"Editable description of a photo.\n\nCapture metadata (taken_at, latitude, longitude) is deliberately absent: a photo is\nevidence of a condition at a place and time, and silently editable capture data destroys\nthat. `extra=\"forbid\"` so an attempt to set it is rejected rather than quietly ignored —\ncorrections go through the audited /capture-correction endpoint."},"SmartMatchResponse":{"properties":{"matches":{"items":{"$ref":"#/components/schemas/SmartMatchResult"},"type":"array","title":"Matches"}},"type":"object","required":["matches"],"title":"SmartMatchResponse"},"SmartMatchResult":{"properties":{"profile_id":{"type":"string","format":"uuid","title":"Profile Id"},"display_name":{"type":"string","title":"Display Name"},"reasoning":{"type":"string","title":"Reasoning"},"rank":{"type":"integer","title":"Rank"},"avg_rating":{"type":"number","title":"Avg Rating"},"trades":{"items":{"type":"string"},"type":"array","title":"Trades"}},"type":"object","required":["profile_id","display_name","reasoning","rank","avg_rating","trades"],"title":"SmartMatchResult"},"SorItemCreate":{"properties":{"code":{"type":"string","maxLength":50,"minLength":1,"title":"Code"},"description":{"type":"string","minLength":1,"title":"Description"},"unit":{"$ref":"#/components/schemas/SorUnit","default":"each"},"rate":{"type":"number","minimum":0.0,"title":"Rate","default":0.0},"smv_minutes":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Smv Minutes"},"trade":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Trade"},"category":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Category"}},"type":"object","required":["code","description"],"title":"SorItemCreate"},"SorItemResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"schedule_id":{"type":"string","format":"uuid","title":"Schedule Id"},"code":{"type":"string","title":"Code"},"description":{"type":"string","title":"Description"},"unit":{"$ref":"#/components/schemas/SorUnit"},"rate":{"type":"number","title":"Rate"},"smv_minutes":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Smv Minutes"},"trade":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Trade"},"category":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Category"},"is_active":{"type":"boolean","title":"Is Active"}},"type":"object","required":["id","schedule_id","code","description","unit","rate","smv_minutes","trade","category","is_active"],"title":"SorItemResponse"},"SorUnit":{"type":"string","enum":["each","hour","m","m2","m3","item","set","day"],"title":"SorUnit"},"StartTrialRequest":{"properties":{"plan":{"type":"string","title":"Plan","default":"pro"}},"type":"object","title":"StartTrialRequest"},"StarterFormBody":{"properties":{"emergency_contact_name":{"type":"string","title":"Emergency Contact Name"},"emergency_contact_phone":{"type":"string","title":"Emergency Contact Phone"},"emergency_contact_relationship":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Emergency Contact Relationship"},"bank_account_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Bank Account Name"},"bank_sort_code":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Bank Sort Code"},"bank_account_number":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Bank Account Number"},"national_insurance_number":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"National Insurance Number"}},"type":"object","required":["emergency_contact_name","emergency_contact_phone"],"title":"StarterFormBody"},"StatusResponse":{"properties":{"state":{"$ref":"#/components/schemas/ComponentState"},"checked_at":{"type":"string","format":"date-time","title":"Checked At"},"components":{"items":{"$ref":"#/components/schemas/ComponentStatus"},"type":"array","title":"Components"}},"type":"object","required":["state","checked_at","components"],"title":"StatusResponse"},"StockItemCreate":{"properties":{"sku":{"type":"string","maxLength":100,"minLength":1,"title":"Sku"},"name":{"type":"string","maxLength":255,"minLength":1,"title":"Name"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"unit":{"type":"string","title":"Unit","default":"each"},"unit_cost":{"type":"number","minimum":0.0,"title":"Unit Cost","default":0.0},"supplier_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Supplier Id"},"reorder_level":{"type":"integer","minimum":0.0,"title":"Reorder Level","default":0}},"type":"object","required":["sku","name"],"title":"StockItemCreate"},"StockItemResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"sku":{"type":"string","title":"Sku"},"name":{"type":"string","title":"Name"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"unit":{"type":"string","title":"Unit"},"unit_cost":{"type":"number","title":"Unit Cost"},"reorder_level":{"type":"integer","title":"Reorder Level"},"is_active":{"type":"boolean","title":"Is Active"},"total_quantity":{"type":"number","title":"Total Quantity","default":0.0}},"type":"object","required":["id","sku","name","description","unit","unit_cost","reorder_level","is_active"],"title":"StockItemResponse"},"StockLevelResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"location_id":{"type":"string","format":"uuid","title":"Location Id"},"item_id":{"type":"string","format":"uuid","title":"Item Id"},"quantity":{"type":"number","title":"Quantity"},"location_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Location Name"},"item_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Item Name"},"item_sku":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Item Sku"}},"type":"object","required":["id","location_id","item_id","quantity"],"title":"StockLevelResponse"},"StockLocationType":{"type":"string","enum":["van","store","site"],"title":"StockLocationType"},"StockMovementType":{"type":"string","enum":["receipt","issue","return","transfer","adjustment"],"title":"StockMovementType"},"SubInvoiceCreate":{"properties":{"invoice_date":{"type":"string","format":"date","title":"Invoice Date"},"due_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Due Date"},"amount_net":{"type":"number","exclusiveMinimum":0.0,"title":"Amount Net"},"cis_deduction_rate":{"type":"number","maximum":100.0,"minimum":0.0,"title":"Cis Deduction Rate","default":20.0},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"job_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Job Id"},"rfq_invitation_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Rfq Invitation Id"}},"type":"object","required":["invoice_date","amount_net"],"title":"SubInvoiceCreate"},"SubInvoiceResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"company_id":{"type":"string","format":"uuid","title":"Company Id"},"subcontractor_id":{"type":"string","format":"uuid","title":"Subcontractor Id"},"job_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Job Id"},"rfq_invitation_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Rfq Invitation Id"},"invoice_number":{"type":"string","title":"Invoice Number"},"invoice_date":{"type":"string","format":"date","title":"Invoice Date"},"due_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Due Date"},"amount_net":{"type":"number","title":"Amount Net"},"cis_deduction_rate":{"type":"number","title":"Cis Deduction Rate"},"cis_deduction_amount":{"type":"number","title":"Cis Deduction Amount"},"amount_gross":{"type":"number","title":"Amount Gross"},"status":{"type":"string","title":"Status"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"payment_certificate_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Payment Certificate Url"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"}},"type":"object","required":["id","company_id","subcontractor_id","job_id","rfq_invitation_id","invoice_number","invoice_date","due_date","amount_net","cis_deduction_rate","cis_deduction_amount","amount_gross","status","notes","payment_certificate_url","created_at","updated_at"],"title":"SubInvoiceResponse"},"SubInvoiceUpdate":{"properties":{"status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Status"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"payment_certificate_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Payment Certificate Url"}},"type":"object","title":"SubInvoiceUpdate"},"SubPortalInvitationLineItemResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"rfq_line_item_id":{"type":"string","format":"uuid","title":"Rfq Line Item Id"},"description":{"type":"string","title":"Description"},"unit_price":{"type":"number","title":"Unit Price"},"total":{"type":"number","title":"Total"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"}},"type":"object","required":["id","rfq_line_item_id","description","unit_price","total"],"title":"SubPortalInvitationLineItemResponse"},"SubPortalLineItemResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"description":{"type":"string","title":"Description"},"quantity":{"type":"number","title":"Quantity"},"unit":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Unit"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"sort_order":{"type":"integer","title":"Sort Order"}},"type":"object","required":["id","description","quantity","sort_order"],"title":"SubPortalLineItemResponse"},"SubPortalQuoteLineItem":{"properties":{"rfq_line_item_id":{"type":"string","format":"uuid","title":"Rfq Line Item Id"},"unit_price":{"type":"number","title":"Unit Price"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"}},"type":"object","required":["rfq_line_item_id","unit_price"],"title":"SubPortalQuoteLineItem"},"SubPortalQuoteSubmit":{"properties":{"line_items":{"items":{"$ref":"#/components/schemas/SubPortalQuoteLineItem"},"type":"array","title":"Line Items"},"total_price":{"type":"number","title":"Total Price"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"}},"type":"object","required":["line_items","total_price"],"title":"SubPortalQuoteSubmit"},"SubPortalRFQResponse":{"properties":{"invitation_id":{"type":"string","format":"uuid","title":"Invitation Id"},"rfq_id":{"type":"string","format":"uuid","title":"Rfq Id"},"rfq_number":{"type":"string","title":"Rfq Number"},"rfq_title":{"type":"string","title":"Rfq Title"},"rfq_description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Rfq Description"},"due_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Due Date"},"company_name":{"type":"string","title":"Company Name"},"status":{"type":"string","title":"Status"},"total_price":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Total Price"},"submitted_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Submitted At"},"line_items":{"items":{"$ref":"#/components/schemas/SubPortalLineItemResponse"},"type":"array","title":"Line Items"},"quote_line_items":{"items":{"$ref":"#/components/schemas/SubPortalInvitationLineItemResponse"},"type":"array","title":"Quote Line Items"}},"type":"object","required":["invitation_id","rfq_id","rfq_number","rfq_title","company_name","status","line_items","quote_line_items"],"title":"SubPortalRFQResponse"},"SubcontractorCreate":{"properties":{"name":{"type":"string","maxLength":255,"minLength":1,"title":"Name"},"trade":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Trade"},"email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Email"},"phone":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Phone"},"address":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Address"},"city":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"City"},"postcode":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Postcode"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"}},"type":"object","required":["name"],"title":"SubcontractorCreate"},"SubcontractorResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"company_id":{"type":"string","format":"uuid","title":"Company Id"},"name":{"type":"string","title":"Name"},"trade":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Trade"},"email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Email"},"phone":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Phone"},"address":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Address"},"city":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"City"},"postcode":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Postcode"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"is_active":{"type":"boolean","title":"Is Active"},"is_approved":{"type":"boolean","title":"Is Approved"},"performance_rating":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Performance Rating"},"performance_notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Performance Notes"},"approved_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Approved At"},"xero_contact_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Xero Contact Id"},"quickbooks_vendor_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Quickbooks Vendor Id"},"freshbooks_client_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Freshbooks Client Id"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"}},"type":"object","required":["id","company_id","name","trade","email","phone","address","city","postcode","notes","is_active","is_approved","performance_rating","performance_notes","approved_at","xero_contact_id","quickbooks_vendor_id","freshbooks_client_id","created_at","updated_at"],"title":"SubcontractorResponse"},"SubcontractorUpdate":{"properties":{"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name"},"trade":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Trade"},"email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Email"},"phone":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Phone"},"address":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Address"},"city":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"City"},"postcode":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Postcode"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"is_active":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Active"},"is_approved":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Approved"},"performance_rating":{"anyOf":[{"type":"number","maximum":5.0,"minimum":0.0},{"type":"null"}],"title":"Performance Rating"},"performance_notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Performance Notes"}},"type":"object","title":"SubcontractorUpdate"},"SubmissionCreate":{"properties":{"data":{"type":"object","title":"Data"},"entity_type":{"anyOf":[{"$ref":"#/components/schemas/FormEntityType"},{"type":"null"}]},"entity_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Entity Id"},"signature_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Signature Url"}},"type":"object","required":["data"],"title":"SubmissionCreate"},"SubmissionResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"form_id":{"type":"string","format":"uuid","title":"Form Id"},"entity_type":{"$ref":"#/components/schemas/FormEntityType"},"entity_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Entity Id"},"data":{"type":"object","title":"Data"},"schema_snapshot":{"items":{"type":"object"},"type":"array","title":"Schema Snapshot"},"form_version":{"type":"integer","title":"Form Version"},"submitted_by_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Submitted By Id"},"submitted_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Submitted At"},"signature_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Signature Url"},"created_at":{"type":"string","format":"date-time","title":"Created At"}},"type":"object","required":["id","form_id","entity_type","entity_id","data","schema_snapshot","form_version","submitted_by_id","submitted_at","signature_url","created_at"],"title":"SubmissionResponse"},"SubmitAccreditationRequest":{"properties":{"scheme":{"type":"string","title":"Scheme"},"reference_number":{"type":"string","title":"Reference Number"},"document_path":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Document Path"}},"type":"object","required":["scheme","reference_number"],"title":"SubmitAccreditationRequest"},"SubmitLeaveRequest":{"properties":{"leave_type":{"$ref":"#/components/schemas/LeaveType"},"start_date":{"type":"string","format":"date","title":"Start Date"},"end_date":{"type":"string","format":"date","title":"End Date"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"}},"type":"object","required":["leave_type","start_date","end_date"],"title":"SubmitLeaveRequest"},"SubmitReturnRequest":{"properties":{"hmrc_reference":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Hmrc Reference"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"submission_method":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Submission Method","description":"How the return reached HMRC, e.g. 'hmrc_online', 'agent', 'software'."},"employment_status_declared":{"type":"boolean","title":"Employment Status Declared","default":false},"verification_declared":{"type":"boolean","title":"Verification Declared","default":false},"is_nil_return":{"type":"boolean","title":"Is Nil Return","default":false},"inactivity_declared":{"type":"boolean","title":"Inactivity Declared","default":false}},"type":"object","title":"SubmitReturnRequest","description":"Records a return that has been filed with HMRC.\n\nEstimark does not file on your behalf — filing needs user-restricted HMRC OAuth and\nfraud-prevention headers. This records what was filed, when, and the declarations that\nwere made, so the audit trail is complete and the deductions are locked to a period."},"SubscribeRequest":{"properties":{"payment_method_id":{"type":"string","title":"Payment Method Id"},"customer_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Customer Id"},"plan":{"type":"string","title":"Plan","default":"core"},"billing_interval":{"type":"string","title":"Billing Interval","default":"monthly"}},"type":"object","required":["payment_method_id"],"title":"SubscribeRequest"},"SubscriptionOverrideBody":{"properties":{"plan":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Plan"},"status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Status"},"extend_trial_days":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Extend Trial Days"},"reason":{"type":"string","title":"Reason","default":""},"sync_stripe":{"type":"boolean","title":"Sync Stripe","default":false}},"type":"object","title":"SubscriptionOverrideBody"},"SupplierContactCreate":{"properties":{"name":{"type":"string","maxLength":255,"minLength":1,"title":"Name"},"role":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Role"},"email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Email"},"phone":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Phone"},"is_primary":{"type":"boolean","title":"Is Primary","default":false}},"type":"object","required":["name"],"title":"SupplierContactCreate"},"SupplierContactResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"supplier_id":{"type":"string","format":"uuid","title":"Supplier Id"},"name":{"type":"string","title":"Name"},"role":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Role"},"email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Email"},"phone":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Phone"},"is_primary":{"type":"boolean","title":"Is Primary"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"}},"type":"object","required":["id","supplier_id","name","role","email","phone","is_primary","created_at","updated_at"],"title":"SupplierContactResponse"},"SupplierContactUpdate":{"properties":{"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name"},"role":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Role"},"email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Email"},"phone":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Phone"},"is_primary":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Primary"}},"type":"object","title":"SupplierContactUpdate"},"SupplierCreate":{"properties":{"name":{"type":"string","maxLength":255,"minLength":1,"title":"Name"},"contact_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Contact Name"},"email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Email"},"phone":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Phone"},"address":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Address"},"city":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"City"},"postcode":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Postcode"},"website":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Website"},"account_reference":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Account Reference"},"payment_terms_days":{"type":"integer","title":"Payment Terms Days","default":30},"category":{"type":"string","title":"Category","default":"other"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"}},"type":"object","required":["name"],"title":"SupplierCreate"},"SupplierPriceResponse":{"properties":{"supplier_key":{"type":"string","title":"Supplier Key"},"supplier_name":{"type":"string","title":"Supplier Name"},"supplier_url":{"type":"string","title":"Supplier Url"},"supplier_sku":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Supplier Sku"},"price_ex_vat":{"type":"number","title":"Price Ex Vat"},"price_inc_vat":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Price Inc Vat"},"in_stock":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"In Stock"},"last_scraped_at":{"type":"string","format":"date-time","title":"Last Scraped At"}},"type":"object","required":["supplier_key","supplier_name","supplier_url","price_ex_vat","last_scraped_at"],"title":"SupplierPriceResponse"},"SupplierResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"company_id":{"type":"string","format":"uuid","title":"Company Id"},"name":{"type":"string","title":"Name"},"contact_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Contact Name"},"email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Email"},"phone":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Phone"},"address":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Address"},"city":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"City"},"postcode":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Postcode"},"website":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Website"},"account_reference":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Account Reference"},"payment_terms_days":{"type":"integer","title":"Payment Terms Days"},"category":{"type":"string","title":"Category"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"is_active":{"type":"boolean","title":"Is Active"},"is_approved":{"type":"boolean","title":"Is Approved"},"performance_rating":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Performance Rating"},"performance_notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Performance Notes"},"sage_vendor_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Sage Vendor Id"},"xero_contact_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Xero Contact Id"},"quickbooks_vendor_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Quickbooks Vendor Id"},"freshbooks_client_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Freshbooks Client Id"},"contacts":{"items":{"$ref":"#/components/schemas/SupplierContactResponse"},"type":"array","title":"Contacts","default":[]},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"}},"type":"object","required":["id","company_id","name","contact_name","email","phone","address","city","postcode","website","account_reference","payment_terms_days","category","notes","is_active","is_approved","performance_rating","performance_notes","sage_vendor_id","xero_contact_id","quickbooks_vendor_id","freshbooks_client_id","created_at","updated_at"],"title":"SupplierResponse"},"SupplierUpdate":{"properties":{"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name"},"contact_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Contact Name"},"email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Email"},"phone":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Phone"},"address":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Address"},"city":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"City"},"postcode":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Postcode"},"website":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Website"},"account_reference":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Account Reference"},"payment_terms_days":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Payment Terms Days"},"category":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Category"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"is_active":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Active"},"is_approved":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Approved"},"performance_rating":{"anyOf":[{"type":"number","maximum":5.0,"minimum":0.0},{"type":"null"}],"title":"Performance Rating"},"performance_notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Performance Notes"}},"type":"object","title":"SupplierUpdate"},"TakeoffCreate":{"properties":{"title":{"type":"string","title":"Title"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"job_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Job Id"},"quote_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Quote Id"},"reference_doc_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Reference Doc Id"},"measurements":{"items":{"type":"object"},"type":"array","title":"Measurements","default":[]}},"type":"object","required":["title"],"title":"TakeoffCreate"},"TakeoffUpdate":{"properties":{"title":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Title"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"job_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Job Id"},"quote_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Quote Id"},"measurements":{"anyOf":[{"items":{"type":"object"},"type":"array"},{"type":"null"}],"title":"Measurements"}},"type":"object","title":"TakeoffUpdate"},"TeamInvitationResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"email":{"type":"string","title":"Email"},"role":{"$ref":"#/components/schemas/CompanyUserRole"},"expires_at":{"type":"string","format":"date-time","title":"Expires At"},"created_at":{"type":"string","format":"date-time","title":"Created At"}},"type":"object","required":["id","email","role","expires_at","created_at"],"title":"TeamInvitationResponse"},"TeamMemberCostUpdate":{"properties":{"trade":{"anyOf":[{"type":"string","maxLength":100},{"type":"null"}],"title":"Trade"},"hourly_rate":{"anyOf":[{"type":"number","minimum":0.0},{"type":"null"}],"title":"Hourly Rate"},"daily_rate":{"anyOf":[{"type":"number","minimum":0.0},{"type":"null"}],"title":"Daily Rate"},"annual_salary":{"anyOf":[{"type":"number","minimum":0.0},{"type":"null"}],"title":"Annual Salary"},"cost_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cost Type"}},"type":"object","title":"TeamMemberCostUpdate"},"TeamMemberResponse":{"properties":{"user_id":{"type":"string","format":"uuid","title":"User Id"},"email":{"type":"string","title":"Email"},"full_name":{"type":"string","title":"Full Name"},"role":{"$ref":"#/components/schemas/CompanyUserRole"},"created_at":{"type":"string","format":"date-time","title":"Created At"}},"type":"object","required":["user_id","email","full_name","role","created_at"],"title":"TeamMemberResponse"},"TenderAnalysisLineItemResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"item_type":{"$ref":"#/components/schemas/LineItemType"},"description":{"type":"string","title":"Description"},"category":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Category"},"quantity":{"type":"number","title":"Quantity"},"unit":{"type":"string","title":"Unit"},"unit_price":{"type":"number","title":"Unit Price"},"total":{"type":"number","title":"Total"},"price_book_item_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Price Book Item Id"},"labour_rate_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Labour Rate Id"},"team_member_user_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Team Member User Id"},"confidence":{"$ref":"#/components/schemas/ConfidenceLevel"},"is_approved":{"type":"boolean","title":"Is Approved"},"sort_order":{"type":"integer","title":"Sort Order"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"}},"type":"object","required":["id","item_type","description","category","quantity","unit","unit_price","total","price_book_item_id","labour_rate_id","team_member_user_id","confidence","is_approved","sort_order","notes"],"title":"TenderAnalysisLineItemResponse"},"TenderAnalysisQuestionResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"question":{"type":"string","title":"Question"},"category":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Category"},"answer":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Answer"},"answered_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Answered At"},"is_required":{"type":"boolean","title":"Is Required"},"sort_order":{"type":"integer","title":"Sort Order"}},"type":"object","required":["id","question","category","answer","answered_at","is_required","sort_order"],"title":"TenderAnalysisQuestionResponse"},"TenderAnalysisResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"tender_id":{"type":"string","format":"uuid","title":"Tender Id"},"status":{"$ref":"#/components/schemas/AnalysisStatus"},"summary":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Summary"},"scope_of_works":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Scope Of Works"},"key_requirements":{"anyOf":[{"items":{},"type":"array"},{"type":"null"}],"title":"Key Requirements"},"suggested_trades":{"anyOf":[{"items":{},"type":"array"},{"type":"null"}],"title":"Suggested Trades"},"error_message":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error Message"},"analysed_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Analysed At"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"}},"type":"object","required":["id","tender_id","status","summary","scope_of_works","key_requirements","suggested_trades","error_message","analysed_at","created_at","updated_at"],"title":"TenderAnalysisResponse"},"TenderCountResponse":{"properties":{"count":{"type":"integer","title":"Count"},"sample_titles":{"items":{"type":"string"},"type":"array","title":"Sample Titles"}},"type":"object","required":["count","sample_titles"],"title":"TenderCountResponse"},"TenderCreateRequest":{"properties":{"title":{"type":"string","maxLength":500,"minLength":1,"title":"Title"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"reference_number":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Reference Number"},"client_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Client Id"},"due_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Due Date"},"site_address":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Site Address"},"project_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Project Type"},"estimated_value":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Estimated Value"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"}},"type":"object","required":["title"],"title":"TenderCreateRequest"},"TenderMatchResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"tender_opportunity_id":{"type":"string","format":"uuid","title":"Tender Opportunity Id"},"user_id":{"type":"string","format":"uuid","title":"User Id"},"company_id":{"type":"string","format":"uuid","title":"Company Id"},"match_score":{"type":"integer","title":"Match Score"},"match_reasons":{"items":{"type":"string"},"type":"array","title":"Match Reasons"},"alert_sent":{"type":"boolean","title":"Alert Sent"},"user_dismissed":{"type":"boolean","title":"User Dismissed"},"user_saved":{"type":"boolean","title":"User Saved"},"user_status":{"$ref":"#/components/schemas/MatchUserStatus"},"ai_analysis":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Ai Analysis"},"disclaimer_acknowledged_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Disclaimer Acknowledged At"},"tender_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Tender Id"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"}},"type":"object","required":["id","tender_opportunity_id","user_id","company_id","match_score","match_reasons","alert_sent","user_dismissed","user_saved","user_status","ai_analysis","disclaimer_acknowledged_at","created_at","updated_at"],"title":"TenderMatchResponse"},"TenderMatchWithOpportunity":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"tender_opportunity_id":{"type":"string","format":"uuid","title":"Tender Opportunity Id"},"user_id":{"type":"string","format":"uuid","title":"User Id"},"company_id":{"type":"string","format":"uuid","title":"Company Id"},"match_score":{"type":"integer","title":"Match Score"},"match_reasons":{"items":{"type":"string"},"type":"array","title":"Match Reasons"},"alert_sent":{"type":"boolean","title":"Alert Sent"},"user_dismissed":{"type":"boolean","title":"User Dismissed"},"user_saved":{"type":"boolean","title":"User Saved"},"user_status":{"$ref":"#/components/schemas/MatchUserStatus"},"ai_analysis":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Ai Analysis"},"disclaimer_acknowledged_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Disclaimer Acknowledged At"},"tender_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Tender Id"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"},"opportunity":{"$ref":"#/components/schemas/TenderOpportunityResponse"}},"type":"object","required":["id","tender_opportunity_id","user_id","company_id","match_score","match_reasons","alert_sent","user_dismissed","user_saved","user_status","ai_analysis","disclaimer_acknowledged_at","created_at","updated_at","opportunity"],"title":"TenderMatchWithOpportunity","description":"Match response including the opportunity details."},"TenderOpportunityResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"source":{"$ref":"#/components/schemas/TenderSource"},"reference_id":{"type":"string","title":"Reference Id"},"title":{"type":"string","title":"Title"},"description":{"type":"string","title":"Description"},"buyer_name":{"type":"string","title":"Buyer Name"},"buyer_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Buyer Type"},"published_at":{"type":"string","format":"date-time","title":"Published At"},"deadline_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Deadline At"},"value_min":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Value Min"},"value_max":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Value Max"},"value_estimated":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Value Estimated"},"cpv_codes":{"items":{"type":"string"},"type":"array","title":"Cpv Codes"},"trade_categories":{"items":{"type":"string"},"type":"array","title":"Trade Categories"},"regions":{"items":{"type":"string"},"type":"array","title":"Regions"},"postcode":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Postcode"},"location":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Location"},"contract_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Contract Type"},"procedure_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Procedure Type"},"award_criteria":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Award Criteria"},"contact_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Contact Name"},"contact_email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Contact Email"},"contact_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Contact Url"},"notice_url":{"type":"string","title":"Notice Url"},"is_active":{"type":"boolean","title":"Is Active"},"closed_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Closed At"},"awarded_to":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Awarded To"},"award_value":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Award Value"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"}},"type":"object","required":["id","source","reference_id","title","description","buyer_name","buyer_type","published_at","deadline_at","value_min","value_max","value_estimated","cpv_codes","trade_categories","regions","postcode","location","contract_type","procedure_type","award_criteria","contact_name","contact_email","contact_url","notice_url","is_active","closed_at","awarded_to","award_value","created_at","updated_at"],"title":"TenderOpportunityResponse"},"TenderPreferences":{"properties":{"interested_in_tenders":{"type":"boolean","title":"Interested In Tenders","default":false},"tender_value_ranges":{"items":{"type":"string"},"type":"array","title":"Tender Value Ranges","default":[]},"tender_sectors":{"items":{"type":"string"},"type":"array","title":"Tender Sectors","default":[]},"tender_travel_distance":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Tender Travel Distance"},"tender_alert_frequency":{"type":"string","title":"Tender Alert Frequency","default":"daily"}},"type":"object","title":"TenderPreferences"},"TenderResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"company_id":{"type":"string","format":"uuid","title":"Company Id"},"client_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Client Id"},"title":{"type":"string","title":"Title"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"reference_number":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Reference Number"},"status":{"$ref":"#/components/schemas/TenderStatus"},"due_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Due Date"},"submitted_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Submitted At"},"site_address":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Site Address"},"project_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Project Type"},"estimated_value":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Estimated Value"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"is_archived":{"type":"boolean","title":"Is Archived"},"custom_fields":{"type":"object","title":"Custom Fields"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"}},"type":"object","required":["id","company_id","client_id","title","description","reference_number","status","due_date","submitted_at","site_address","project_type","estimated_value","notes","is_archived","custom_fields","created_at","updated_at"],"title":"TenderResponse"},"TenderSource":{"type":"string","enum":["fts","contracts_finder"],"title":"TenderSource"},"TenderStatus":{"type":"string","enum":["draft","submitted","won","lost","withdrawn"],"title":"TenderStatus"},"TenderUpdateRequest":{"properties":{"title":{"anyOf":[{"type":"string","maxLength":500,"minLength":1},{"type":"null"}],"title":"Title"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"reference_number":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Reference Number"},"client_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Client Id"},"due_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Due Date"},"site_address":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Site Address"},"project_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Project Type"},"estimated_value":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Estimated Value"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"status":{"anyOf":[{"$ref":"#/components/schemas/TenderStatus"},{"type":"null"}]}},"type":"object","title":"TenderUpdateRequest"},"TicketStatusUpdate":{"properties":{"status":{"type":"string","title":"Status"}},"type":"object","required":["status"],"title":"TicketStatusUpdate"},"TimesheetCategory":{"type":"string","enum":["labour","plant","other"],"title":"TimesheetCategory"},"TimesheetEntryCreate":{"properties":{"job_id":{"type":"string","format":"uuid","title":"Job Id"},"worker_name":{"type":"string","maxLength":255,"minLength":1,"title":"Worker Name"},"entry_date":{"type":"string","format":"date","title":"Entry Date"},"hours":{"type":"number","exclusiveMinimum":0.0,"title":"Hours"},"hourly_rate":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Hourly Rate"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"category":{"$ref":"#/components/schemas/TimesheetCategory","default":"labour"},"reference":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Reference"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"}},"type":"object","required":["job_id","worker_name","entry_date","hours"],"title":"TimesheetEntryCreate"},"TimesheetEntryResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"job_id":{"type":"string","format":"uuid","title":"Job Id"},"worker_name":{"type":"string","title":"Worker Name"},"entry_date":{"type":"string","format":"date","title":"Entry Date"},"hours":{"type":"number","title":"Hours"},"hourly_rate":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Hourly Rate"},"labour_cost":{"type":"number","title":"Labour Cost"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"category":{"$ref":"#/components/schemas/TimesheetCategory"},"reference":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Reference"},"approved":{"type":"boolean","title":"Approved"},"approved_by":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Approved By"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"}},"type":"object","required":["id","job_id","worker_name","entry_date","hours","hourly_rate","labour_cost","description","category","reference","approved","approved_by","notes","created_at","updated_at"],"title":"TimesheetEntryResponse"},"TimesheetEntryUpdate":{"properties":{"worker_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Worker Name"},"entry_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Entry Date"},"hours":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Hours"},"hourly_rate":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Hourly Rate"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"category":{"anyOf":[{"$ref":"#/components/schemas/TimesheetCategory"},{"type":"null"}]},"reference":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Reference"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"}},"type":"object","title":"TimesheetEntryUpdate"},"TimesheetSummary":{"properties":{"job_id":{"type":"string","format":"uuid","title":"Job Id"},"total_hours":{"type":"number","title":"Total Hours"},"total_labour_cost":{"type":"number","title":"Total Labour Cost"},"approved_hours":{"type":"number","title":"Approved Hours"},"pending_hours":{"type":"number","title":"Pending Hours"},"worker_count":{"type":"integer","title":"Worker Count"}},"type":"object","required":["job_id","total_hours","total_labour_cost","approved_hours","pending_hours","worker_count"],"title":"TimesheetSummary"},"ToolboxAttendeeCreate":{"properties":{"person_name":{"type":"string","maxLength":255,"minLength":1,"title":"Person Name"},"person_company":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Person Company"},"worker_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Worker Id"},"signed":{"type":"boolean","title":"Signed","default":false}},"type":"object","required":["person_name"],"title":"ToolboxAttendeeCreate"},"ToolboxAttendeeResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"talk_id":{"type":"string","format":"uuid","title":"Talk Id"},"worker_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Worker Id"},"person_name":{"type":"string","title":"Person Name"},"person_company":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Person Company"},"signed":{"type":"boolean","title":"Signed"},"signed_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Signed At"}},"type":"object","required":["id","talk_id","worker_id","person_name","person_company","signed","signed_at"],"title":"ToolboxAttendeeResponse"},"ToolboxTalkCreate":{"properties":{"topic":{"type":"string","maxLength":500,"minLength":1,"title":"Topic"},"presenter":{"type":"string","maxLength":255,"minLength":1,"title":"Presenter"},"talk_date":{"type":"string","format":"date","title":"Talk Date"},"job_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Job Id"},"location":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Location"},"duration_minutes":{"anyOf":[{"type":"integer","maximum":480.0,"minimum":1.0},{"type":"null"}],"title":"Duration Minutes"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"attendees":{"items":{"$ref":"#/components/schemas/ToolboxAttendeeCreate"},"type":"array","title":"Attendees","default":[]}},"type":"object","required":["topic","presenter","talk_date"],"title":"ToolboxTalkCreate"},"ToolboxTalkResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"company_id":{"type":"string","format":"uuid","title":"Company Id"},"job_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Job Id"},"topic":{"type":"string","title":"Topic"},"presenter":{"type":"string","title":"Presenter"},"talk_date":{"type":"string","format":"date","title":"Talk Date"},"location":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Location"},"duration_minutes":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Duration Minutes"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"attendees":{"items":{"$ref":"#/components/schemas/ToolboxAttendeeResponse"},"type":"array","title":"Attendees","default":[]},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"}},"type":"object","required":["id","company_id","job_id","topic","presenter","talk_date","location","duration_minutes","notes","created_at","updated_at"],"title":"ToolboxTalkResponse"},"ToolboxTalkUpdate":{"properties":{"topic":{"anyOf":[{"type":"string","maxLength":500,"minLength":1},{"type":"null"}],"title":"Topic"},"presenter":{"anyOf":[{"type":"string","maxLength":255,"minLength":1},{"type":"null"}],"title":"Presenter"},"talk_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Talk Date"},"location":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Location"},"duration_minutes":{"anyOf":[{"type":"integer","maximum":480.0,"minimum":1.0},{"type":"null"}],"title":"Duration Minutes"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"attendees":{"anyOf":[{"items":{"$ref":"#/components/schemas/ToolboxAttendeeCreate"},"type":"array"},{"type":"null"}],"title":"Attendees"}},"type":"object","title":"ToolboxTalkUpdate"},"TrackingEventRequest":{"properties":{"event":{"type":"string","title":"Event"},"listing_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Listing Id"},"user_type":{"type":"string","title":"User Type","default":"anonymous"},"session_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Session Id"}},"type":"object","required":["event"],"title":"TrackingEventRequest"},"TradeRateResponse":{"properties":{"trade":{"type":"string","title":"Trade"},"display":{"type":"string","title":"Display"},"avg_day_rate_pence":{"type":"integer","title":"Avg Day Rate Pence"}},"type":"object","required":["trade","display","avg_day_rate_pence"],"title":"TradeRateResponse"},"TwoFABackupCodesResponse":{"properties":{"backup_codes":{"items":{"type":"string"},"type":"array","title":"Backup Codes"}},"type":"object","required":["backup_codes"],"title":"TwoFABackupCodesResponse"},"TwoFADisableRequest":{"properties":{"code":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Code"},"backup_code":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Backup Code"}},"type":"object","title":"TwoFADisableRequest"},"TwoFAEnableRequest":{"properties":{"secret":{"type":"string","title":"Secret"},"code":{"type":"string","title":"Code"}},"type":"object","required":["secret","code"],"title":"TwoFAEnableRequest"},"TwoFAEnableResponse":{"properties":{"backup_codes":{"items":{"type":"string"},"type":"array","title":"Backup Codes"}},"type":"object","required":["backup_codes"],"title":"TwoFAEnableResponse"},"TwoFASetupResponse":{"properties":{"secret":{"type":"string","title":"Secret"},"otpauth_uri":{"type":"string","title":"Otpauth Uri"},"qr_data":{"type":"string","title":"Qr Data"}},"type":"object","required":["secret","otpauth_uri","qr_data"],"title":"TwoFASetupResponse"},"TwoFAVerifyRequest":{"properties":{"temp_token":{"type":"string","title":"Temp Token"},"code":{"type":"string","title":"Code"}},"type":"object","required":["temp_token","code"],"title":"TwoFAVerifyRequest"},"UnitCreate":{"properties":{"unit_number":{"type":"string","maxLength":50,"title":"Unit Number"},"unit_type":{"type":"string","maxLength":30,"title":"Unit Type"},"floor":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Floor"},"aspect":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Aspect"},"area_sqm":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Area Sqm"},"area_sqft":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Area Sqft"},"bedrooms":{"type":"integer","title":"Bedrooms","default":1},"bathrooms":{"type":"integer","title":"Bathrooms","default":1},"asking_price":{"type":"integer","title":"Asking Price","default":0},"service_charge":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Service Charge"},"ground_rent":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Ground Rent"},"leasehold_years":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Leasehold Years"},"epc_rating":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Epc Rating"},"image_s3_keys":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Image S3 Keys"},"floor_plan_s3_key":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Floor Plan S3 Key"},"status":{"type":"string","title":"Status","default":"available"},"portal_status":{"type":"string","title":"Portal Status","default":"draft"}},"type":"object","required":["unit_number","unit_type"],"title":"UnitCreate"},"UnitStatusUpdate":{"properties":{"status":{"type":"string","title":"Status","description":"available | reserved | exchanged | completed | withdrawn"}},"type":"object","required":["status"],"title":"UnitStatusUpdate"},"UnitUpdate":{"properties":{"unit_number":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Unit Number"},"unit_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Unit Type"},"floor":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Floor"},"aspect":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Aspect"},"area_sqm":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Area Sqm"},"area_sqft":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Area Sqft"},"bedrooms":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Bedrooms"},"bathrooms":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Bathrooms"},"asking_price":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Asking Price"},"service_charge":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Service Charge"},"ground_rent":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Ground Rent"},"leasehold_years":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Leasehold Years"},"epc_rating":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Epc Rating"},"image_s3_keys":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Image S3 Keys"},"floor_plan_s3_key":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Floor Plan S3 Key"},"portal_status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Portal Status"}},"type":"object","title":"UnitUpdate"},"UnreadCountResponse":{"properties":{"count":{"type":"integer","title":"Count"}},"type":"object","required":["count"],"title":"UnreadCountResponse"},"UpcomingRetentionRelease":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"job_id":{"type":"string","format":"uuid","title":"Job Id"},"job_number":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Job Number"},"job_title":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Job Title"},"client_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Client Name"},"release_type":{"type":"string","title":"Release Type"},"release_date":{"type":"string","format":"date","title":"Release Date"},"amount":{"type":"number","title":"Amount"},"days_until":{"type":"integer","title":"Days Until"}},"type":"object","required":["id","job_id","job_number","job_title","client_name","release_type","release_date","amount","days_until"],"title":"UpcomingRetentionRelease"},"UpdateLineItemRequest":{"properties":{"description":{"anyOf":[{"type":"string","minLength":1},{"type":"null"}],"title":"Description"},"category":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Category"},"quantity":{"anyOf":[{"type":"number","minimum":0.0},{"type":"null"}],"title":"Quantity"},"unit":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Unit"},"unit_price":{"anyOf":[{"type":"number","minimum":0.0},{"type":"null"}],"title":"Unit Price"},"is_approved":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Approved"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"price_book_item_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Price Book Item Id"},"labour_rate_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Labour Rate Id"},"team_member_user_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Team Member User Id"}},"type":"object","title":"UpdateLineItemRequest"},"UpdateMatchStatusRequest":{"properties":{"user_status":{"$ref":"#/components/schemas/MatchUserStatus"}},"type":"object","required":["user_status"],"title":"UpdateMatchStatusRequest"},"UpdateMemberRoleRequest":{"properties":{"role":{"$ref":"#/components/schemas/CompanyUserRole"}},"type":"object","required":["role"],"title":"UpdateMemberRoleRequest"},"UpdateProfileRequest":{"properties":{"first_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"First Name"},"last_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Last Name"}},"type":"object","title":"UpdateProfileRequest"},"UserResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"email":{"type":"string","format":"email","title":"Email"},"first_name":{"type":"string","title":"First Name"},"last_name":{"type":"string","title":"Last Name"},"full_name":{"type":"string","title":"Full Name"},"is_verified":{"type":"boolean","title":"Is Verified"},"is_active":{"type":"boolean","title":"Is Active"},"is_superuser":{"type":"boolean","title":"Is Superuser","default":false},"created_at":{"type":"string","format":"date-time","title":"Created At"},"role":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Role"},"avatar_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Avatar Url"},"completed_onboarding_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Completed Onboarding At"}},"type":"object","required":["id","email","first_name","last_name","full_name","is_verified","is_active","created_at"],"title":"UserResponse"},"UserUpdateRequest":{"properties":{"first_name":{"anyOf":[{"type":"string","maxLength":100,"minLength":1},{"type":"null"}],"title":"First Name"},"last_name":{"anyOf":[{"type":"string","maxLength":100,"minLength":1},{"type":"null"}],"title":"Last Name"}},"type":"object","title":"UserUpdateRequest"},"ValidateRequest":{"properties":{"validated_date":{"type":"string","format":"date","title":"Validated Date"},"lpa_reference":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Lpa Reference"},"submitted_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Submitted Date"},"eia_development":{"type":"boolean","title":"Eia Development","default":false}},"type":"object","required":["validated_date"],"title":"ValidateRequest","description":"Record the LPA validating the application, which starts the statutory clock."},"ValidationError":{"properties":{"loc":{"items":{"anyOf":[{"type":"string"},{"type":"integer"}]},"type":"array","title":"Location"},"msg":{"type":"string","title":"Message"},"type":{"type":"string","title":"Error Type"}},"type":"object","required":["loc","msg","type"],"title":"ValidationError"},"VapidPublicKeyResponse":{"properties":{"key":{"type":"string","title":"Key"}},"type":"object","required":["key"],"title":"VapidPublicKeyResponse"},"VariationCreate":{"properties":{"job_id":{"type":"string","format":"uuid","title":"Job Id"},"title":{"type":"string","maxLength":500,"minLength":1,"title":"Title"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"variation_amount":{"type":"number","title":"Variation Amount","default":0.0},"requested_by_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Requested By Name"},"line_items":{"items":{"$ref":"#/components/schemas/VariationLineItemCreate"},"type":"array","title":"Line Items","default":[]}},"type":"object","required":["job_id","title"],"title":"VariationCreate"},"VariationLineItemCreate":{"properties":{"description":{"type":"string","minLength":1,"title":"Description"},"quantity":{"type":"number","title":"Quantity","default":1.0},"unit":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Unit"},"unit_price":{"type":"number","title":"Unit Price","default":0.0},"total":{"type":"number","title":"Total","default":0.0},"category":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Category"},"sort_order":{"type":"integer","title":"Sort Order","default":0}},"type":"object","required":["description"],"title":"VariationLineItemCreate"},"VariationLineItemResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"variation_id":{"type":"string","format":"uuid","title":"Variation Id"},"description":{"type":"string","title":"Description"},"quantity":{"type":"number","title":"Quantity"},"unit":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Unit"},"unit_price":{"type":"number","title":"Unit Price"},"total":{"type":"number","title":"Total"},"category":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Category"},"sort_order":{"type":"integer","title":"Sort Order"}},"type":"object","required":["id","variation_id","description","quantity","unit","unit_price","total","category","sort_order"],"title":"VariationLineItemResponse"},"VariationLineItemUpdate":{"properties":{"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"quantity":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Quantity"},"unit":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Unit"},"unit_price":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Unit Price"},"total":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Total"},"category":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Category"},"sort_order":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Sort Order"}},"type":"object","title":"VariationLineItemUpdate"},"VariationRejectBody":{"properties":{"rejected_reason":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Rejected Reason"}},"type":"object","title":"VariationRejectBody"},"VariationResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"company_id":{"type":"string","format":"uuid","title":"Company Id"},"job_id":{"type":"string","format":"uuid","title":"Job Id"},"variation_number":{"type":"string","title":"Variation Number"},"title":{"type":"string","title":"Title"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"status":{"$ref":"#/components/schemas/VariationStatus"},"original_contract_value":{"type":"number","title":"Original Contract Value"},"variation_amount":{"type":"number","title":"Variation Amount"},"requested_by_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Requested By Name"},"approved_by_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Approved By Name"},"submitted_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Submitted At"},"approved_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Approved At"},"rejected_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Rejected At"},"rejected_reason":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Rejected Reason"},"line_items":{"items":{"$ref":"#/components/schemas/VariationLineItemResponse"},"type":"array","title":"Line Items","default":[]},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"}},"type":"object","required":["id","company_id","job_id","variation_number","title","description","status","original_contract_value","variation_amount","requested_by_name","approved_by_name","submitted_at","approved_at","rejected_at","rejected_reason","created_at","updated_at"],"title":"VariationResponse"},"VariationStatus":{"type":"string","enum":["draft","submitted","approved","rejected","withdrawn"],"title":"VariationStatus"},"VariationUpdate":{"properties":{"title":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Title"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"variation_amount":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Variation Amount"},"requested_by_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Requested By Name"},"approved_by_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Approved By Name"}},"type":"object","title":"VariationUpdate"},"VehicleCreate":{"properties":{"registration":{"type":"string","maxLength":20,"minLength":1,"title":"Registration"},"make":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Make"},"model":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Model"},"year":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Year"},"colour":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Colour"},"vehicle_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Vehicle Type"},"mot_expiry":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Mot Expiry"},"insurance_expiry":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Insurance Expiry"},"next_service_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Next Service Date"},"service_interval_miles":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Service Interval Miles"},"current_mileage":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Current Mileage"},"assigned_driver":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Assigned Driver"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"}},"type":"object","required":["registration"],"title":"VehicleCreate"},"VehicleResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"company_id":{"type":"string","format":"uuid","title":"Company Id"},"registration":{"type":"string","title":"Registration"},"make":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Make"},"model":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Model"},"year":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Year"},"colour":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Colour"},"vehicle_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Vehicle Type"},"mot_expiry":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Mot Expiry"},"insurance_expiry":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Insurance Expiry"},"next_service_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Next Service Date"},"service_interval_miles":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Service Interval Miles"},"current_mileage":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Current Mileage"},"assigned_driver":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Assigned Driver"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"is_active":{"type":"boolean","title":"Is Active"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"}},"type":"object","required":["id","company_id","registration","make","model","year","colour","vehicle_type","mot_expiry","insurance_expiry","next_service_date","service_interval_miles","current_mileage","assigned_driver","notes","is_active","created_at","updated_at"],"title":"VehicleResponse"},"VehicleUpdate":{"properties":{"registration":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Registration"},"make":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Make"},"model":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Model"},"year":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Year"},"colour":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Colour"},"vehicle_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Vehicle Type"},"mot_expiry":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Mot Expiry"},"insurance_expiry":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Insurance Expiry"},"next_service_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Next Service Date"},"service_interval_miles":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Service Interval Miles"},"current_mileage":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Current Mileage"},"assigned_driver":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Assigned Driver"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"is_active":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Active"}},"type":"object","title":"VehicleUpdate"},"VerifyEmailRequest":{"properties":{"token":{"type":"string","title":"Token"}},"type":"object","required":["token"],"title":"VerifyEmailRequest"},"VerifyRequest":{"properties":{"is_verified":{"type":"boolean","title":"Is Verified"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"}},"type":"object","required":["is_verified"],"title":"VerifyRequest"},"ViewingSchedule":{"properties":{"viewing_date":{"type":"string","title":"Viewing Date","description":"ISO 8601 datetime string"}},"type":"object","required":["viewing_date"],"title":"ViewingSchedule"},"VisitCreateRequest":{"properties":{"visit_date":{"type":"string","format":"date","title":"Visit Date"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"duration_minutes":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Duration Minutes"},"photos":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Photos"}},"type":"object","required":["visit_date"],"title":"VisitCreateRequest"},"VisitResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"contract_id":{"type":"string","format":"uuid","title":"Contract Id"},"visit_date":{"type":"string","format":"date","title":"Visit Date"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"duration_minutes":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Duration Minutes"},"photos":{"items":{"type":"string"},"type":"array","title":"Photos"},"status":{"type":"string","title":"Status"},"created_at":{"type":"string","title":"Created At"}},"type":"object","required":["id","contract_id","visit_date","photos","status","created_at"],"title":"VisitResponse"},"VisitUpdateRequest":{"properties":{"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"duration_minutes":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Duration Minutes"},"status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Status"}},"type":"object","title":"VisitUpdateRequest"},"VoidCategory":{"type":"string","enum":["minor","standard","major"],"title":"VoidCategory"},"VoidCreate":{"properties":{"property_id":{"type":"string","format":"uuid","title":"Property Id"},"category":{"anyOf":[{"$ref":"#/components/schemas/VoidCategory"},{"type":"null"}]},"notified_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Notified Date"},"keys_received_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Keys Received Date"},"target_days":{"type":"integer","maximum":365.0,"minimum":1.0,"title":"Target Days","default":21},"estimated_cost":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Estimated Cost"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"}},"type":"object","required":["property_id"],"title":"VoidCreate"},"VoidPaymentRequest":{"properties":{"reason":{"type":"string","minLength":1,"title":"Reason"}},"type":"object","required":["reason"],"title":"VoidPaymentRequest"},"VoidPropertyOption":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"reference":{"type":"string","title":"Reference"},"address_line1":{"type":"string","title":"Address Line1"},"postcode":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Postcode"}},"type":"object","required":["id","reference","address_line1"],"title":"VoidPropertyOption","description":"Minimal property row for the void create form's picker."},"VoidResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"company_id":{"type":"string","format":"uuid","title":"Company Id"},"property_id":{"type":"string","format":"uuid","title":"Property Id"},"reference":{"type":"string","title":"Reference"},"status":{"$ref":"#/components/schemas/VoidStatus"},"category":{"anyOf":[{"$ref":"#/components/schemas/VoidCategory"},{"type":"null"}]},"notified_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Notified Date"},"keys_received_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Keys Received Date"},"inspected_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Inspected Date"},"works_start_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Works Start Date"},"works_complete_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Works Complete Date"},"ready_to_let_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Ready To Let Date"},"let_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Let Date"},"target_days":{"type":"integer","title":"Target Days"},"estimated_cost":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Estimated Cost"},"actual_cost":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Actual Cost"},"linked_job_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Linked Job Id"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"days_void":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Days Void"},"is_overdue":{"type":"boolean","title":"Is Overdue","default":false},"property_reference":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Property Reference"},"property_address":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Property Address"},"items":{"items":{"$ref":"#/components/schemas/VoidWorkItemResponse"},"type":"array","title":"Items","default":[]},"created_at":{"type":"string","format":"date-time","title":"Created At"}},"type":"object","required":["id","company_id","property_id","reference","status","category","notified_date","keys_received_date","inspected_date","works_start_date","works_complete_date","ready_to_let_date","let_date","target_days","estimated_cost","actual_cost","linked_job_id","notes","created_at"],"title":"VoidResponse"},"VoidStatus":{"type":"string","enum":["notified","keys_received","inspected","works_in_progress","works_complete","ready_to_let","let","cancelled"],"title":"VoidStatus"},"VoidSummary":{"properties":{"open_voids":{"type":"integer","title":"Open Voids"},"overdue":{"type":"integer","title":"Overdue"},"average_days_void":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Average Days Void"},"average_turnaround_let":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Average Turnaround Let"},"total_estimated_cost":{"type":"number","title":"Total Estimated Cost"},"total_actual_cost":{"type":"number","title":"Total Actual Cost"},"by_status":{"additionalProperties":{"type":"integer"},"type":"object","title":"By Status"}},"type":"object","required":["open_voids","overdue","average_days_void","average_turnaround_let","total_estimated_cost","total_actual_cost","by_status"],"title":"VoidSummary","description":"The weekly numbers a housing client actually reviews."},"VoidUpdate":{"properties":{"category":{"anyOf":[{"$ref":"#/components/schemas/VoidCategory"},{"type":"null"}]},"status":{"anyOf":[{"$ref":"#/components/schemas/VoidStatus"},{"type":"null"}]},"notified_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Notified Date"},"keys_received_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Keys Received Date"},"inspected_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Inspected Date"},"works_start_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Works Start Date"},"works_complete_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Works Complete Date"},"ready_to_let_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Ready To Let Date"},"let_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Let Date"},"target_days":{"anyOf":[{"type":"integer","maximum":365.0,"minimum":1.0},{"type":"null"}],"title":"Target Days"},"estimated_cost":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Estimated Cost"},"actual_cost":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Actual Cost"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"}},"type":"object","title":"VoidUpdate"},"VoidWorkItemCreate":{"properties":{"description":{"type":"string","minLength":1,"title":"Description"},"trade":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Trade"},"sor_code":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Sor Code"},"cost":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Cost"}},"type":"object","required":["description"],"title":"VoidWorkItemCreate"},"VoidWorkItemResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"void_id":{"type":"string","format":"uuid","title":"Void Id"},"description":{"type":"string","title":"Description"},"trade":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Trade"},"sor_code":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Sor Code"},"cost":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Cost"},"is_complete":{"type":"boolean","title":"Is Complete"},"completed_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Completed Date"}},"type":"object","required":["id","void_id","description","trade","sor_code","cost","is_complete","completed_date"],"title":"VoidWorkItemResponse"},"WarrantyDefectCreate":{"properties":{"title":{"type":"string","title":"Title"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"reported_by":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Reported By"},"severity":{"type":"string","enum":["minor","moderate","major"],"title":"Severity","default":"minor"},"target_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Target Date"}},"type":"object","required":["title"],"title":"WarrantyDefectCreate"},"WarrantyDefectPortalCreate":{"properties":{"title":{"type":"string","title":"Title"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"reported_by":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Reported By"},"severity":{"type":"string","enum":["minor","moderate","major"],"title":"Severity","default":"minor"}},"type":"object","required":["title"],"title":"WarrantyDefectPortalCreate","description":"Submitted by client via portal — reported_via forced to 'portal'."},"WarrantyDefectResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"warranty_period_id":{"type":"string","format":"uuid","title":"Warranty Period Id"},"title":{"type":"string","title":"Title"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"reported_by":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Reported By"},"reported_via":{"type":"string","title":"Reported Via"},"severity":{"type":"string","title":"Severity"},"status":{"type":"string","title":"Status"},"assigned_to":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Assigned To"},"target_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Target Date"},"resolved_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Resolved At"},"resolution_notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Resolution Notes"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"}},"type":"object","required":["id","warranty_period_id","title","description","reported_by","reported_via","severity","status","assigned_to","target_date","resolved_at","resolution_notes","created_at","updated_at"],"title":"WarrantyDefectResponse"},"WarrantyDefectUpdate":{"properties":{"title":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Title"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"severity":{"anyOf":[{"type":"string","enum":["minor","moderate","major"]},{"type":"null"}],"title":"Severity"},"status":{"anyOf":[{"type":"string","enum":["open","acknowledged","in_progress","resolved","rejected"]},{"type":"null"}],"title":"Status"},"assigned_to":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Assigned To"},"target_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Target Date"},"resolution_notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Resolution Notes"}},"type":"object","title":"WarrantyDefectUpdate"},"WarrantyPeriodCreate":{"properties":{"job_id":{"type":"string","format":"uuid","title":"Job Id"},"start_date":{"type":"string","format":"date","title":"Start Date"},"duration_months":{"type":"integer","title":"Duration Months","default":12},"terms":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Terms"}},"type":"object","required":["job_id","start_date"],"title":"WarrantyPeriodCreate"},"WarrantyPeriodResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"job_id":{"type":"string","format":"uuid","title":"Job Id"},"start_date":{"type":"string","format":"date","title":"Start Date"},"end_date":{"type":"string","format":"date","title":"End Date"},"duration_months":{"type":"integer","title":"Duration Months"},"terms":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Terms"},"status":{"type":"string","title":"Status"},"certificate_issued_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Certificate Issued At"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"},"defects":{"items":{"$ref":"#/components/schemas/WarrantyDefectResponse"},"type":"array","title":"Defects","default":[]},"open_count":{"type":"integer","title":"Open Count","default":0},"resolved_count":{"type":"integer","title":"Resolved Count","default":0},"job_number":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Job Number"},"job_title":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Job Title"},"client_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Client Name"}},"type":"object","required":["id","job_id","start_date","end_date","duration_months","terms","status","certificate_issued_at","created_at","updated_at"],"title":"WarrantyPeriodResponse"},"WarrantyPeriodSummary":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"job_id":{"type":"string","format":"uuid","title":"Job Id"},"job_number":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Job Number"},"job_title":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Job Title"},"client_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Client Name"},"start_date":{"type":"string","format":"date","title":"Start Date"},"end_date":{"type":"string","format":"date","title":"End Date"},"status":{"type":"string","title":"Status"},"open_count":{"type":"integer","title":"Open Count"},"resolved_count":{"type":"integer","title":"Resolved Count"},"days_remaining":{"type":"integer","title":"Days Remaining"}},"type":"object","required":["id","job_id","job_number","job_title","client_name","start_date","end_date","status","open_count","resolved_count","days_remaining"],"title":"WarrantyPeriodSummary"},"WarrantyPeriodUpdate":{"properties":{"start_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Start Date"},"duration_months":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Duration Months"},"terms":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Terms"},"status":{"anyOf":[{"type":"string","enum":["active","expired","closed"]},{"type":"null"}],"title":"Status"}},"type":"object","title":"WarrantyPeriodUpdate"},"WarrantyQuoteRequestCreate":{"properties":{"project_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Project Id"},"project_name":{"type":"string","title":"Project Name"},"project_type":{"type":"string","enum":["new_build_residential","conversion","self_build","renovation"],"title":"Project Type"},"contract_value":{"type":"integer","title":"Contract Value"},"unit_count":{"type":"integer","title":"Unit Count","default":1},"postcode":{"type":"string","title":"Postcode"},"completion_date":{"type":"string","title":"Completion Date"},"developer_name":{"type":"string","title":"Developer Name"},"developer_email":{"type":"string","title":"Developer Email"},"construction_method":{"type":"string","enum":["traditional","timber_frame","steel_frame","modular"],"title":"Construction Method","default":"traditional"},"architect_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Architect Name"},"structural_engineer":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Structural Engineer"},"previous_projects":{"type":"string","enum":["0","1","2-5","6-10","11+"],"title":"Previous Projects","default":"0"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"provider_premier":{"type":"boolean","title":"Provider Premier","default":true},"provider_buildzone":{"type":"boolean","title":"Provider Buildzone","default":true},"provider_labc":{"type":"boolean","title":"Provider Labc","default":false},"provider_nhbc":{"type":"boolean","title":"Provider Nhbc","default":false}},"type":"object","required":["project_name","project_type","contract_value","postcode","completion_date","developer_name","developer_email"],"title":"WarrantyQuoteRequestCreate"},"WarrantyQuoteUpdate":{"properties":{"premium_pence":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Premium Pence"},"quote_ref":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Quote Ref"},"valid_until":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Valid Until"},"quote_document_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Quote Document Url"},"referral_fee_pence":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Referral Fee Pence"},"status":{"anyOf":[{"type":"string","enum":["pending","quoted","accepted","declined","expired"]},{"type":"null"}],"title":"Status"}},"type":"object","title":"WarrantyQuoteUpdate"},"WasteItemCreate":{"properties":{"waste_type":{"$ref":"#/components/schemas/WasteType","default":"general"},"quantity_kg":{"type":"number","exclusiveMinimum":0.0,"title":"Quantity Kg"},"disposal_method":{"$ref":"#/components/schemas/DisposalMethod","default":"landfill"},"contractor_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Contractor Name"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"}},"type":"object","required":["quantity_kg"],"title":"WasteItemCreate"},"WasteItemResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"waste_type":{"$ref":"#/components/schemas/WasteType"},"quantity_kg":{"type":"number","title":"Quantity Kg"},"disposal_method":{"$ref":"#/components/schemas/DisposalMethod"},"contractor_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Contractor Name"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"}},"type":"object","required":["id","waste_type","quantity_kg","disposal_method","contractor_name","notes"],"title":"WasteItemResponse"},"WasteTransferCreate":{"properties":{"note_number":{"type":"string","title":"Note Number"},"transfer_date":{"type":"string","format":"date","title":"Transfer Date"},"carrier_name":{"type":"string","title":"Carrier Name"},"carrier_registration":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Carrier Registration"},"carrier_permit":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Carrier Permit"},"destination_site":{"type":"string","title":"Destination Site"},"destination_permit":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Destination Permit"},"waste_description":{"type":"string","title":"Waste Description"},"waste_code":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Waste Code"},"quantity_kg":{"type":"number","title":"Quantity Kg","default":0.0},"is_hazardous":{"type":"boolean","title":"Is Hazardous","default":false},"signed_by":{"type":"string","title":"Signed By"},"received_by":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Received By"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"job_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Job Id"}},"type":"object","required":["note_number","transfer_date","carrier_name","destination_site","waste_description","signed_by"],"title":"WasteTransferCreate"},"WasteTransferUpdate":{"properties":{"note_number":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Note Number"},"transfer_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Transfer Date"},"carrier_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Carrier Name"},"carrier_registration":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Carrier Registration"},"carrier_permit":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Carrier Permit"},"destination_site":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Destination Site"},"destination_permit":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Destination Permit"},"waste_description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Waste Description"},"waste_code":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Waste Code"},"quantity_kg":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Quantity Kg"},"is_hazardous":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Hazardous"},"signed_by":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Signed By"},"received_by":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Received By"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"}},"type":"object","title":"WasteTransferUpdate"},"WasteType":{"type":"string","enum":["concrete","timber","metal","plastic","general","hazardous","soil","plasterboard","other"],"title":"WasteType"},"WebhookEndpointCreate":{"properties":{"url":{"type":"string","maxLength":500,"title":"Url"},"description":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Description"},"events":{"items":{"type":"string"},"type":"array","title":"Events"}},"type":"object","required":["url"],"title":"WebhookEndpointCreate"},"WebhookEndpointResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"url":{"type":"string","title":"Url"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"events":{"items":{"type":"string"},"type":"array","title":"Events"},"is_active":{"type":"boolean","title":"Is Active"},"consecutive_failures":{"type":"integer","title":"Consecutive Failures"},"last_success_at":{"anyOf":[{},{"type":"null"}],"title":"Last Success At"},"last_failure_at":{"anyOf":[{},{"type":"null"}],"title":"Last Failure At"},"last_error":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Last Error"},"disabled_at":{"anyOf":[{},{"type":"null"}],"title":"Disabled At"}},"type":"object","required":["id","url","description","events","is_active","consecutive_failures"],"title":"WebhookEndpointResponse"},"WebhookEndpointUpdate":{"properties":{"url":{"anyOf":[{"type":"string","maxLength":500},{"type":"null"}],"title":"Url"},"description":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Description"},"events":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Events"},"is_active":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Active"}},"type":"object","title":"WebhookEndpointUpdate"},"WebhookEventType":{"properties":{"event":{"type":"string","title":"Event"},"description":{"type":"string","title":"Description"}},"type":"object","required":["event","description"],"title":"WebhookEventType"},"WebhookSubscriptionCreate":{"properties":{"event_type":{"type":"string","title":"Event Type"},"target_url":{"type":"string","title":"Target Url"},"secret":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Secret"}},"type":"object","required":["event_type","target_url"],"title":"WebhookSubscriptionCreate"},"WebhookSubscriptionResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"company_id":{"type":"string","format":"uuid","title":"Company Id"},"app_id":{"type":"string","format":"uuid","title":"App Id"},"event_type":{"type":"string","title":"Event Type"},"target_url":{"type":"string","title":"Target Url"},"is_active":{"type":"boolean","title":"Is Active"},"created_at":{"type":"string","format":"date-time","title":"Created At"}},"type":"object","required":["id","company_id","app_id","event_type","target_url","is_active","created_at"],"title":"WebhookSubscriptionResponse"},"WebsiteSlugUpdate":{"properties":{"website_slug":{"type":"string","title":"Website Slug"}},"type":"object","required":["website_slug"],"title":"WebsiteSlugUpdate"},"WhiteLabelPatch":{"properties":{"custom_domain":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Custom Domain"},"logo_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Logo Url"},"primary_color":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Primary Color"},"secondary_color":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Secondary Color"},"favicon_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Favicon Url"},"email_from_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Email From Name"},"email_from_address":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Email From Address"},"hide_estimark_branding":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Hide Estimark Branding"},"custom_css":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Custom Css"}},"type":"object","title":"WhiteLabelPatch"},"WidgetIn":{"properties":{"widget_type":{"type":"string","title":"Widget Type"},"config":{"type":"object","title":"Config","default":{}},"position_x":{"type":"integer","title":"Position X","default":0},"position_y":{"type":"integer","title":"Position Y","default":0},"width":{"type":"integer","title":"Width","default":1},"height":{"type":"integer","title":"Height","default":1},"is_visible":{"type":"boolean","title":"Is Visible","default":true}},"type":"object","required":["widget_type"],"title":"WidgetIn"},"WidgetPatch":{"properties":{"config":{"anyOf":[{"type":"object"},{"type":"null"}],"title":"Config"},"position_x":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Position X"},"position_y":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Position Y"},"width":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Width"},"height":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Height"},"is_visible":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Visible"}},"type":"object","title":"WidgetPatch"},"WorkDetails":{"properties":{"trades":{"items":{"type":"string"},"type":"array","title":"Trades","default":[]},"regions":{"items":{"type":"string"},"type":"array","title":"Regions","default":[]},"project_types":{"items":{"type":"string"},"type":"array","title":"Project Types","default":[]},"typical_value":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Typical Value"},"concurrent_projects":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Concurrent Projects"},"subcontracting":{"type":"boolean","title":"Subcontracting","default":false}},"type":"object","title":"WorkDetails"},"WorkerAssignRequest":{"properties":{"user_id":{"type":"string","format":"uuid","title":"User Id"}},"type":"object","required":["user_id"],"title":"WorkerAssignRequest"},"WorkerCreate":{"properties":{"name":{"type":"string","maxLength":255,"minLength":1,"title":"Name"},"job_title":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Job Title"},"email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Email"},"phone":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Phone"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"employee_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Employee Id"},"user_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"User Id"}},"type":"object","required":["name"],"title":"WorkerCreate"},"WorkerUpdate":{"properties":{"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name"},"job_title":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Job Title"},"email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Email"},"phone":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Phone"},"is_active":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Active"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"employee_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Employee Id"},"user_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"User Id"}},"type":"object","title":"WorkerUpdate"},"app__api__v1__admin_2fa__MessageResponse":{"properties":{"message":{"type":"string","title":"Message"}},"type":"object","required":["message"],"title":"MessageResponse"},"app__api__v1__admin_2fa__TokenResponse":{"properties":{"access_token":{"type":"string","title":"Access Token"},"token_type":{"type":"string","title":"Token Type","default":"bearer"}},"type":"object","required":["access_token"],"title":"TokenResponse"},"app__api__v1__auth__ChangePasswordRequest":{"properties":{"current_password":{"type":"string","title":"Current Password"},"new_password":{"type":"string","title":"New Password"}},"type":"object","required":["current_password","new_password"],"title":"ChangePasswordRequest"},"app__api__v1__gdpr__MessageResponse":{"properties":{"message":{"type":"string","title":"Message"}},"type":"object","required":["message"],"title":"MessageResponse"},"app__api__v1__ip_whitelist__MessageResponse":{"properties":{"message":{"type":"string","title":"Message"}},"type":"object","required":["message"],"title":"MessageResponse"},"app__api__v1__jobs__WorkerResponse":{"properties":{"user_id":{"type":"string","format":"uuid","title":"User Id"},"email":{"type":"string","title":"Email"},"full_name":{"type":"string","title":"Full Name"},"assigned_at":{"type":"string","format":"date-time","title":"Assigned At"}},"type":"object","required":["user_id","email","full_name","assigned_at"],"title":"WorkerResponse"},"app__schemas__auth__TokenResponse":{"properties":{"access_token":{"type":"string","title":"Access Token"},"token_type":{"type":"string","title":"Token Type","default":"bearer"},"refresh_token":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Refresh Token"}},"type":"object","required":["access_token"],"title":"TokenResponse"},"app__schemas__chat__MessageResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"channel_id":{"type":"string","format":"uuid","title":"Channel Id"},"author_id":{"type":"string","format":"uuid","title":"Author Id"},"author_name":{"type":"string","title":"Author Name"},"body":{"type":"string","title":"Body"},"is_edited":{"type":"boolean","title":"Is Edited"},"edited_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Edited At"},"is_deleted":{"type":"boolean","title":"Is Deleted"},"parent_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Parent Id"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"reply_count":{"type":"integer","title":"Reply Count","default":0}},"type":"object","required":["id","channel_id","author_id","author_name","body","is_edited","edited_at","is_deleted","parent_id","created_at"],"title":"MessageResponse"},"app__schemas__common__MessageResponse":{"properties":{"message":{"type":"string","title":"Message"}},"type":"object","required":["message"],"title":"MessageResponse"},"app__schemas__training__WorkerResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"name":{"type":"string","title":"Name"},"job_title":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Job Title"},"email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Email"},"phone":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Phone"},"is_active":{"type":"boolean","title":"Is Active"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"employee_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Employee Id"},"user_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"User Id"},"qualifications":{"items":{"$ref":"#/components/schemas/QualificationSummary"},"type":"array","title":"Qualifications","default":[]},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"}},"type":"object","required":["id","name","job_title","email","phone","is_active","notes","created_at","updated_at"],"title":"WorkerResponse"},"app__schemas__user__ChangePasswordRequest":{"properties":{"current_password":{"type":"string","title":"Current Password"},"new_password":{"type":"string","maxLength":128,"minLength":8,"title":"New Password"}},"type":"object","required":["current_password","new_password"],"title":"ChangePasswordRequest"}},"securitySchemes":{"ApiKeyAuth":{"type":"apiKey","in":"header","name":"X-API-Key"}}},"security":[{"ApiKeyAuth":[]}]}