{"businesses_list":{"$schema":"https://json-schema.org/draft/2020-12/schema","type":"object","properties":{"limit":{"default":50,"type":"integer","minimum":1,"maximum":100},"offset":{"default":0,"type":"integer","minimum":0,"maximum":9007199254740991}},"required":["limit","offset"],"additionalProperties":false},"business_get":{"$schema":"https://json-schema.org/draft/2020-12/schema","type":"object","properties":{"business_id":{"description":"Omit for your own business; use businesses_list for shared business IDs.","type":"string","minLength":1,"maxLength":128}},"additionalProperties":false},"business_set":{"$schema":"https://json-schema.org/draft/2020-12/schema","type":"object","properties":{"business_id":{"description":"Omit for your own business; use businesses_list for shared business IDs.","type":"string","minLength":1,"maxLength":128},"request_id":{"type":"string","minLength":8,"maxLength":128,"description":"Stable ID for this action; reuse only for identical retries."},"name":{"type":"string","minLength":1,"maxLength":2000},"currency":{"type":"string","pattern":"^[A-Z]{3}$"},"billing_address":{"type":"string","minLength":1,"maxLength":2000},"invoice_preferences":{"type":"object","properties":{"prefix":{"default":"","type":"string","pattern":"^[A-Za-z0-9_-]{0,24}$"},"number_padding":{"default":1,"type":"integer","minimum":1,"maximum":12},"starting_number":{"default":1,"type":"integer","minimum":1,"maximum":999999999},"default_note":{"type":"string","minLength":1,"maxLength":2000},"payment_instructions":{"type":"string","minLength":1,"maxLength":2000}},"required":["prefix","number_padding","starting_number"],"additionalProperties":false}},"required":["request_id","name","currency"],"additionalProperties":false},"tax_profile_set":{"$schema":"https://json-schema.org/draft/2020-12/schema","type":"object","properties":{"business_id":{"description":"Omit for your own business; use businesses_list for shared business IDs.","type":"string","minLength":1,"maxLength":128},"request_id":{"type":"string","minLength":8,"maxLength":128,"description":"Stable ID for this action; reuse only for identical retries."},"profile":{"type":"object","properties":{"country":{"type":"string","pattern":"^[A-Z]{2}$"},"region":{"type":"string","minLength":1,"maxLength":2000},"registration_status":{"type":"string","enum":["registered","not_registered","unknown"]},"registrations":{"default":[],"maxItems":20,"type":"array","items":{"type":"object","properties":{"jurisdiction":{"type":"string","minLength":1,"maxLength":2000},"number":{"type":"string","minLength":1,"maxLength":2000},"effective_from":{"type":"string","pattern":"^\\d{4}-\\d{2}-\\d{2}$"}},"required":["jurisdiction","number","effective_from"],"additionalProperties":false}},"reviewed_on":{"type":"string","pattern":"^\\d{4}-\\d{2}-\\d{2}$"},"notes":{"type":"string","minLength":1,"maxLength":2000}},"required":["country","registration_status","registrations","reviewed_on","notes"],"additionalProperties":false}},"required":["request_id","profile"],"additionalProperties":false},"tax_guide":{"$schema":"https://json-schema.org/draft/2020-12/schema","type":"object","properties":{"country":{"type":"string","pattern":"^[A-Z]{2}$"}},"additionalProperties":false},"team_list":{"$schema":"https://json-schema.org/draft/2020-12/schema","type":"object","properties":{"business_id":{"description":"Omit for your own business; use businesses_list for shared business IDs.","type":"string","minLength":1,"maxLength":128},"limit":{"default":50,"type":"integer","minimum":1,"maximum":100},"offset":{"default":0,"type":"integer","minimum":0,"maximum":9007199254740991}},"required":["limit","offset"],"additionalProperties":false},"team_invite":{"$schema":"https://json-schema.org/draft/2020-12/schema","type":"object","properties":{"business_id":{"description":"Omit for your own business; use businesses_list for shared business IDs.","type":"string","minLength":1,"maxLength":128},"request_id":{"type":"string","minLength":8,"maxLength":128,"description":"Stable ID for this action; reuse only for identical retries."},"email":{"type":"string","maxLength":254,"format":"email","pattern":"^(?:[A-Za-z0-9_'+\\-]+\\.)*[A-Za-z0-9_'+\\-]*[A-Za-z0-9_+-]@(?:[A-Za-z0-9][A-Za-z0-9\\-]*\\.)+[A-Za-z]{2,}$"},"role":{"type":"string","enum":["editor","viewer"]}},"required":["request_id","email","role"],"additionalProperties":false},"team_accept":{"$schema":"https://json-schema.org/draft/2020-12/schema","type":"object","properties":{"business_id":{"description":"Omit for your own business; use businesses_list for shared business IDs.","type":"string","minLength":1,"maxLength":128},"request_id":{"type":"string","minLength":8,"maxLength":128,"description":"Stable ID for this action; reuse only for identical retries."},"invitation_id":{"type":"string","minLength":1,"maxLength":128}},"required":["request_id","invitation_id"],"additionalProperties":false},"team_member_set":{"$schema":"https://json-schema.org/draft/2020-12/schema","type":"object","properties":{"business_id":{"description":"Omit for your own business; use businesses_list for shared business IDs.","type":"string","minLength":1,"maxLength":128},"request_id":{"type":"string","minLength":8,"maxLength":128,"description":"Stable ID for this action; reuse only for identical retries."},"member_id":{"type":"string","minLength":1,"maxLength":128},"role":{"type":"string","enum":["editor","viewer","removed"]}},"required":["request_id","member_id","role"],"additionalProperties":false},"clients_list":{"$schema":"https://json-schema.org/draft/2020-12/schema","type":"object","properties":{"business_id":{"description":"Omit for your own business; use businesses_list for shared business IDs.","type":"string","minLength":1,"maxLength":128},"limit":{"default":50,"type":"integer","minimum":1,"maximum":100},"offset":{"default":0,"type":"integer","minimum":0,"maximum":9007199254740991}},"required":["limit","offset"],"additionalProperties":false},"client_save":{"$schema":"https://json-schema.org/draft/2020-12/schema","type":"object","properties":{"business_id":{"description":"Omit for your own business; use businesses_list for shared business IDs.","type":"string","minLength":1,"maxLength":128},"request_id":{"type":"string","minLength":8,"maxLength":128,"description":"Stable ID for this action; reuse only for identical retries."},"client_id":{"type":"string","minLength":1,"maxLength":128},"name":{"type":"string","minLength":1,"maxLength":2000},"email":{"type":"string","maxLength":254,"format":"email","pattern":"^(?:[A-Za-z0-9_'+\\-]+\\.)*[A-Za-z0-9_'+\\-]*[A-Za-z0-9_+-]@(?:[A-Za-z0-9][A-Za-z0-9\\-]*\\.)+[A-Za-z]{2,}$"},"billing_address":{"type":"string","minLength":1,"maxLength":2000},"country":{"type":"string","pattern":"^[A-Z]{2}$"},"region":{"type":"string","minLength":1,"maxLength":2000},"postal_code":{"type":"string","minLength":1,"maxLength":2000},"customer_type":{"default":"unknown","type":"string","enum":["business","consumer","unknown"]},"tax_ids":{"default":[],"maxItems":20,"type":"array","items":{"type":"string","minLength":1,"maxLength":2000}},"tax_evidence":{"type":"string","minLength":1,"maxLength":2000}},"required":["request_id","name","customer_type","tax_ids"],"additionalProperties":false},"billable_record":{"$schema":"https://json-schema.org/draft/2020-12/schema","type":"object","properties":{"business_id":{"description":"Omit for your own business; use businesses_list for shared business IDs.","type":"string","minLength":1,"maxLength":128},"request_id":{"type":"string","minLength":8,"maxLength":128,"description":"Stable ID for this action; reuse only for identical retries."},"item_id":{"type":"string","minLength":1,"maxLength":128},"client_id":{"type":"string","minLength":1,"maxLength":128},"kind":{"type":"string","enum":["time","expense","ai_usage"]},"description":{"type":"string","minLength":1,"maxLength":2000},"quantity":{"type":"string","pattern":"^\\d{1,9}(?:\\.\\d{1,6})?$"},"unit":{"type":"string","minLength":1,"maxLength":40},"amount_minor":{"type":"integer","minimum":0,"maximum":1000000000000},"rate_minor":{"type":"integer","minimum":0,"maximum":1000000000000},"cost_minor":{"type":"integer","minimum":0,"maximum":1000000000000},"measurement":{"type":"string","enum":["measured","estimated"]},"reference":{"type":"string","minLength":1,"maxLength":2000}},"required":["request_id","client_id","kind","description","quantity","unit","amount_minor"],"additionalProperties":false},"billables_list":{"$schema":"https://json-schema.org/draft/2020-12/schema","type":"object","properties":{"business_id":{"description":"Omit for your own business; use businesses_list for shared business IDs.","type":"string","minLength":1,"maxLength":128},"limit":{"default":50,"type":"integer","minimum":1,"maximum":100},"offset":{"default":0,"type":"integer","minimum":0,"maximum":9007199254740991},"client_id":{"type":"string","minLength":1,"maxLength":128},"state":{"type":"string","enum":["unbilled","reserved","partial","invoiced"]}},"required":["limit","offset"],"additionalProperties":false},"expense_record":{"$schema":"https://json-schema.org/draft/2020-12/schema","type":"object","properties":{"business_id":{"description":"Omit for your own business; use businesses_list for shared business IDs.","type":"string","minLength":1,"maxLength":128},"request_id":{"type":"string","minLength":8,"maxLength":128,"description":"Stable ID for this action; reuse only for identical retries."},"expense_id":{"type":"string","minLength":1,"maxLength":128},"vendor":{"type":"string","minLength":1,"maxLength":2000},"category":{"type":"string","minLength":1,"maxLength":2000},"description":{"type":"string","minLength":1,"maxLength":2000},"incurred_on":{"type":"string","pattern":"^\\d{4}-\\d{2}-\\d{2}$"},"cost_minor":{"type":"integer","minimum":0,"maximum":1000000000000},"client_id":{"type":"string","minLength":1,"maxLength":128},"billable_amount_minor":{"type":"integer","minimum":0,"maximum":1000000000000},"reference":{"type":"string","minLength":1,"maxLength":2000}},"required":["request_id","vendor","category","description","incurred_on","cost_minor"],"additionalProperties":false},"expenses_list":{"$schema":"https://json-schema.org/draft/2020-12/schema","type":"object","properties":{"business_id":{"description":"Omit for your own business; use businesses_list for shared business IDs.","type":"string","minLength":1,"maxLength":128},"limit":{"default":50,"type":"integer","minimum":1,"maximum":100},"offset":{"default":0,"type":"integer","minimum":0,"maximum":9007199254740991},"client_id":{"type":"string","minLength":1,"maxLength":128}},"required":["limit","offset"],"additionalProperties":false},"invoice_draft":{"$schema":"https://json-schema.org/draft/2020-12/schema","type":"object","properties":{"business_id":{"description":"Omit for your own business; use businesses_list for shared business IDs.","type":"string","minLength":1,"maxLength":128},"request_id":{"type":"string","minLength":8,"maxLength":128,"description":"Stable ID for this action; reuse only for identical retries."},"client_id":{"type":"string","minLength":1,"maxLength":128},"lines":{"minItems":1,"maxItems":100,"type":"array","items":{"type":"object","properties":{"item_id":{"type":"string","minLength":1,"maxLength":128},"amount_minor":{"type":"integer","minimum":0,"maximum":1000000000000},"discount":{"oneOf":[{"type":"object","properties":{"kind":{"type":"string","const":"fixed"},"amount_minor":{"type":"integer","minimum":0,"maximum":1000000000000}},"required":["kind","amount_minor"],"additionalProperties":false},{"type":"object","properties":{"kind":{"type":"string","const":"percent"},"rate_ppm":{"type":"integer","minimum":0,"maximum":1000000}},"required":["kind","rate_ppm"],"additionalProperties":false}]},"tax":{"type":"object","properties":{"treatment":{"type":"string","enum":["taxable","zero_rated","exempt","out_of_scope","reverse_charge","not_registered"]},"jurisdiction":{"type":"string","minLength":1,"maxLength":2000},"reason":{"type":"string","minLength":1,"maxLength":2000},"service_category":{"type":"string","minLength":1,"maxLength":2000},"evidence":{"default":[],"maxItems":10,"type":"array","items":{"type":"string","minLength":1,"maxLength":2000}},"mode":{"default":"exclusive","type":"string","enum":["exclusive","inclusive"]},"components":{"default":[],"maxItems":5,"type":"array","items":{"type":"object","properties":{"name":{"type":"string","minLength":1,"maxLength":80},"rate_ppm":{"type":"integer","minimum":1,"maximum":1000000,"description":"Parts per million: 20% = 200000; 8.875% = 88750."},"taxable_fraction_ppm":{"default":1000000,"type":"integer","minimum":1,"maximum":1000000}},"required":["name","rate_ppm","taxable_fraction_ppm"],"additionalProperties":false}}},"required":["treatment","jurisdiction","reason","service_category","evidence","mode","components"],"additionalProperties":false}},"required":["item_id","amount_minor"],"additionalProperties":false}},"discount":{"oneOf":[{"type":"object","properties":{"kind":{"type":"string","const":"fixed"},"amount_minor":{"type":"integer","minimum":0,"maximum":1000000000000}},"required":["kind","amount_minor"],"additionalProperties":false},{"type":"object","properties":{"kind":{"type":"string","const":"percent"},"rate_ppm":{"type":"integer","minimum":0,"maximum":1000000}},"required":["kind","rate_ppm"],"additionalProperties":false}]},"supply_date":{"type":"string","pattern":"^\\d{4}-\\d{2}-\\d{2}$"},"due_date":{"type":"string","pattern":"^\\d{4}-\\d{2}-\\d{2}$"},"note":{"type":"string","minLength":1,"maxLength":2000}},"required":["request_id","client_id","lines","supply_date","due_date"],"additionalProperties":false},"invoice_get":{"$schema":"https://json-schema.org/draft/2020-12/schema","type":"object","properties":{"business_id":{"description":"Omit for your own business; use businesses_list for shared business IDs.","type":"string","minLength":1,"maxLength":128},"invoice_id":{"type":"string","minLength":1,"maxLength":128}},"required":["invoice_id"],"additionalProperties":false},"invoice_check":{"$schema":"https://json-schema.org/draft/2020-12/schema","type":"object","properties":{"business_id":{"description":"Omit for your own business; use businesses_list for shared business IDs.","type":"string","minLength":1,"maxLength":128},"invoice_id":{"type":"string","minLength":1,"maxLength":128}},"required":["invoice_id"],"additionalProperties":false},"invoices_list":{"$schema":"https://json-schema.org/draft/2020-12/schema","type":"object","properties":{"business_id":{"description":"Omit for your own business; use businesses_list for shared business IDs.","type":"string","minLength":1,"maxLength":128},"limit":{"default":50,"type":"integer","minimum":1,"maximum":100},"offset":{"default":0,"type":"integer","minimum":0,"maximum":9007199254740991},"status":{"type":"string","enum":["draft","issued","cancelled"]}},"required":["limit","offset"],"additionalProperties":false},"invoice_issue":{"$schema":"https://json-schema.org/draft/2020-12/schema","type":"object","properties":{"business_id":{"description":"Omit for your own business; use businesses_list for shared business IDs.","type":"string","minLength":1,"maxLength":128},"request_id":{"type":"string","minLength":8,"maxLength":128,"description":"Stable ID for this action; reuse only for identical retries."},"invoice_id":{"type":"string","minLength":1,"maxLength":128},"expected_total_minor":{"type":"integer","minimum":0,"maximum":1000000000000},"confirmed":{"type":"boolean","const":true,"description":"Only after the user approves this draft and its exact total."}},"required":["request_id","invoice_id","expected_total_minor","confirmed"],"additionalProperties":false},"invoice_cancel_draft":{"$schema":"https://json-schema.org/draft/2020-12/schema","type":"object","properties":{"business_id":{"description":"Omit for your own business; use businesses_list for shared business IDs.","type":"string","minLength":1,"maxLength":128},"request_id":{"type":"string","minLength":8,"maxLength":128,"description":"Stable ID for this action; reuse only for identical retries."},"invoice_id":{"type":"string","minLength":1,"maxLength":128},"reason":{"type":"string","minLength":1,"maxLength":2000}},"required":["request_id","invoice_id","reason"],"additionalProperties":false},"payment_record":{"$schema":"https://json-schema.org/draft/2020-12/schema","type":"object","properties":{"business_id":{"description":"Omit for your own business; use businesses_list for shared business IDs.","type":"string","minLength":1,"maxLength":128},"request_id":{"type":"string","minLength":8,"maxLength":128,"description":"Stable ID for this action; reuse only for identical retries."},"invoice_id":{"type":"string","minLength":1,"maxLength":128},"amount_minor":{"type":"integer","minimum":0,"maximum":1000000000000},"received_on":{"type":"string","pattern":"^\\d{4}-\\d{2}-\\d{2}$"},"reference":{"type":"string","minLength":1,"maxLength":2000,"description":"Unique business-wide payment reference. Reuse when reporting the same payment."}},"required":["request_id","invoice_id","amount_minor","received_on","reference"],"additionalProperties":false},"payments_list":{"$schema":"https://json-schema.org/draft/2020-12/schema","type":"object","properties":{"business_id":{"description":"Omit for your own business; use businesses_list for shared business IDs.","type":"string","minLength":1,"maxLength":128},"limit":{"default":50,"type":"integer","minimum":1,"maximum":100},"offset":{"default":0,"type":"integer","minimum":0,"maximum":9007199254740991},"invoice_id":{"type":"string","minLength":1,"maxLength":128}},"required":["limit","offset"],"additionalProperties":false},"records_export":{"$schema":"https://json-schema.org/draft/2020-12/schema","type":"object","properties":{"business_id":{"description":"Omit for your own business; use businesses_list for shared business IDs.","type":"string","minLength":1,"maxLength":128},"limit":{"default":50,"type":"integer","minimum":1,"maximum":100},"offset":{"default":0,"type":"integer","minimum":0,"maximum":9007199254740991},"kind":{"type":"string","enum":["business","client","billable","expense","invoice","payment","audit"]}},"required":["limit","offset","kind"],"additionalProperties":false}}