{"openapi":"3.1.0","info":{"title":"Firmado API","version":"1","description":"Firmado's API: the same one the app uses. Every route here works on one organization, the API key's.\n\n**Authentication.** Send an organization API key (Settings › API keys) in `X-Api-Key: fmd_...` or `Authorization: Bearer fmd_...`. Each key has permissions per feature (read, create, update, delete); the action comes from the method (GET reads, POST creates, PUT and PATCH update, DELETE deletes) unless an operation says otherwise (`x-action`).\n\n**Errors** are always `{ \"error\": { \"code\", \"message\", \"details\" } }`. Translate and act by `code`.\n\n**Rate limit.** All keys of an organization share its plan's requests per minute. Answers carry `X-RateLimit-Limit`, `X-RateLimit-Remaining` and `X-RateLimit-Reset`; past it, 429 with `Retry-After`.\n\n**Conventions.** Money is in integer minor units (cents). Dates and times are ISO 8601. Ids are UUIDs. Lists are paged with `page` and `pageSize` (up to 100).\n\n**Webhooks** send the events listed in `x-webhook-events`, signed in the `Firmado-Signature` header."},"servers":[{"url":"https://api.firmado.app"}],"security":[{"apiKey":[]},{"bearer":[]}],"tags":[{"name":"catalogPages","description":"Public service catalogs and their presentation."},{"name":"catalogRequests","description":"Quote requests submitted through public catalogs."},{"name":"postAutomations","description":"Automatic replies to comments on social posts."},{"name":"tasks","description":"CRM tasks with owners, due dates and priorities."},{"name":"contacts","description":"People in the CRM: emails, phones, tags, lists, custom properties, history."},{"name":"companies","description":"Companies in the CRM and the contacts working there."},{"name":"lists","description":"Static contact lists and their members."},{"name":"deals","description":"Proposals (deals): content, packages, recipients, sending, status, questions from clients."},{"name":"invoices","description":"Invoices: items, sending, payments recorded by hand."},{"name":"approvals","description":"Documents sent for approval and who approved them."},{"name":"contracts","description":"Contracts: templates (rich text with {{fields.key}}, {{contact.firstName}}, {{contract.items}}-style variables, fields filled by the team or the signer, prices and services) and contracts made from them, sent to one or more signers who sign by drawing or typing; each sent signer uses the monthly signatures allowance."},{"name":"calendarEvents","description":"Saved calendar events (date, time zone, place or link, repeat, reminder): each has a page where people add it to Google, Outlook, Office 365, Yahoo or Apple calendars, a hosted .ics file, and views and adds per day."},{"name":"socialPosts","description":"The social calendar (editorial calendar): posts (caption, pictures uploaded first, first comment, date) for the connected Facebook Pages and Instagram accounts. Drafts are scheduled with POST :id/schedule, which sends them for approval when the organization requires it; approvers approve or request changes. Firmado publishes them at their time and records each account's result and engagement numbers. Each account reached uses one of the monthly social posts."},{"name":"loyalty","description":"The loyalty program (Pro): rules (points per purchase and per amount, tiers with multipliers, expiration), rewards (items, discounts, cashback) and members, one per contact, with their points. Purchases earn by themselves: payments in Firmado and sales made outside it (recorded as manual payments, a payments feature). Rewards are taken with POST redemptions and handed over with fulfill. Each member has a card page."},{"name":"contactEvents","description":"Contact events: things a contact did, as the organization's own systems report them (signed_up, cart.abandoned, app:opened), with flat properties, when it happened and a channel. The contact by id or by email (created with a name). A `reference` makes each one count once. They show on the contact's page; loyalty can give points for them. Each uses one of the monthly contact events."},{"name":"services","description":"Catalog services and product SKUs (kind=product), prices, product groups and photos. Products and services share the services allowance."},{"name":"packages","description":"Catalog packages combining services and products, with prices and photos."},{"name":"appointments","description":"Meetings on the calendar."},{"name":"bookingPages","description":"Public pages where contacts book meetings."},{"name":"forms","description":"Forms and their submissions."},{"name":"surveys","description":"Surveys (NPS, satisfaction), invited contacts and answers."},{"name":"linkPages","description":"Link pages (\"link in bio\"): their links, look, and daily views and clicks."},{"name":"microsites","description":"The microsite (Pro, one per organization): a small web page built from blocks (rows of columns: headings, text, buttons, images, videos, forms, catalog items...), its address, and daily views and clicks."},{"name":"shortLinks","description":"Short links that redirect and count clicks, to measure links used outside Firmado."},{"name":"qrCodes","description":"Saved QR codes: what each holds (a link, text, contact card, Wi-Fi, event...), its look, and the short link that counts its scans."},{"name":"emailSignatures","description":"Saved email signatures: who each is for (name, job, contacts), its pictures, social links, meeting link, the text below it and its look."},{"name":"sharedFiles","description":"Files (PDF, spreadsheets, ebooks...) shared from a public page, open, behind a form or a payment, with their numbers."},{"name":"files","description":"The organization's files: the library of images, PDFs and documents it uploads (public addresses, used in emails), and everything else that takes its storage, by kind. Only library files can be renamed or deleted here."},{"name":"projects","description":"Projects (campaigns and the like): dates, owners, notes, and the records of other features linked to them, with their numbers."},{"name":"emails","description":"Emails to contacts from the organization's own domain: templates (drag-and-drop documents with {{contact.firstName}}-style variables), marketing campaigns to lists and tags (only contacts who consented), automations, and sending a template to one contact (transactional by default). Each email uses the monthly allowance."},{"name":"availability","description":"Members’ working hours."},{"name":"customProperties","description":"Custom fields defined for contacts, companies and deals."},{"name":"dashboard","description":"Summaries: proposals, sales, marketing and calendar numbers."},{"name":"payments","description":"Stripe payments received through proposals and invoices, refunds, and sales made outside Firmado (manual payments): typed by the team or sent from a shop or POS, the buyer by contact id or by email (created with a name), a unique `reference` so each sale comes in once and can be found or deleted by it."},{"name":"organization","description":"The organization itself: name, settings, members."}],"paths":{"/v1/appointments":{"get":{"operationId":"GET /v1/appointments","summary":"Lists the meetings on the calendar between two dates, by host or for everyone.","tags":["appointments"],"x-feature":"appointments","x-action":"read","parameters":[{"name":"from","in":"query","required":false,"schema":{"type":"string","format":"date-time"}},{"name":"to","in":"query","required":false,"schema":{"type":"string","format":"date-time"}},{"name":"hostId","in":"query","required":false,"schema":{"type":"string","minLength":1}},{"name":"contactId","in":"query","required":false,"schema":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"}},{"name":"dealId","in":"query","required":false,"schema":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"}},{"name":"projectId","in":"query","required":false,"schema":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"}},{"name":"status","in":"query","required":false,"schema":{"type":"string","enum":["awaiting_payment","pending","scheduled","completed","canceled","no_show"]}},{"name":"includeCanceled","in":"query","required":false,"schema":{"type":"string"}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"items":{"properties":{"allDay":{"type":"boolean"},"bookingPage":{"properties":{"id":{"format":"uuid","type":"string"},"title":{"type":"string"}},"required":["id","title"],"type":["null","object"]},"bookingPageId":{"format":"uuid","type":["null","string"]},"cancelReason":{"type":["null","string"]},"canceledAt":{"format":"date-time","type":["null","string"]},"canceledBy":{"type":["null","string"]},"catalogRequestId":{"type":"null"},"contact":{"properties":{"id":{"format":"uuid","type":"string"},"name":{"type":"string"}},"required":["id","name"],"type":["null","object"]},"contactId":{"format":"uuid","type":["null","string"]},"createdAt":{"format":"date-time","type":"string"},"createdBy":{"format":"uuid","type":["null","string"]},"deal":{"type":"null"},"dealId":{"type":"null"},"description":{"type":"null"},"endsAt":{"format":"date-time","type":"string"},"guestEmail":{"format":"email","type":["null","string"]},"guestName":{"type":["null","string"]},"guestNotes":{"type":"null"},"guestPhone":{"type":"null"},"host":{"properties":{"id":{"format":"uuid","type":"string"},"image":{"type":"null"},"name":{"type":"string"}},"required":["id","image","name"],"type":["null","object"]},"hostId":{"format":"uuid","type":["null","string"]},"id":{"format":"uuid","type":"string"},"location":{"format":"uri","type":["null","string"]},"locationType":{"type":["null","string"]},"payment":{"type":"null"},"source":{"type":"string"},"startsAt":{"format":"date-time","type":"string"},"status":{"type":"string"},"timezone":{"type":["null","string"]},"title":{"type":"string"},"updatedAt":{"format":"date-time","type":"string"},"updatedBy":{"format":"uuid","type":["null","string"]}},"required":["allDay","bookingPage","bookingPageId","cancelReason","canceledAt","canceledBy","catalogRequestId","contact","contactId","createdAt","createdBy","deal","dealId","description","endsAt","guestEmail","guestName","guestNotes","guestPhone","host","hostId","id","location","locationType","payment","source","startsAt","status","timezone","title","updatedAt","updatedBy"],"type":"object"},"type":"array"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"post":{"operationId":"POST /v1/appointments","summary":"Books a meeting with a contact for one of the members.","tags":["appointments"],"x-feature":"appointments","x-action":"create","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"title":{"type":"string","minLength":1,"maxLength":200},"description":{"anyOf":[{"type":"string","maxLength":5000},{"type":"null"}]},"startsAt":{"type":"string","format":"date-time"},"endsAt":{"type":"string","format":"date-time"},"timezone":{"anyOf":[{"type":"string","maxLength":64},{"type":"null"}]},"hostId":{"anyOf":[{"type":"string","minLength":1},{"type":"null"}]},"contactId":{"anyOf":[{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},{"type":"null"}]},"dealId":{"anyOf":[{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},{"type":"null"}]},"locationType":{"anyOf":[{"type":"string","enum":["video","phone","in_person","other"]},{"type":"null"}]},"location":{"anyOf":[{"type":"string","maxLength":500},{"type":"null"}]}},"required":["title","startsAt","endsAt"]}}}},"responses":{"201":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"allDay":{"type":"boolean"},"bookingPage":{"type":"null"},"bookingPageId":{"type":"null"},"cancelReason":{"type":"null"},"canceledAt":{"type":"null"},"canceledBy":{"type":"null"},"catalogRequestId":{"type":"null"},"contact":{"properties":{"id":{"format":"uuid","type":"string"},"name":{"type":"string"}},"required":["id","name"],"type":["null","object"]},"contactId":{"format":"uuid","type":["null","string"]},"createdAt":{"format":"date-time","type":"string"},"createdBy":{"format":"uuid","type":"string"},"deal":{"type":"null"},"dealId":{"type":"null"},"description":{"type":["null","string"]},"endsAt":{"format":"date-time","type":"string"},"guestEmail":{"type":"null"},"guestName":{"type":"null"},"guestNotes":{"type":"null"},"guestPhone":{"type":"null"},"host":{"properties":{"id":{"format":"uuid","type":"string"},"image":{"type":"null"},"name":{"type":"string"}},"required":["id","image","name"],"type":"object"},"hostId":{"format":"uuid","type":"string"},"id":{"format":"uuid","type":"string"},"location":{"format":"uri","type":["null","string"]},"locationType":{"type":"null"},"payment":{"type":"null"},"source":{"type":"string"},"startsAt":{"format":"date-time","type":"string"},"status":{"type":"string"},"timezone":{"type":"null"},"title":{"type":"string"},"updatedAt":{"format":"date-time","type":"string"},"updatedBy":{"format":"uuid","type":"string"}},"required":["allDay","bookingPage","bookingPageId","cancelReason","canceledAt","canceledBy","catalogRequestId","contact","contactId","createdAt","createdBy","deal","dealId","description","endsAt","guestEmail","guestName","guestNotes","guestPhone","host","hostId","id","location","locationType","payment","source","startsAt","status","timezone","title","updatedAt","updatedBy"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/appointments/{id}":{"delete":{"operationId":"DELETE /v1/appointments/{id}","summary":"Deletes a meeting.","tags":["appointments"],"x-feature":"appointments","x-action":"delete","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"204":{"description":"Done, with no content."},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"get":{"operationId":"GET /v1/appointments/{id}","summary":"Returns a meeting.","tags":["appointments"],"x-feature":"appointments","x-action":"read","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"patch":{"operationId":"PATCH /v1/appointments/{id}","summary":"Changes a meeting: time, host, contact, place or notes.","tags":["appointments"],"x-feature":"appointments","x-action":"update","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"title":{"type":"string","minLength":1,"maxLength":200},"description":{"anyOf":[{"type":"string","maxLength":5000},{"type":"null"}]},"startsAt":{"type":"string","format":"date-time"},"endsAt":{"type":"string","format":"date-time"},"timezone":{"anyOf":[{"type":"string","maxLength":64},{"type":"null"}]},"hostId":{"anyOf":[{"type":"string","minLength":1},{"type":"null"}]},"contactId":{"anyOf":[{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},{"type":"null"}]},"dealId":{"anyOf":[{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},{"type":"null"}]},"locationType":{"anyOf":[{"type":"string","enum":["video","phone","in_person","other"]},{"type":"null"}]},"location":{"anyOf":[{"type":"string","maxLength":500},{"type":"null"}]},"status":{"type":"string","enum":["pending","scheduled","completed","canceled","no_show"]},"cancelReason":{"anyOf":[{"type":"string","maxLength":1000},{"type":"null"}]},"refund":{"type":"boolean"}}}}}},"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"allDay":{"type":"boolean"},"bookingPage":{"properties":{"id":{"format":"uuid","type":"string"},"title":{"type":"string"}},"required":["id","title"],"type":["null","object"]},"bookingPageId":{"format":"uuid","type":["null","string"]},"cancelReason":{"type":["null","string"]},"canceledAt":{"format":"date-time","type":["null","string"]},"canceledBy":{"type":["null","string"]},"catalogRequestId":{"type":"null"},"contact":{"properties":{"id":{"format":"uuid","type":"string"},"name":{"type":"string"}},"required":["id","name"],"type":["null","object"]},"contactId":{"format":"uuid","type":["null","string"]},"createdAt":{"format":"date-time","type":"string"},"createdBy":{"format":"uuid","type":["null","string"]},"deal":{"type":"null"},"dealId":{"type":"null"},"description":{"type":["null","string"]},"endsAt":{"format":"date-time","type":"string"},"guestEmail":{"format":"email","type":["null","string"]},"guestName":{"type":["null","string"]},"guestNotes":{"type":"null"},"guestPhone":{"type":"null"},"host":{"properties":{"id":{"format":"uuid","type":"string"},"image":{"type":"null"},"name":{"type":"string"}},"required":["id","image","name"],"type":"object"},"hostId":{"format":"uuid","type":"string"},"id":{"format":"uuid","type":"string"},"location":{"format":"uri","type":["null","string"]},"locationType":{"type":"null"},"payment":{"properties":{"amount":{"type":"integer"},"currency":{"type":"string"},"paidAt":{"format":"date-time","type":"string"},"status":{"type":"string"}},"required":["amount","currency","paidAt","status"],"type":["null","object"]},"source":{"type":"string"},"startsAt":{"format":"date-time","type":"string"},"status":{"type":"string"},"timezone":{"type":"null"},"title":{"type":"string"},"updatedAt":{"format":"date-time","type":"string"},"updatedBy":{"format":"uuid","type":"string"}},"required":["allDay","bookingPage","bookingPageId","cancelReason","canceledAt","canceledBy","catalogRequestId","contact","contactId","createdAt","createdBy","deal","dealId","description","endsAt","guestEmail","guestName","guestNotes","guestPhone","host","hostId","id","location","locationType","payment","source","startsAt","status","timezone","title","updatedAt","updatedBy"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/appointments/{id}/confirm":{"post":{"operationId":"POST /v1/appointments/{id}/confirm","summary":"Confirms a meeting requested through a booking page, with where it will happen.","tags":["appointments"],"x-feature":"appointments","x-action":"update","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"locationType":{"type":"string","enum":["video","phone","in_person","other"]},"location":{"type":"string","minLength":1,"maxLength":500}},"required":["locationType","location"]}}}},"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"allDay":{"type":"boolean"},"bookingPage":{"properties":{"id":{"format":"uuid","type":"string"},"title":{"type":"string"}},"required":["id","title"],"type":"object"},"bookingPageId":{"format":"uuid","type":"string"},"cancelReason":{"type":"null"},"canceledAt":{"type":"null"},"canceledBy":{"type":"null"},"catalogRequestId":{"type":"null"},"contact":{"properties":{"id":{"format":"uuid","type":"string"},"name":{"type":"string"}},"required":["id","name"],"type":"object"},"contactId":{"format":"uuid","type":"string"},"createdAt":{"format":"date-time","type":"string"},"createdBy":{"type":"null"},"deal":{"type":"null"},"dealId":{"type":"null"},"description":{"type":"null"},"endsAt":{"format":"date-time","type":"string"},"guestEmail":{"format":"email","type":"string"},"guestName":{"type":"string"},"guestNotes":{"type":"null"},"guestPhone":{"type":"null"},"host":{"properties":{"id":{"format":"uuid","type":"string"},"image":{"type":"null"},"name":{"type":"string"}},"required":["id","name","image"],"type":"object"},"hostId":{"format":"uuid","type":"string"},"id":{"format":"uuid","type":"string"},"location":{"format":"uri","type":"string"},"locationType":{"type":"string"},"payment":{"type":"null"},"source":{"type":"string"},"startsAt":{"format":"date-time","type":"string"},"status":{"type":"string"},"timezone":{"type":"null"},"title":{"type":"string"},"updatedAt":{"format":"date-time","type":"string"},"updatedBy":{"format":"uuid","type":"string"}},"required":["id","hostId","contactId","dealId","catalogRequestId","bookingPageId","title","description","startsAt","endsAt","timezone","allDay","locationType","location","status","source","guestName","guestEmail","guestPhone","guestNotes","canceledAt","canceledBy","cancelReason","createdBy","updatedBy","createdAt","updatedAt","host","contact","deal","bookingPage","payment"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/appointments/{id}/decline":{"post":{"operationId":"POST /v1/appointments/{id}/decline","summary":"Declines a meeting requested through a booking page.","tags":["appointments"],"x-feature":"appointments","x-action":"update","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"reason":{"anyOf":[{"type":"string","maxLength":1000},{"type":"null"}]},"refund":{"default":false,"type":"boolean"}}}}}},"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"allDay":{"type":"boolean"},"bookingPage":{"properties":{"id":{"format":"uuid","type":"string"},"title":{"type":"string"}},"required":["id","title"],"type":"object"},"bookingPageId":{"format":"uuid","type":"string"},"cancelReason":{"type":"string"},"canceledAt":{"format":"date-time","type":"string"},"canceledBy":{"type":"string"},"catalogRequestId":{"type":"null"},"contact":{"properties":{"id":{"format":"uuid","type":"string"},"name":{"type":"string"}},"required":["id","name"],"type":"object"},"contactId":{"format":"uuid","type":"string"},"createdAt":{"format":"date-time","type":"string"},"createdBy":{"type":"null"},"deal":{"type":"null"},"dealId":{"type":"null"},"description":{"type":"null"},"endsAt":{"format":"date-time","type":"string"},"guestEmail":{"format":"email","type":"string"},"guestName":{"type":"string"},"guestNotes":{"type":"null"},"guestPhone":{"type":"null"},"host":{"properties":{"id":{"format":"uuid","type":"string"},"image":{"type":"null"},"name":{"type":"string"}},"required":["id","name","image"],"type":"object"},"hostId":{"format":"uuid","type":"string"},"id":{"format":"uuid","type":"string"},"location":{"type":"null"},"locationType":{"type":"null"},"payment":{"type":"null"},"source":{"type":"string"},"startsAt":{"format":"date-time","type":"string"},"status":{"type":"string"},"timezone":{"type":"null"},"title":{"type":"string"},"updatedAt":{"format":"date-time","type":"string"},"updatedBy":{"format":"uuid","type":"string"}},"required":["id","hostId","contactId","dealId","catalogRequestId","bookingPageId","title","description","startsAt","endsAt","timezone","allDay","locationType","location","status","source","guestName","guestEmail","guestPhone","guestNotes","canceledAt","canceledBy","cancelReason","createdBy","updatedBy","createdAt","updatedAt","host","contact","deal","bookingPage","payment"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/appointments/check":{"get":{"operationId":"GET /v1/appointments/check","summary":"Checks whether a time is free and inside the host’s working hours, before booking it.","tags":["appointments"],"x-feature":"appointments","x-action":"read","parameters":[{"name":"hostId","in":"query","required":false,"schema":{"type":"string","minLength":1}},{"name":"startsAt","in":"query","required":true,"schema":{"type":"string","format":"date-time"}},{"name":"endsAt","in":"query","required":true,"schema":{"type":"string","format":"date-time"}},{"name":"excludeId","in":"query","required":false,"schema":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"conflicts":{"items":{"properties":{"endsAt":{"format":"date-time","type":"string"},"id":{"format":"uuid","type":"string"},"startsAt":{"format":"date-time","type":"string"},"title":{"type":"string"}},"required":["id","title","startsAt","endsAt"],"type":"object"},"type":"array"},"googleBusy":{"type":"boolean"},"outsideAvailability":{"type":"boolean"}},"required":["conflicts","googleBusy","outsideAvailability"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/appointments/usage":{"get":{"operationId":"GET /v1/appointments/usage","summary":"This month’s meetings against the plan’s allowance.","tags":["appointments"],"x-feature":"appointments","x-action":"read","responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"limit":{"type":["integer","null"]},"resetsAt":{"format":"date-time","type":"string"},"used":{"type":"integer"}},"required":["used","limit","resetsAt"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/approvals":{"get":{"operationId":"GET /v1/approvals","summary":"Lists the documents sent for approval.","tags":["approvals"],"x-feature":"approvals","x-action":"read","parameters":[{"name":"page","in":"query","required":false,"schema":{"default":1,"type":"integer","minimum":1,"maximum":9007199254740991}},{"name":"pageSize","in":"query","required":false,"schema":{"default":25,"type":"integer","minimum":1,"maximum":100}},{"name":"q","in":"query","required":false,"schema":{"type":"string","minLength":1,"maxLength":200}},{"name":"archived","in":"query","required":false,"schema":{"type":"string"}},{"name":"status","in":"query","required":false,"schema":{"type":"string","enum":["draft","sent","approved","declined","canceled"]}},{"name":"contactId","in":"query","required":false,"schema":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"}},{"name":"companyId","in":"query","required":false,"schema":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"}},{"name":"ownerId","in":"query","required":false,"schema":{"type":"string","minLength":1}},{"name":"createdFrom","in":"query","required":false,"schema":{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"}},{"name":"createdBefore","in":"query","required":false,"schema":{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"}},{"name":"sort","in":"query","required":false,"schema":{"default":"createdAt","type":"string","enum":["createdAt","title"]}},{"name":"order","in":"query","required":false,"schema":{"default":"desc","type":"string","enum":["asc","desc"]}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"data":{"items":{"properties":{"approvers":{"properties":{"approved":{"type":"integer"},"total":{"type":"integer"}},"required":["total","approved"],"type":"object"},"canceledAt":{"type":"null"},"company":{"type":"null"},"companyId":{"type":"null"},"completedAt":{"format":"date-time","type":["null","string"]},"createdAt":{"format":"date-time","type":"string"},"createdBy":{"format":"uuid","type":"string"},"fileBytes":{"type":["integer","null"]},"fileHash":{"type":["null","string"]},"fileName":{"type":["null","string"]},"hasFile":{"type":"boolean"},"id":{"format":"uuid","type":"string"},"language":{"type":"null"},"message":{"type":["null","string"]},"organizationId":{"format":"uuid","type":"string"},"ownerId":{"format":"uuid","type":"string"},"sentAt":{"format":"date-time","type":["null","string"]},"status":{"type":"string"},"title":{"type":"string"},"updatedAt":{"format":"date-time","type":"string"},"updatedBy":{"format":"uuid","type":"string"},"verifySignerEmail":{"type":"boolean"}},"required":["id","organizationId","title","message","status","companyId","ownerId","language","verifySignerEmail","fileName","fileBytes","fileHash","sentAt","completedAt","canceledAt","createdBy","updatedBy","createdAt","updatedAt","hasFile","company","approvers"],"type":"object"},"type":"array"},"page":{"type":"integer"},"pageSize":{"type":"integer"},"total":{"type":"integer"}},"required":["data","page","pageSize","total"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"post":{"operationId":"POST /v1/approvals","summary":"Creates an approval draft with its approvers.","tags":["approvals"],"x-feature":"approvals","x-action":"create","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"title":{"type":"string","minLength":1,"maxLength":200},"message":{"anyOf":[{"type":"string","maxLength":5000},{"type":"null"}]},"companyId":{"anyOf":[{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},{"type":"null"}]},"language":{"anyOf":[{"type":"string","enum":["pt","es","en","fr"]},{"type":"null"}]},"verifySignerEmail":{"type":"boolean"},"approvers":{"maxItems":20,"type":"array","items":{"type":"object","properties":{"contactId":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},"email":{"type":"string","maxLength":320,"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,}$"},"name":{"type":"string","minLength":1,"maxLength":200}}}}},"required":["title"]}}}},"responses":{"201":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"approvers":{"items":{"properties":{"contactId":{"format":"uuid","type":["null","string"]},"decidedAt":{"type":"null"},"declineReason":{"type":"null"},"email":{"format":"email","type":"string"},"fileHash":{"type":"null"},"firstViewedAt":{"type":"null"},"id":{"format":"uuid","type":"string"},"ipAddress":{"type":"null"},"lastViewedAt":{"type":"null"},"name":{"type":["null","string"]},"sendCount":{"type":"integer"},"sentAt":{"type":"null"},"signerName":{"type":"null"},"signerTaxId":{"type":"null"},"status":{"type":"string"},"url":{"type":"null"},"userAgent":{"type":"null"},"verification":{"type":"null"},"viewCount":{"type":"integer"}},"required":["id","contactId","name","email","status","url","sentAt","sendCount","viewCount","firstViewedAt","lastViewedAt","decidedAt","signerName","signerTaxId","fileHash","ipAddress","userAgent","declineReason","verification"],"type":"object"},"type":"array"},"canceledAt":{"type":"null"},"company":{"type":"null"},"companyId":{"type":"null"},"completedAt":{"type":"null"},"createdAt":{"format":"date-time","type":"string"},"createdBy":{"format":"uuid","type":"string"},"fileBytes":{"type":"null"},"fileHash":{"type":"null"},"fileName":{"type":"null"},"hasFile":{"type":"boolean"},"id":{"format":"uuid","type":"string"},"language":{"type":"null"},"message":{"type":["null","string"]},"organizationId":{"format":"uuid","type":"string"},"ownerId":{"format":"uuid","type":"string"},"sentAt":{"type":"null"},"status":{"type":"string"},"title":{"type":"string"},"updatedAt":{"format":"date-time","type":"string"},"updatedBy":{"format":"uuid","type":"string"},"verifySignerEmail":{"type":"boolean"}},"required":["approvers","canceledAt","company","companyId","completedAt","createdAt","createdBy","fileBytes","fileHash","fileName","hasFile","id","language","message","organizationId","ownerId","sentAt","status","title","updatedAt","updatedBy","verifySignerEmail"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/approvals/{id}":{"delete":{"operationId":"DELETE /v1/approvals/{id}","summary":"Deletes an approval.","tags":["approvals"],"x-feature":"approvals","x-action":"delete","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"204":{"description":"Done, with no content."},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"get":{"operationId":"GET /v1/approvals/{id}","summary":"Returns an approval with each approver’s answer.","tags":["approvals"],"x-feature":"approvals","x-action":"read","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"approvers":{"items":{"properties":{"contactId":{"format":"uuid","type":["null","string"]},"decidedAt":{"format":"date-time","type":["null","string"]},"declineReason":{"type":["null","string"]},"email":{"format":"email","type":"string"},"fileHash":{"type":["null","string"]},"firstViewedAt":{"format":"date-time","type":["null","string"]},"id":{"format":"uuid","type":"string"},"ipAddress":{"type":["null","string"]},"lastViewedAt":{"format":"date-time","type":["null","string"]},"name":{"type":["null","string"]},"sendCount":{"type":"integer"},"sentAt":{"format":"date-time","type":"string"},"signerName":{"type":["null","string"]},"signerTaxId":{"type":["null","string"]},"status":{"type":"string"},"url":{"format":"uri","type":"string"},"userAgent":{"type":"null"},"verification":{"properties":{"sendCount":{"type":"integer"},"sentAt":{"format":"date-time","type":"string"},"verifiedAt":{"format":"date-time","type":["null","string"]}},"required":["sentAt","sendCount","verifiedAt"],"type":["null","object"]},"viewCount":{"type":"integer"}},"required":["id","contactId","name","email","status","url","sentAt","sendCount","viewCount","firstViewedAt","lastViewedAt","decidedAt","signerName","signerTaxId","fileHash","ipAddress","userAgent","declineReason","verification"],"type":"object"},"type":"array"},"canceledAt":{"type":"null"},"company":{"type":"null"},"companyId":{"type":"null"},"completedAt":{"format":"date-time","type":"string"},"createdAt":{"format":"date-time","type":"string"},"createdBy":{"format":"uuid","type":"string"},"fileBytes":{"type":"integer"},"fileHash":{"type":"string"},"fileName":{"type":"string"},"hasFile":{"type":"boolean"},"id":{"format":"uuid","type":"string"},"language":{"type":"null"},"message":{"type":["null","string"]},"organizationId":{"format":"uuid","type":"string"},"ownerId":{"format":"uuid","type":"string"},"sentAt":{"format":"date-time","type":"string"},"status":{"type":"string"},"title":{"type":"string"},"updatedAt":{"format":"date-time","type":"string"},"updatedBy":{"format":"uuid","type":"string"},"verifySignerEmail":{"type":"boolean"}},"required":["id","organizationId","title","message","status","companyId","ownerId","language","verifySignerEmail","fileName","fileBytes","fileHash","sentAt","completedAt","canceledAt","createdBy","updatedBy","createdAt","updatedAt","hasFile","company","approvers"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"patch":{"operationId":"PATCH /v1/approvals/{id}","summary":"Changes an approval draft: title, message, approvers and settings.","tags":["approvals"],"x-feature":"approvals","x-action":"update","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"title":{"type":"string","minLength":1,"maxLength":200},"message":{"anyOf":[{"type":"string","maxLength":5000},{"type":"null"}]},"companyId":{"anyOf":[{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},{"type":"null"}]},"language":{"anyOf":[{"type":"string","enum":["pt","es","en","fr"]},{"type":"null"}]},"verifySignerEmail":{"type":"boolean"},"approvers":{"maxItems":20,"type":"array","items":{"type":"object","properties":{"contactId":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},"email":{"type":"string","maxLength":320,"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,}$"},"name":{"type":"string","minLength":1,"maxLength":200}}}}}}}}},"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/approvals/{id}/approvers/{approverId}/resend":{"post":{"operationId":"POST /v1/approvals/{id}/approvers/{approverId}/resend","summary":"Emails an approver their link again.","tags":["approvals"],"x-feature":"approvals","x-action":"update","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}},{"name":"approverId","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/approvals/{id}/approvers/{approverId}/verification/resend":{"post":{"operationId":"POST /v1/approvals/{id}/approvers/{approverId}/verification/resend","summary":"Sends an approver a new link to confirm their email address.","tags":["approvals"],"x-feature":"approvals","x-action":"update","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}},{"name":"approverId","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/approvals/{id}/cancel":{"post":{"operationId":"POST /v1/approvals/{id}/cancel","summary":"Cancels a sent approval; its links stop working.","tags":["approvals"],"x-feature":"approvals","x-action":"update","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/approvals/{id}/file":{"get":{"operationId":"GET /v1/approvals/{id}/file","summary":"Downloads the approval’s PDF.","tags":["approvals"],"x-feature":"approvals","x-action":"read","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"put":{"operationId":"PUT /v1/approvals/{id}/file","summary":"Uploads the PDF to approve (drafts only), replacing the previous one.","tags":["approvals"],"x-feature":"approvals","x-action":"update","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"multipart/form-data":{"schema":{"type":"object","required":["file"],"properties":{"file":{"type":"string","format":"binary"}}}}}},"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"approvers":{"items":{"properties":{"contactId":{"format":"uuid","type":["null","string"]},"decidedAt":{"type":"null"},"declineReason":{"type":"null"},"email":{"format":"email","type":"string"},"fileHash":{"type":"null"},"firstViewedAt":{"type":"null"},"id":{"format":"uuid","type":"string"},"ipAddress":{"type":"null"},"lastViewedAt":{"type":"null"},"name":{"type":["null","string"]},"sendCount":{"type":"integer"},"sentAt":{"type":"null"},"signerName":{"type":"null"},"signerTaxId":{"type":"null"},"status":{"type":"string"},"url":{"type":"null"},"userAgent":{"type":"null"},"verification":{"type":"null"},"viewCount":{"type":"integer"}},"required":["id","contactId","name","email","status","url","sentAt","sendCount","viewCount","firstViewedAt","lastViewedAt","decidedAt","signerName","signerTaxId","fileHash","ipAddress","userAgent","declineReason","verification"],"type":"object"},"type":"array"},"canceledAt":{"type":"null"},"company":{"type":"null"},"companyId":{"type":"null"},"completedAt":{"type":"null"},"createdAt":{"format":"date-time","type":"string"},"createdBy":{"format":"uuid","type":"string"},"fileBytes":{"type":"integer"},"fileHash":{"type":"string"},"fileName":{"type":"string"},"hasFile":{"type":"boolean"},"id":{"format":"uuid","type":"string"},"language":{"type":"null"},"message":{"type":["null","string"]},"organizationId":{"format":"uuid","type":"string"},"ownerId":{"format":"uuid","type":"string"},"sentAt":{"type":"null"},"status":{"type":"string"},"title":{"type":"string"},"updatedAt":{"format":"date-time","type":"string"},"updatedBy":{"format":"uuid","type":"string"},"verifySignerEmail":{"type":"boolean"}},"required":["approvers","canceledAt","company","companyId","completedAt","createdAt","createdBy","fileBytes","fileHash","fileName","hasFile","id","language","message","organizationId","ownerId","sentAt","status","title","updatedAt","updatedBy","verifySignerEmail"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/approvals/{id}/send":{"post":{"operationId":"POST /v1/approvals/{id}/send","summary":"Sends the draft: every approver gets their link by email.","tags":["approvals"],"x-feature":"approvals","x-action":"update","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"approvers":{"items":{"properties":{"contactId":{"format":"uuid","type":["null","string"]},"decidedAt":{"type":"null"},"declineReason":{"type":"null"},"email":{"format":"email","type":"string"},"fileHash":{"type":"null"},"firstViewedAt":{"type":"null"},"id":{"format":"uuid","type":"string"},"ipAddress":{"type":"null"},"lastViewedAt":{"type":"null"},"name":{"type":["null","string"]},"sendCount":{"type":"integer"},"sentAt":{"format":"date-time","type":"string"},"signerName":{"type":"null"},"signerTaxId":{"type":"null"},"status":{"type":"string"},"url":{"format":"uri","type":"string"},"userAgent":{"type":"null"},"verification":{"type":"null"},"viewCount":{"type":"integer"}},"required":["id","contactId","name","email","status","url","sentAt","sendCount","viewCount","firstViewedAt","lastViewedAt","decidedAt","signerName","signerTaxId","fileHash","ipAddress","userAgent","declineReason","verification"],"type":"object"},"type":"array"},"canceledAt":{"type":"null"},"company":{"type":"null"},"companyId":{"type":"null"},"completedAt":{"type":"null"},"createdAt":{"format":"date-time","type":"string"},"createdBy":{"format":"uuid","type":"string"},"fileBytes":{"type":"integer"},"fileHash":{"type":"string"},"fileName":{"type":"string"},"hasFile":{"type":"boolean"},"id":{"format":"uuid","type":"string"},"language":{"type":"null"},"message":{"type":["null","string"]},"organizationId":{"format":"uuid","type":"string"},"ownerId":{"format":"uuid","type":"string"},"sentAt":{"format":"date-time","type":"string"},"status":{"type":"string"},"title":{"type":"string"},"updatedAt":{"format":"date-time","type":"string"},"updatedBy":{"format":"uuid","type":"string"},"verifySignerEmail":{"type":"boolean"}},"required":["id","organizationId","title","message","status","companyId","ownerId","language","verifySignerEmail","fileName","fileBytes","fileHash","sentAt","completedAt","canceledAt","createdBy","updatedBy","createdAt","updatedAt","hasFile","company","approvers"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/availability/{memberId}":{"get":{"operationId":"GET /v1/availability/{memberId}","summary":"A member’s working hours, time zone and days off.","tags":["availability"],"x-feature":"availability","x-action":"read","parameters":[{"name":"memberId","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"custom":{"type":"boolean"},"memberId":{"format":"uuid","type":"string"},"overrides":{"type":"array"},"overridesLimit":{"type":"integer"},"timezone":{"type":"string"},"weekly":{"additionalProperties":{"items":{"properties":{"end":{"type":"string"},"start":{"type":"string"}},"required":["end","start"],"type":"object"},"type":"array"},"type":"object"}},"required":["custom","memberId","overrides","overridesLimit","timezone","weekly"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"put":{"operationId":"PUT /v1/availability/{memberId}","summary":"Replaces a member’s working hours and days off.","tags":["availability"],"x-feature":"availability","x-action":"update","parameters":[{"name":"memberId","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"timezone":{"type":"string","maxLength":64},"weekly":{"type":"object","properties":{"0":{"maxItems":8,"type":"array","items":{"type":"object","properties":{"start":{"type":"string","pattern":"^([01]\\d|2[0-3]):[0-5]\\d$|^24:00$"},"end":{"type":"string","pattern":"^([01]\\d|2[0-3]):[0-5]\\d$|^24:00$"}},"required":["start","end"]}},"1":{"maxItems":8,"type":"array","items":{"type":"object","properties":{"start":{"type":"string","pattern":"^([01]\\d|2[0-3]):[0-5]\\d$|^24:00$"},"end":{"type":"string","pattern":"^([01]\\d|2[0-3]):[0-5]\\d$|^24:00$"}},"required":["start","end"]}},"2":{"maxItems":8,"type":"array","items":{"type":"object","properties":{"start":{"type":"string","pattern":"^([01]\\d|2[0-3]):[0-5]\\d$|^24:00$"},"end":{"type":"string","pattern":"^([01]\\d|2[0-3]):[0-5]\\d$|^24:00$"}},"required":["start","end"]}},"3":{"maxItems":8,"type":"array","items":{"type":"object","properties":{"start":{"type":"string","pattern":"^([01]\\d|2[0-3]):[0-5]\\d$|^24:00$"},"end":{"type":"string","pattern":"^([01]\\d|2[0-3]):[0-5]\\d$|^24:00$"}},"required":["start","end"]}},"4":{"maxItems":8,"type":"array","items":{"type":"object","properties":{"start":{"type":"string","pattern":"^([01]\\d|2[0-3]):[0-5]\\d$|^24:00$"},"end":{"type":"string","pattern":"^([01]\\d|2[0-3]):[0-5]\\d$|^24:00$"}},"required":["start","end"]}},"5":{"maxItems":8,"type":"array","items":{"type":"object","properties":{"start":{"type":"string","pattern":"^([01]\\d|2[0-3]):[0-5]\\d$|^24:00$"},"end":{"type":"string","pattern":"^([01]\\d|2[0-3]):[0-5]\\d$|^24:00$"}},"required":["start","end"]}},"6":{"maxItems":8,"type":"array","items":{"type":"object","properties":{"start":{"type":"string","pattern":"^([01]\\d|2[0-3]):[0-5]\\d$|^24:00$"},"end":{"type":"string","pattern":"^([01]\\d|2[0-3]):[0-5]\\d$|^24:00$"}},"required":["start","end"]}}},"required":["0","1","2","3","4","5","6"]},"overrides":{"maxItems":366,"type":"array","items":{"type":"object","properties":{"date":{"type":"string","format":"date","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))$"},"intervals":{"maxItems":8,"type":"array","items":{"type":"object","properties":{"start":{"type":"string","pattern":"^([01]\\d|2[0-3]):[0-5]\\d$|^24:00$"},"end":{"type":"string","pattern":"^([01]\\d|2[0-3]):[0-5]\\d$|^24:00$"}},"required":["start","end"]}}},"required":["date","intervals"]}}},"required":["timezone","weekly","overrides"]}}}},"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"custom":{"type":"boolean"},"memberId":{"format":"uuid","type":"string"},"overrides":{"items":{"properties":{"date":{"format":"date","type":"string"},"intervals":{"type":"array"}},"required":["date","intervals"],"type":"object"},"type":"array"},"overridesLimit":{"type":"integer"},"timezone":{"type":"string"},"weekly":{"additionalProperties":{"items":{"properties":{"end":{"type":"string"},"start":{"type":"string"}},"required":["end","start"],"type":"object"},"type":"array"},"type":"object"}},"required":["custom","memberId","overrides","overridesLimit","timezone","weekly"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/booking-pages":{"get":{"operationId":"GET /v1/booking-pages","summary":"Lists the booking pages.","tags":["bookingPages"],"x-feature":"bookingPages","x-action":"read","parameters":[{"name":"hostId","in":"query","required":false,"schema":{"type":"string","minLength":1}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"post":{"operationId":"POST /v1/booking-pages","summary":"Creates a booking page.","tags":["bookingPages"],"x-feature":"bookingPages","x-action":"create","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"title":{"type":"string","minLength":1,"maxLength":120},"description":{"anyOf":[{"type":"string","maxLength":2000},{"type":"null"}]},"durationMinutes":{"type":"integer","minimum":5,"maximum":480},"bufferBeforeMinutes":{"default":0,"type":"integer","minimum":0,"maximum":240},"bufferAfterMinutes":{"default":0,"type":"integer","minimum":0,"maximum":240},"minNoticeMinutes":{"default":240,"type":"integer","minimum":0,"maximum":43200},"maxDaysAhead":{"default":60,"type":"integer","minimum":1,"maximum":365},"slotIntervalMinutes":{"anyOf":[{"type":"integer","minimum":5,"maximum":480},{"type":"null"}]},"allDay":{"default":false,"type":"boolean"},"durationDays":{"default":1,"type":"integer","minimum":1,"maximum":30},"teamMode":{"anyOf":[{"type":"string","enum":["host_first","time_first"]},{"type":"null"}]},"teamHostIds":{"maxItems":500,"type":"array","items":{"type":"string","minLength":1}},"locations":{"maxItems":4,"type":"array","items":{"type":"object","properties":{"type":{"type":"string","enum":["video","phone","in_person","other"]},"value":{"anyOf":[{"type":"string","maxLength":500},{"type":"null"}]}},"required":["type"]}},"requirePhone":{"default":false,"type":"boolean"},"isPublic":{"default":false,"type":"boolean"},"requireCaptcha":{"default":false,"type":"boolean"},"priceAmount":{"anyOf":[{"type":"integer","minimum":1,"maximum":100000000},{"type":"null"}]},"priceCurrency":{"anyOf":[{"type":"string","pattern":"^[A-Z]{3}$"},{"type":"null"}]},"refundNoticeMinutes":{"anyOf":[{"type":"integer","minimum":0,"maximum":43200},{"type":"null"}]},"active":{"default":true,"type":"boolean"},"templateId":{"anyOf":[{"type":"string","enum":["classic","modern","minimal","bold"]},{"type":"null"}]},"theme":{"default":{},"type":"object","properties":{"primaryColor":{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"accentColor":{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"backgroundColor":{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"textColor":{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"headingFont":{"type":"string","pattern":"^[A-Za-z0-9 ]{1,60}$"},"bodyFont":{"type":"string","pattern":"^[A-Za-z0-9 ]{1,60}$"},"coverImageUrl":{"type":"string","maxLength":2000,"format":"uri"},"cornerRadius":{"type":"string","enum":["none","small","medium","large"]}},"additionalProperties":false},"hostId":{"type":"string","minLength":1}},"required":["title","durationMinutes"]}}}},"responses":{"201":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"active":{"type":"boolean"},"allDay":{"type":"boolean"},"bufferAfterMinutes":{"type":"integer"},"bufferBeforeMinutes":{"type":"integer"},"createdAt":{"format":"date-time","type":"string"},"createdBy":{"format":"uuid","type":"string"},"description":{"type":"null"},"durationDays":{"type":"integer"},"durationMinutes":{"type":"integer"},"hostId":{"format":"uuid","type":"string"},"hostName":{"type":"string"},"id":{"format":"uuid","type":"string"},"isPublic":{"type":"boolean"},"locations":{"items":{"properties":{"type":{"type":"string"},"value":{"format":"uri","type":"string"}},"required":["type","value"],"type":"object"},"type":"array"},"maxDaysAhead":{"type":"integer"},"minNoticeMinutes":{"type":"integer"},"priceAmount":{"type":["integer","null"]},"priceCurrency":{"type":["null","string"]},"publicId":{"type":"string"},"refundNoticeMinutes":{"type":["integer","null"]},"requireCaptcha":{"type":"boolean"},"requirePhone":{"type":"boolean"},"slotIntervalMinutes":{"type":"null"},"teamHostIds":{"type":"array"},"teamMode":{"type":["null","string"]},"templateId":{"type":["null","string"]},"theme":{"properties":{"primaryColor":{"type":"string"}},"required":[],"type":"object"},"title":{"type":"string"},"updatedAt":{"format":"date-time","type":"string"},"updatedBy":{"format":"uuid","type":"string"},"url":{"format":"uri","type":"string"}},"required":["active","allDay","bufferAfterMinutes","bufferBeforeMinutes","createdAt","createdBy","description","durationDays","durationMinutes","hostId","hostName","id","isPublic","locations","maxDaysAhead","minNoticeMinutes","priceAmount","priceCurrency","publicId","refundNoticeMinutes","requireCaptcha","requirePhone","slotIntervalMinutes","teamHostIds","teamMode","templateId","theme","title","updatedAt","updatedBy","url"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/booking-pages/{id}":{"delete":{"operationId":"DELETE /v1/booking-pages/{id}","summary":"Deletes a booking page; meetings already booked stay.","tags":["bookingPages"],"x-feature":"bookingPages","x-action":"delete","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"204":{"description":"Done, with no content."},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"get":{"operationId":"GET /v1/booking-pages/{id}","summary":"Returns a booking page with its settings.","tags":["bookingPages"],"x-feature":"bookingPages","x-action":"read","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"patch":{"operationId":"PATCH /v1/booking-pages/{id}","summary":"Changes a booking page: hosts, durations, questions, look and rules.","tags":["bookingPages"],"x-feature":"bookingPages","x-action":"update","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"title":{"type":"string","minLength":1,"maxLength":120},"description":{"anyOf":[{"type":"string","maxLength":2000},{"type":"null"}]},"durationMinutes":{"type":"integer","minimum":5,"maximum":480},"bufferBeforeMinutes":{"type":"integer","minimum":0,"maximum":240},"bufferAfterMinutes":{"type":"integer","minimum":0,"maximum":240},"minNoticeMinutes":{"type":"integer","minimum":0,"maximum":43200},"maxDaysAhead":{"type":"integer","minimum":1,"maximum":365},"slotIntervalMinutes":{"anyOf":[{"type":"integer","minimum":5,"maximum":480},{"type":"null"}]},"allDay":{"type":"boolean"},"durationDays":{"type":"integer","minimum":1,"maximum":30},"teamMode":{"anyOf":[{"type":"string","enum":["host_first","time_first"]},{"type":"null"}]},"teamHostIds":{"maxItems":500,"type":"array","items":{"type":"string","minLength":1}},"locations":{"maxItems":4,"type":"array","items":{"type":"object","properties":{"type":{"type":"string","enum":["video","phone","in_person","other"]},"value":{"anyOf":[{"type":"string","maxLength":500},{"type":"null"}]}},"required":["type"]}},"requirePhone":{"type":"boolean"},"isPublic":{"type":"boolean"},"requireCaptcha":{"type":"boolean"},"priceAmount":{"anyOf":[{"type":"integer","minimum":1,"maximum":100000000},{"type":"null"}]},"priceCurrency":{"anyOf":[{"type":"string","pattern":"^[A-Z]{3}$"},{"type":"null"}]},"refundNoticeMinutes":{"anyOf":[{"type":"integer","minimum":0,"maximum":43200},{"type":"null"}]},"active":{"type":"boolean"},"templateId":{"anyOf":[{"type":"string","enum":["classic","modern","minimal","bold"]},{"type":"null"}]},"theme":{"type":"object","properties":{"primaryColor":{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"accentColor":{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"backgroundColor":{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"textColor":{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"headingFont":{"type":"string","pattern":"^[A-Za-z0-9 ]{1,60}$"},"bodyFont":{"type":"string","pattern":"^[A-Za-z0-9 ]{1,60}$"},"coverImageUrl":{"type":"string","maxLength":2000,"format":"uri"},"cornerRadius":{"type":"string","enum":["none","small","medium","large"]}},"additionalProperties":false},"hostId":{"type":"string","minLength":1}}}}}},"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"active":{"type":"boolean"},"allDay":{"type":"boolean"},"bufferAfterMinutes":{"type":"integer"},"bufferBeforeMinutes":{"type":"integer"},"createdAt":{"format":"date-time","type":"string"},"createdBy":{"format":"uuid","type":"string"},"description":{"type":"null"},"durationDays":{"type":"integer"},"durationMinutes":{"type":"integer"},"hostId":{"format":"uuid","type":"string"},"hostName":{"type":"string"},"id":{"format":"uuid","type":"string"},"isPublic":{"type":"boolean"},"locations":{"items":{"properties":{"type":{"type":"string"},"value":{"type":["null","string"]}},"required":["type","value"],"type":"object"},"type":"array"},"maxDaysAhead":{"type":"integer"},"minNoticeMinutes":{"type":"integer"},"priceAmount":{"type":["integer","null"]},"priceCurrency":{"type":["null","string"]},"publicId":{"type":"string"},"refundNoticeMinutes":{"type":["integer","null"]},"requireCaptcha":{"type":"boolean"},"requirePhone":{"type":"boolean"},"slotIntervalMinutes":{"type":"null"},"teamHostIds":{"type":"array"},"teamMode":{"type":"null"},"templateId":{"type":"null"},"theme":{"properties":{},"required":[],"type":"object"},"title":{"type":"string"},"updatedAt":{"format":"date-time","type":"string"},"updatedBy":{"format":"uuid","type":"string"},"url":{"format":"uri","type":"string"}},"required":["active","allDay","bufferAfterMinutes","bufferBeforeMinutes","createdAt","createdBy","description","durationDays","durationMinutes","hostId","hostName","id","isPublic","locations","maxDaysAhead","minNoticeMinutes","priceAmount","priceCurrency","publicId","refundNoticeMinutes","requireCaptcha","requirePhone","slotIntervalMinutes","teamHostIds","teamMode","templateId","theme","title","updatedAt","updatedBy","url"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/booking-pages/preview":{"post":{"operationId":"POST /v1/booking-pages/preview","summary":"Shows a booking page as visitors would see it with unsaved settings; saves nothing.","tags":["bookingPages"],"x-feature":"bookingPages","x-action":"read","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"durationMinutes":{"type":"integer","minimum":5,"maximum":480},"bufferBeforeMinutes":{"type":"integer","minimum":0,"maximum":240},"bufferAfterMinutes":{"type":"integer","minimum":0,"maximum":240},"minNoticeMinutes":{"type":"integer","minimum":0,"maximum":43200},"maxDaysAhead":{"type":"integer","minimum":1,"maximum":365},"slotIntervalMinutes":{"anyOf":[{"type":"integer","minimum":5,"maximum":480},{"type":"null"}]},"allDay":{"default":false,"type":"boolean"},"durationDays":{"default":1,"type":"integer","minimum":1,"maximum":30},"teamMode":{"anyOf":[{"type":"string","enum":["host_first","time_first"]},{"type":"null"}]},"teamHostIds":{"maxItems":500,"type":"array","items":{"type":"string","minLength":1}},"hostId":{"type":"string","minLength":1},"pickedHostId":{"type":"string","minLength":1},"templateId":{"anyOf":[{"type":"string","enum":["classic","modern","minimal","bold"]},{"type":"null"}]},"from":{"type":"string","format":"date-time"},"to":{"type":"string","format":"date-time"}},"required":["durationMinutes","bufferBeforeMinutes","bufferAfterMinutes","minNoticeMinutes","maxDaysAhead","from","to"]}}}},"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"host":{"properties":{"image":{"type":"null"},"name":{"type":"string"}},"required":["name","image"],"type":"object"},"hostTimezone":{"type":"string"},"organization":{"properties":{"language":{"type":"string"},"name":{"type":"string"}},"required":["name","language"],"type":"object"},"slots":{"items":{"format":"date-time","type":"string"},"type":"array"},"team":{"type":"null"},"templateId":{"type":"string"},"theme":{"properties":{"accentColor":{"type":"string"},"backgroundColor":{"type":"string"},"bodyFont":{"type":"string"},"cornerRadius":{"type":"string"},"headingFont":{"type":"string"},"primaryColor":{"type":"string"},"textColor":{"type":"string"}},"required":["primaryColor","accentColor","backgroundColor","textColor","headingFont","bodyFont","cornerRadius"],"type":"object"}},"required":["organization","templateId","theme","host","team","hostTimezone","slots"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/calendar-events":{"get":{"operationId":"GET /v1/calendar-events","summary":"Lists the saved calendar events.","tags":["calendarEvents"],"x-feature":"calendarEvents","x-action":"read","responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"items":{"properties":{"active":{"type":"boolean"},"adds30":{"type":"integer"},"allDay":{"type":"boolean"},"createdAt":{"format":"date-time","type":"string"},"createdBy":{"format":"uuid","type":"string"},"description":{"type":"string"},"endDate":{"format":"date","type":"string"},"endTime":{"type":"string"},"icsUrl":{"format":"uri","type":"string"},"id":{"format":"uuid","type":"string"},"location":{"type":"string"},"pageUrl":{"format":"uri","type":"string"},"publicId":{"type":"string"},"reminderMinutes":{"type":"integer"},"repeat":{"type":"null"},"startDate":{"format":"date","type":"string"},"startTime":{"type":"string"},"templateId":{"type":["null","string"]},"theme":{"properties":{},"required":[],"type":"object"},"timezone":{"type":"string"},"title":{"type":"string"},"updatedAt":{"format":"date-time","type":"string"},"updatedBy":{"format":"uuid","type":"string"},"url":{"type":"null"},"views30":{"type":"integer"}},"required":["id","publicId","title","description","location","url","timezone","allDay","startDate","startTime","endDate","endTime","repeat","reminderMinutes","templateId","theme","active","createdBy","updatedBy","createdAt","updatedAt","pageUrl","icsUrl","views30","adds30"],"type":"object"},"type":"array"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"post":{"operationId":"POST /v1/calendar-events","summary":"Saves a calendar event, with its page and .ics file.","tags":["calendarEvents"],"x-feature":"calendarEvents","x-action":"create","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"title":{"type":"string","minLength":1,"maxLength":200},"description":{"anyOf":[{"type":"string","maxLength":5000},{"type":"null"}]},"location":{"anyOf":[{"type":"string","maxLength":500},{"type":"null"}]},"url":{"anyOf":[{"type":"string","maxLength":2000,"format":"uri"},{"type":"null"}]},"timezone":{"type":"string","maxLength":64},"allDay":{"default":false,"type":"boolean"},"startDate":{"type":"string","pattern":"^\\d{4}-\\d{2}-\\d{2}$"},"startTime":{"anyOf":[{"type":"string","pattern":"^([01]\\d|2[0-3]):[0-5]\\d$"},{"type":"null"}]},"endDate":{"type":"string","pattern":"^\\d{4}-\\d{2}-\\d{2}$"},"endTime":{"anyOf":[{"type":"string","pattern":"^([01]\\d|2[0-3]):[0-5]\\d$"},{"type":"null"}]},"repeat":{"anyOf":[{"type":"object","properties":{"freq":{"type":"string","enum":["daily","weekly","monthly","yearly"]},"interval":{"default":1,"type":"integer","minimum":1,"maximum":99},"count":{"default":null,"anyOf":[{"type":"integer","minimum":1,"maximum":500},{"type":"null"}]},"until":{"default":null,"anyOf":[{"type":"string","pattern":"^\\d{4}-\\d{2}-\\d{2}$"},{"type":"null"}]}},"required":["freq"]},{"type":"null"}]},"reminderMinutes":{"anyOf":[{"type":"integer","minimum":0,"maximum":40320},{"type":"null"}]},"templateId":{"anyOf":[{"type":"string","enum":["classic","modern","minimal","bold"]},{"type":"null"}]},"theme":{"default":{},"type":"object","properties":{"primaryColor":{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"accentColor":{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"backgroundColor":{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"textColor":{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"headingFont":{"type":"string","pattern":"^[A-Za-z0-9 ]{1,60}$"},"bodyFont":{"type":"string","pattern":"^[A-Za-z0-9 ]{1,60}$"},"coverImageUrl":{"type":"string","maxLength":2000,"format":"uri"},"cornerRadius":{"type":"string","enum":["none","small","medium","large"]}},"additionalProperties":false},"active":{"default":true,"type":"boolean"}},"required":["title","timezone","startDate","endDate"]}}}},"responses":{"201":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"active":{"type":"boolean"},"adds30":{"type":"integer"},"allDay":{"type":"boolean"},"createdAt":{"format":"date-time","type":"string"},"createdBy":{"format":"uuid","type":"string"},"description":{"type":"string"},"endDate":{"format":"date","type":"string"},"endTime":{"type":"string"},"icsUrl":{"format":"uri","type":"string"},"id":{"format":"uuid","type":"string"},"location":{"type":"string"},"pageUrl":{"format":"uri","type":"string"},"publicId":{"type":"string"},"reminderMinutes":{"type":"integer"},"repeat":{"type":"null"},"startDate":{"format":"date","type":"string"},"startTime":{"type":"string"},"templateId":{"type":"null"},"theme":{"properties":{},"required":[],"type":"object"},"timezone":{"type":"string"},"title":{"type":"string"},"updatedAt":{"format":"date-time","type":"string"},"updatedBy":{"format":"uuid","type":"string"},"url":{"type":"null"},"views30":{"type":"integer"}},"required":["id","publicId","title","description","location","url","timezone","allDay","startDate","startTime","endDate","endTime","repeat","reminderMinutes","templateId","theme","active","createdBy","updatedBy","createdAt","updatedAt","pageUrl","icsUrl","views30","adds30"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/calendar-events/{id}":{"delete":{"operationId":"DELETE /v1/calendar-events/{id}","summary":"Deletes a calendar event with its page and file.","tags":["calendarEvents"],"x-feature":"calendarEvents","x-action":"delete","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"204":{"description":"Done, with no content."},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"get":{"operationId":"GET /v1/calendar-events/{id}","summary":"Returns a saved calendar event.","tags":["calendarEvents"],"x-feature":"calendarEvents","x-action":"read","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"patch":{"operationId":"PATCH /v1/calendar-events/{id}","summary":"Changes a calendar event; its page and file keep their address.","tags":["calendarEvents"],"x-feature":"calendarEvents","x-action":"update","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"anyOf":[{"type":"object","properties":{"title":{"type":"string","minLength":1,"maxLength":200},"description":{"anyOf":[{"type":"string","maxLength":5000},{"type":"null"}]},"location":{"anyOf":[{"type":"string","maxLength":500},{"type":"null"}]},"url":{"anyOf":[{"type":"string","maxLength":2000,"format":"uri"},{"type":"null"}]},"timezone":{"type":"string","maxLength":64},"allDay":{"default":false,"type":"boolean"},"startDate":{"type":"string","pattern":"^\\d{4}-\\d{2}-\\d{2}$"},"startTime":{"anyOf":[{"type":"string","pattern":"^([01]\\d|2[0-3]):[0-5]\\d$"},{"type":"null"}]},"endDate":{"type":"string","pattern":"^\\d{4}-\\d{2}-\\d{2}$"},"endTime":{"anyOf":[{"type":"string","pattern":"^([01]\\d|2[0-3]):[0-5]\\d$"},{"type":"null"}]},"repeat":{"anyOf":[{"type":"object","properties":{"freq":{"type":"string","enum":["daily","weekly","monthly","yearly"]},"interval":{"default":1,"type":"integer","minimum":1,"maximum":99},"count":{"default":null,"anyOf":[{"type":"integer","minimum":1,"maximum":500},{"type":"null"}]},"until":{"default":null,"anyOf":[{"type":"string","pattern":"^\\d{4}-\\d{2}-\\d{2}$"},{"type":"null"}]}},"required":["freq"]},{"type":"null"}]},"reminderMinutes":{"anyOf":[{"type":"integer","minimum":0,"maximum":40320},{"type":"null"}]},"templateId":{"anyOf":[{"type":"string","enum":["classic","modern","minimal","bold"]},{"type":"null"}]},"theme":{"default":{},"type":"object","properties":{"primaryColor":{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"accentColor":{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"backgroundColor":{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"textColor":{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"headingFont":{"type":"string","pattern":"^[A-Za-z0-9 ]{1,60}$"},"bodyFont":{"type":"string","pattern":"^[A-Za-z0-9 ]{1,60}$"},"coverImageUrl":{"type":"string","maxLength":2000,"format":"uri"},"cornerRadius":{"type":"string","enum":["none","small","medium","large"]}},"additionalProperties":false},"active":{"default":true,"type":"boolean"}},"required":["title","timezone","startDate","endDate"]},{"type":"object","properties":{"templateId":{"anyOf":[{"type":"string","enum":["classic","modern","minimal","bold"]},{"type":"null"}]},"theme":{"type":"object","properties":{"primaryColor":{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"accentColor":{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"backgroundColor":{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"textColor":{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"headingFont":{"type":"string","pattern":"^[A-Za-z0-9 ]{1,60}$"},"bodyFont":{"type":"string","pattern":"^[A-Za-z0-9 ]{1,60}$"},"coverImageUrl":{"type":"string","maxLength":2000,"format":"uri"},"cornerRadius":{"type":"string","enum":["none","small","medium","large"]}},"additionalProperties":false},"active":{"type":"boolean"}},"additionalProperties":false}]}}}},"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"active":{"type":"boolean"},"adds30":{"type":"integer"},"allDay":{"type":"boolean"},"createdAt":{"format":"date-time","type":"string"},"createdBy":{"format":"uuid","type":"string"},"description":{"type":"string"},"endDate":{"format":"date","type":"string"},"endTime":{"type":"string"},"icsUrl":{"format":"uri","type":"string"},"id":{"format":"uuid","type":"string"},"location":{"type":"string"},"pageUrl":{"format":"uri","type":"string"},"publicId":{"type":"string"},"reminderMinutes":{"type":"integer"},"repeat":{"type":"null"},"startDate":{"format":"date","type":"string"},"startTime":{"type":"string"},"templateId":{"type":["null","string"]},"theme":{"properties":{},"required":[],"type":"object"},"timezone":{"type":"string"},"title":{"type":"string"},"updatedAt":{"format":"date-time","type":"string"},"updatedBy":{"format":"uuid","type":"string"},"url":{"type":"null"},"views30":{"type":"integer"}},"required":["id","publicId","title","description","location","url","timezone","allDay","startDate","startTime","endDate","endTime","repeat","reminderMinutes","templateId","theme","active","createdBy","updatedBy","createdAt","updatedAt","pageUrl","icsUrl","views30","adds30"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/calendar-events/{id}/stats":{"get":{"operationId":"GET /v1/calendar-events/{id}/stats","summary":"Views of an event’s page and adds per calendar, per day.","tags":["calendarEvents"],"x-feature":"calendarEvents","x-action":"read","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}},{"name":"days","in":"query","required":false,"schema":{"default":30,"type":"integer","minimum":7,"maximum":365}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"byCalendar":{"properties":{"google":{"type":"integer"},"ics":{"type":"integer"},"office365":{"type":"integer"},"outlook":{"type":"integer"},"yahoo":{"type":"integer"}},"required":["google","outlook","office365","yahoo","ics"],"type":"object"},"days":{"type":"integer"},"series":{"items":{"properties":{"adds":{"type":"integer"},"day":{"format":"date","type":"string"},"views":{"type":"integer"}},"required":["day","views","adds"],"type":"object"},"type":"array"},"totals":{"properties":{"addRate":{"type":"integer"},"adds":{"type":"integer"},"views":{"type":"integer"}},"required":["views","adds","addRate"],"type":"object"}},"required":["days","totals","series","byCalendar"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/calendar-events/look":{"get":{"operationId":"GET /v1/calendar-events/look","summary":"The organization’s name and theme, for previewing an event page.","tags":["calendarEvents"],"x-feature":"calendarEvents","x-action":"read","parameters":[{"name":"templateId","in":"query","required":false,"schema":{"type":"string","enum":["classic","modern","minimal","bold"]}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"organization":{"properties":{"language":{"type":"string"},"name":{"type":"string"}},"required":["name","language"],"type":"object"},"templateId":{"type":"string"},"theme":{"properties":{"accentColor":{"type":"string"},"backgroundColor":{"type":"string"},"bodyFont":{"type":"string"},"cornerRadius":{"type":"string"},"headingFont":{"type":"string"},"primaryColor":{"type":"string"},"textColor":{"type":"string"}},"required":["primaryColor","accentColor","backgroundColor","textColor","headingFont","bodyFont","cornerRadius"],"type":"object"}},"required":["organization","templateId","theme"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/catalog-pages":{"get":{"operationId":"GET /v1/catalog-pages","summary":"Lists the public catalog pages.","tags":["catalogPages"],"x-feature":"catalogPages","x-action":"read","responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"data":{"items":{"properties":{"allowNotes":{"type":"boolean"},"allowNotesOnly":{"type":"boolean"},"assigneeIds":{"type":"array"},"bookingPageId":{"type":"null"},"buttons":{"type":"array"},"createTask":{"type":"boolean"},"createdAt":{"format":"date-time","type":"string"},"currency":{"type":"string"},"description":{"type":"string"},"fields":{"items":{"type":"string"},"type":"array"},"id":{"format":"uuid","type":"string"},"items":{"items":{"properties":{"featured":{"type":"boolean"},"id":{"format":"uuid","type":"string"},"kind":{"type":"string"},"maxQuantity":{"type":"integer"},"showPrice":{"type":"boolean"}},"required":["id","kind","featured","showPrice","maxQuantity"],"type":"object"},"type":"array"},"language":{"type":"string"},"layout":{"type":"string"},"name":{"type":"string"},"notesLabel":{"type":"string"},"organizationId":{"format":"uuid","type":"string"},"overLimit":{"type":"boolean"},"privacyText":{"type":"string"},"publishedAt":{"format":"date-time","type":"string"},"requireCaptcha":{"type":"boolean"},"showBranding":{"type":"boolean"},"showTotal":{"type":"boolean"},"slug":{"type":"string"},"status":{"type":"string"},"submitLabel":{"type":"string"},"successMessage":{"type":"string"},"taskDueDays":{"type":"integer"},"templateId":{"type":"null"},"theme":{"properties":{},"required":[],"type":"object"},"title":{"type":"string"},"updatedAt":{"format":"date-time","type":"string"},"url":{"format":"uri","type":"string"},"version":{"type":"integer"}},"required":["id","organizationId","slug","name","title","description","status","language","currency","layout","templateId","theme","showBranding","fields","items","buttons","allowNotes","allowNotesOnly","showTotal","requireCaptcha","submitLabel","notesLabel","successMessage","privacyText","bookingPageId","assigneeIds","createTask","taskDueDays","version","createdAt","updatedAt","publishedAt","overLimit","url"],"type":"object"},"type":"array"}},"required":["data"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"post":{"operationId":"POST /v1/catalog-pages","summary":"Creates a catalog page.","tags":["catalogPages"],"x-feature":"catalogPages","x-action":"create","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"name":{"type":"string","minLength":1,"maxLength":120},"slug":{"type":"string","pattern":"^[a-z0-9][a-z0-9-]{1,38}[a-z0-9]$"},"title":{"type":"string","minLength":1,"maxLength":200},"description":{"default":"","type":"string","maxLength":3000},"language":{"default":"pt","type":"string","enum":["pt","en","es","fr"]},"currency":{"default":"BRL","type":"string","pattern":"^[A-Z]{3}$"},"layout":{"default":"grid","type":"string","enum":["grid","list","editorial"]},"templateId":{"default":null,"anyOf":[{"type":"string","enum":["classic","modern","minimal","bold"]},{"type":"null"}]},"theme":{"default":{},"type":"object","properties":{"primaryColor":{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"accentColor":{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"backgroundColor":{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"textColor":{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"headingFont":{"type":"string","pattern":"^[A-Za-z0-9 ]{1,60}$"},"bodyFont":{"type":"string","pattern":"^[A-Za-z0-9 ]{1,60}$"},"coverImageUrl":{"type":"string","maxLength":2000,"format":"uri"},"cornerRadius":{"type":"string","enum":["none","small","medium","large"]}},"additionalProperties":false},"showBranding":{"default":true,"type":"boolean"},"fields":{"default":[],"maxItems":5,"type":"array","items":{"type":"string","enum":["name","phone","whatsapp","instagram","facebook"]}},"items":{"default":[],"maxItems":400,"type":"array","items":{"type":"object","properties":{"id":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},"kind":{"type":"string","enum":["service","product","package"]},"title":{"type":"string","maxLength":200},"description":{"type":"string","maxLength":2000},"group":{"type":"string","maxLength":100},"featured":{"default":false,"type":"boolean"},"showPrice":{"default":true,"type":"boolean"},"maxQuantity":{"default":1,"type":"integer","minimum":1,"maximum":1000}},"required":["id","kind"]}},"buttons":{"maxItems":5,"type":"array","items":{"type":"object","properties":{"id":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},"title":{"type":"string","minLength":1,"maxLength":100},"url":{"type":"string","maxLength":2000},"icon":{"anyOf":[{"type":"string","enum":["link","globe","instagram","whatsapp","tiktok","youtube","linkedin","facebook","x","telegram","spotify","email","phone","calendar","form","file","shop","star","map","gift"]},{"type":"null"}]},"style":{"anyOf":[{"type":"object","properties":{"background":{"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"text":{"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"border":{"default":"none","type":"string","enum":["none","thin","thick"]},"borderColor":{"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"shadow":{"default":"none","type":"string","enum":["none","soft","hard"]},"shadowColor":{"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"radius":{"default":"theme","type":"string","enum":["theme","square","rounded","pill"]},"hover":{"default":"simple","type":"string","enum":["simple","lift","grow","outline","none"]}}},{"type":"null"}]},"featured":{"default":false,"type":"boolean"}},"required":["id","title","url"]}},"allowNotes":{"default":false,"type":"boolean"},"allowNotesOnly":{"default":false,"type":"boolean"},"showTotal":{"default":true,"type":"boolean"},"requireCaptcha":{"default":true,"type":"boolean"},"submitLabel":{"default":"","type":"string","maxLength":100},"notesLabel":{"default":"","type":"string","maxLength":200},"successMessage":{"default":"","type":"string","maxLength":2000},"privacyText":{"default":"","type":"string","maxLength":2000},"bookingPageId":{"default":null,"anyOf":[{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},{"type":"null"}]},"assigneeIds":{"default":[],"maxItems":15,"type":"array","items":{"type":"string","minLength":1}},"createTask":{"default":false,"type":"boolean"},"taskDueDays":{"default":1,"type":"integer","minimum":0,"maximum":365}},"required":["name","slug","title"]}}}},"responses":{"201":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"allowNotes":{"type":"boolean"},"allowNotesOnly":{"type":"boolean"},"assigneeIds":{"type":"array"},"bookingPageId":{"type":"null"},"buttons":{"type":"array"},"createTask":{"type":"boolean"},"createdAt":{"format":"date-time","type":"string"},"currency":{"type":"string"},"description":{"type":"string"},"fields":{"items":{"type":"string"},"type":"array"},"id":{"format":"uuid","type":"string"},"items":{"items":{"properties":{"featured":{"type":"boolean"},"id":{"format":"uuid","type":"string"},"kind":{"type":"string"},"maxQuantity":{"type":"integer"},"showPrice":{"type":"boolean"}},"required":["featured","id","kind","maxQuantity","showPrice"],"type":"object"},"type":"array"},"language":{"type":"string"},"layout":{"type":"string"},"name":{"type":"string"},"notesLabel":{"type":"string"},"organizationId":{"format":"uuid","type":"string"},"privacyText":{"type":"string"},"publishedAt":{"type":"null"},"requireCaptcha":{"type":"boolean"},"showBranding":{"type":"boolean"},"showTotal":{"type":"boolean"},"slug":{"type":"string"},"status":{"type":"string"},"submitLabel":{"type":"string"},"successMessage":{"type":"string"},"taskDueDays":{"type":"integer"},"templateId":{"type":"null"},"theme":{"properties":{},"required":[],"type":"object"},"title":{"type":"string"},"updatedAt":{"format":"date-time","type":"string"},"version":{"type":"integer"}},"required":["allowNotes","allowNotesOnly","assigneeIds","bookingPageId","buttons","createTask","createdAt","currency","description","fields","id","items","language","layout","name","notesLabel","organizationId","privacyText","publishedAt","requireCaptcha","showBranding","showTotal","slug","status","submitLabel","successMessage","taskDueDays","templateId","theme","title","updatedAt","version"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/catalog-pages/{id}":{"get":{"operationId":"GET /v1/catalog-pages/{id}","summary":"Returns a catalog page with its items and settings.","tags":["catalogPages"],"x-feature":"catalogPages","x-action":"read","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"allowNotes":{"type":"boolean"},"allowNotesOnly":{"type":"boolean"},"assigneeIds":{"type":"array"},"bookingPageId":{"type":"null"},"buttons":{"type":"array"},"createTask":{"type":"boolean"},"createdAt":{"format":"date-time","type":"string"},"currency":{"type":"string"},"description":{"type":"string"},"fields":{"type":"array"},"id":{"format":"uuid","type":"string"},"items":{"items":{"properties":{"featured":{"type":"boolean"},"id":{"format":"uuid","type":"string"},"kind":{"type":"string"},"maxQuantity":{"type":"integer"},"showPrice":{"type":"boolean"}},"required":["id","kind","featured","showPrice","maxQuantity"],"type":"object"},"type":"array"},"language":{"type":"string"},"layout":{"type":"string"},"name":{"type":"string"},"notesLabel":{"type":"string"},"organizationId":{"format":"uuid","type":"string"},"privacyText":{"type":"string"},"publishedAt":{"format":"date-time","type":"string"},"requireCaptcha":{"type":"boolean"},"showBranding":{"type":"boolean"},"showTotal":{"type":"boolean"},"slug":{"type":"string"},"status":{"type":"string"},"submitLabel":{"type":"string"},"successMessage":{"type":"string"},"taskDueDays":{"type":"integer"},"templateId":{"type":"null"},"theme":{"properties":{},"required":[],"type":"object"},"title":{"type":"string"},"updatedAt":{"format":"date-time","type":"string"},"version":{"type":"integer"}},"required":["id","organizationId","slug","name","title","description","status","language","currency","layout","templateId","theme","showBranding","fields","items","buttons","allowNotes","allowNotesOnly","showTotal","requireCaptcha","submitLabel","notesLabel","successMessage","privacyText","bookingPageId","assigneeIds","createTask","taskDueDays","version","createdAt","updatedAt","publishedAt"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"patch":{"operationId":"PATCH /v1/catalog-pages/{id}","summary":"Changes a catalog page: items, texts, look and how requests are handled.","tags":["catalogPages"],"x-feature":"catalogPages","x-action":"update","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"name":{"type":"string","minLength":1,"maxLength":120},"slug":{"type":"string","pattern":"^[a-z0-9][a-z0-9-]{1,38}[a-z0-9]$"},"title":{"type":"string","minLength":1,"maxLength":200},"description":{"default":"","type":"string","maxLength":3000},"language":{"default":"pt","type":"string","enum":["pt","en","es","fr"]},"currency":{"default":"BRL","type":"string","pattern":"^[A-Z]{3}$"},"layout":{"default":"grid","type":"string","enum":["grid","list","editorial"]},"templateId":{"default":null,"anyOf":[{"type":"string","enum":["classic","modern","minimal","bold"]},{"type":"null"}]},"theme":{"default":{},"type":"object","properties":{"primaryColor":{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"accentColor":{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"backgroundColor":{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"textColor":{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"headingFont":{"type":"string","pattern":"^[A-Za-z0-9 ]{1,60}$"},"bodyFont":{"type":"string","pattern":"^[A-Za-z0-9 ]{1,60}$"},"coverImageUrl":{"type":"string","maxLength":2000,"format":"uri"},"cornerRadius":{"type":"string","enum":["none","small","medium","large"]}},"additionalProperties":false},"showBranding":{"default":true,"type":"boolean"},"fields":{"default":[],"maxItems":5,"type":"array","items":{"type":"string","enum":["name","phone","whatsapp","instagram","facebook"]}},"items":{"default":[],"maxItems":400,"type":"array","items":{"type":"object","properties":{"id":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},"kind":{"type":"string","enum":["service","product","package"]},"title":{"type":"string","maxLength":200},"description":{"type":"string","maxLength":2000},"group":{"type":"string","maxLength":100},"featured":{"default":false,"type":"boolean"},"showPrice":{"default":true,"type":"boolean"},"maxQuantity":{"default":1,"type":"integer","minimum":1,"maximum":1000}},"required":["id","kind"]}},"buttons":{"maxItems":5,"type":"array","items":{"type":"object","properties":{"id":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},"title":{"type":"string","minLength":1,"maxLength":100},"url":{"type":"string","maxLength":2000},"icon":{"anyOf":[{"type":"string","enum":["link","globe","instagram","whatsapp","tiktok","youtube","linkedin","facebook","x","telegram","spotify","email","phone","calendar","form","file","shop","star","map","gift"]},{"type":"null"}]},"style":{"anyOf":[{"type":"object","properties":{"background":{"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"text":{"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"border":{"default":"none","type":"string","enum":["none","thin","thick"]},"borderColor":{"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"shadow":{"default":"none","type":"string","enum":["none","soft","hard"]},"shadowColor":{"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"radius":{"default":"theme","type":"string","enum":["theme","square","rounded","pill"]},"hover":{"default":"simple","type":"string","enum":["simple","lift","grow","outline","none"]}}},{"type":"null"}]},"featured":{"default":false,"type":"boolean"}},"required":["id","title","url"]}},"allowNotes":{"default":false,"type":"boolean"},"allowNotesOnly":{"default":false,"type":"boolean"},"showTotal":{"default":true,"type":"boolean"},"requireCaptcha":{"default":true,"type":"boolean"},"submitLabel":{"default":"","type":"string","maxLength":100},"notesLabel":{"default":"","type":"string","maxLength":200},"successMessage":{"default":"","type":"string","maxLength":2000},"privacyText":{"default":"","type":"string","maxLength":2000},"bookingPageId":{"default":null,"anyOf":[{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},{"type":"null"}]},"assigneeIds":{"default":[],"maxItems":15,"type":"array","items":{"type":"string","minLength":1}},"createTask":{"default":false,"type":"boolean"},"taskDueDays":{"default":1,"type":"integer","minimum":0,"maximum":365}},"required":["name","slug","title"]}}}},"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"allowNotes":{"type":"boolean"},"allowNotesOnly":{"type":"boolean"},"assigneeIds":{"type":"array"},"bookingPageId":{"type":"null"},"buttons":{"type":"array"},"createTask":{"type":"boolean"},"createdAt":{"format":"date-time","type":"string"},"currency":{"type":"string"},"description":{"type":"string"},"fields":{"items":{"type":"string"},"type":"array"},"id":{"format":"uuid","type":"string"},"items":{"items":{"properties":{"featured":{"type":"boolean"},"id":{"format":"uuid","type":"string"},"kind":{"type":"string"},"maxQuantity":{"type":"integer"},"showPrice":{"type":"boolean"}},"required":["featured","id","kind","maxQuantity","showPrice"],"type":"object"},"type":"array"},"language":{"type":"string"},"layout":{"type":"string"},"name":{"type":"string"},"notesLabel":{"type":"string"},"organizationId":{"format":"uuid","type":"string"},"privacyText":{"type":"string"},"publishedAt":{"format":"date-time","type":"string"},"requireCaptcha":{"type":"boolean"},"showBranding":{"type":"boolean"},"showTotal":{"type":"boolean"},"slug":{"type":"string"},"status":{"type":"string"},"submitLabel":{"type":"string"},"successMessage":{"type":"string"},"taskDueDays":{"type":"integer"},"templateId":{"type":["null","string"]},"theme":{"properties":{"primaryColor":{"type":"string"}},"required":[],"type":"object"},"title":{"type":"string"},"updatedAt":{"format":"date-time","type":"string"},"version":{"type":"integer"}},"required":["allowNotes","allowNotesOnly","assigneeIds","bookingPageId","buttons","createTask","createdAt","currency","description","fields","id","items","language","layout","name","notesLabel","organizationId","privacyText","publishedAt","requireCaptcha","showBranding","showTotal","slug","status","submitLabel","successMessage","taskDueDays","templateId","theme","title","updatedAt","version"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/catalog-pages/{id}/preview":{"get":{"operationId":"GET /v1/catalog-pages/{id}/preview","summary":"Shows a catalog page as visitors would see it with unsaved settings; saves nothing.","tags":["catalogPages"],"x-feature":"catalogPages","x-action":"read","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/catalog-pages/{id}/stats":{"get":{"operationId":"GET /v1/catalog-pages/{id}/stats","summary":"Views and quote requests of a catalog page, per day.","tags":["catalogPages"],"x-feature":"catalogPages","x-action":"read","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}},{"name":"days","in":"query","required":false,"schema":{"default":30,"type":"number"}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/catalog-pages/{id}/status":{"post":{"operationId":"POST /v1/catalog-pages/{id}/status","summary":"Publishes, pauses or archives a catalog page (administrators, not API keys).","tags":["catalogPages"],"x-feature":"catalogPages","x-action":"create","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"status":{"type":"string","enum":["draft","published","paused","archived"]}},"required":["status"]}}}},"responses":{"201":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"allowNotes":{"type":"boolean"},"allowNotesOnly":{"type":"boolean"},"assigneeIds":{"type":"array"},"bookingPageId":{"type":"null"},"buttons":{"type":"array"},"createTask":{"type":"boolean"},"createdAt":{"format":"date-time","type":"string"},"currency":{"type":"string"},"description":{"type":"string"},"fields":{"items":{"type":"string"},"type":"array"},"id":{"format":"uuid","type":"string"},"items":{"items":{"properties":{"featured":{"type":"boolean"},"id":{"format":"uuid","type":"string"},"kind":{"type":"string"},"maxQuantity":{"type":"integer"},"showPrice":{"type":"boolean"}},"required":["featured","id","kind","maxQuantity","showPrice"],"type":"object"},"type":"array"},"language":{"type":"string"},"layout":{"type":"string"},"name":{"type":"string"},"notesLabel":{"type":"string"},"organizationId":{"format":"uuid","type":"string"},"privacyText":{"type":"string"},"publishedAt":{"format":"date-time","type":"string"},"requireCaptcha":{"type":"boolean"},"showBranding":{"type":"boolean"},"showTotal":{"type":"boolean"},"slug":{"type":"string"},"status":{"type":"string"},"submitLabel":{"type":"string"},"successMessage":{"type":"string"},"taskDueDays":{"type":"integer"},"templateId":{"type":"null"},"theme":{"properties":{},"required":[],"type":"object"},"title":{"type":"string"},"updatedAt":{"format":"date-time","type":"string"},"version":{"type":"integer"}},"required":["allowNotes","allowNotesOnly","assigneeIds","bookingPageId","buttons","createTask","createdAt","currency","description","fields","id","items","language","layout","name","notesLabel","organizationId","privacyText","publishedAt","requireCaptcha","showBranding","showTotal","slug","status","submitLabel","successMessage","taskDueDays","templateId","theme","title","updatedAt","version"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/catalog-pages/preview":{"post":{"operationId":"POST /v1/catalog-pages/preview","summary":"Shows a new catalog page as visitors would see it; saves nothing.","tags":["catalogPages"],"x-feature":"catalogPages","x-action":"read","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"name":{"type":"string","minLength":1,"maxLength":120},"slug":{"anyOf":[{"type":"string","pattern":"^[a-z0-9][a-z0-9-]{1,38}[a-z0-9]$"},{"type":"string","const":""}]},"title":{"type":"string","minLength":1,"maxLength":200},"description":{"default":"","type":"string","maxLength":3000},"language":{"default":"pt","type":"string","enum":["pt","en","es","fr"]},"currency":{"default":"BRL","type":"string","pattern":"^[A-Z]{3}$"},"layout":{"default":"grid","type":"string","enum":["grid","list","editorial"]},"templateId":{"default":null,"anyOf":[{"type":"string","enum":["classic","modern","minimal","bold"]},{"type":"null"}]},"theme":{"default":{},"type":"object","properties":{"primaryColor":{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"accentColor":{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"backgroundColor":{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"textColor":{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"headingFont":{"type":"string","pattern":"^[A-Za-z0-9 ]{1,60}$"},"bodyFont":{"type":"string","pattern":"^[A-Za-z0-9 ]{1,60}$"},"coverImageUrl":{"type":"string","maxLength":2000,"format":"uri"},"cornerRadius":{"type":"string","enum":["none","small","medium","large"]}},"additionalProperties":false},"showBranding":{"default":true,"type":"boolean"},"fields":{"default":[],"maxItems":5,"type":"array","items":{"type":"string","enum":["name","phone","whatsapp","instagram","facebook"]}},"items":{"default":[],"maxItems":400,"type":"array","items":{"type":"object","properties":{"id":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},"kind":{"type":"string","enum":["service","product","package"]},"title":{"type":"string","maxLength":200},"description":{"type":"string","maxLength":2000},"group":{"type":"string","maxLength":100},"featured":{"default":false,"type":"boolean"},"showPrice":{"default":true,"type":"boolean"},"maxQuantity":{"default":1,"type":"integer","minimum":1,"maximum":1000}},"required":["id","kind"]}},"buttons":{"maxItems":5,"type":"array","items":{"type":"object","properties":{"id":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},"title":{"type":"string","minLength":1,"maxLength":100},"url":{"type":"string","maxLength":2000},"icon":{"anyOf":[{"type":"string","enum":["link","globe","instagram","whatsapp","tiktok","youtube","linkedin","facebook","x","telegram","spotify","email","phone","calendar","form","file","shop","star","map","gift"]},{"type":"null"}]},"style":{"anyOf":[{"type":"object","properties":{"background":{"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"text":{"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"border":{"default":"none","type":"string","enum":["none","thin","thick"]},"borderColor":{"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"shadow":{"default":"none","type":"string","enum":["none","soft","hard"]},"shadowColor":{"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"radius":{"default":"theme","type":"string","enum":["theme","square","rounded","pill"]},"hover":{"default":"simple","type":"string","enum":["simple","lift","grow","outline","none"]}}},{"type":"null"}]},"featured":{"default":false,"type":"boolean"}},"required":["id","title","url"]}},"allowNotes":{"default":false,"type":"boolean"},"allowNotesOnly":{"default":false,"type":"boolean"},"showTotal":{"default":true,"type":"boolean"},"requireCaptcha":{"default":true,"type":"boolean"},"submitLabel":{"default":"","type":"string","maxLength":100},"notesLabel":{"default":"","type":"string","maxLength":200},"successMessage":{"default":"","type":"string","maxLength":2000},"privacyText":{"default":"","type":"string","maxLength":2000},"bookingPageId":{"default":null,"anyOf":[{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},{"type":"null"}]},"assigneeIds":{"default":[],"maxItems":15,"type":"array","items":{"type":"string","minLength":1}},"createTask":{"default":false,"type":"boolean"},"taskDueDays":{"default":1,"type":"integer","minimum":0,"maximum":365}},"required":["name","slug","title"]}}}},"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"allowNotes":{"type":"boolean"},"allowNotesOnly":{"type":"boolean"},"bookingUrl":{"type":"null"},"buttons":{"type":"array"},"captcha":{"type":"null"},"currency":{"type":"string"},"description":{"type":"string"},"fields":{"type":"array"},"items":{"items":{"properties":{"description":{"type":"string"},"featured":{"type":"boolean"},"id":{"format":"uuid","type":"string"},"images":{"type":"array"},"includedItemIds":{"type":"array"},"kind":{"type":"string"},"maxQuantity":{"type":"integer"},"name":{"type":"string"},"showPrice":{"type":"boolean"},"unitPrice":{"type":"integer"}},"required":["id","kind","featured","showPrice","maxQuantity","images","name","description","unitPrice","includedItemIds"],"type":"object"},"type":"array"},"language":{"type":"string"},"layout":{"type":"string"},"notesLabel":{"type":"string"},"organization":{"properties":{"logo":{"type":"null"},"name":{"type":"string"}},"required":["name","logo"],"type":"object"},"privacyText":{"type":"string"},"revision":{"type":"string"},"showBranding":{"type":"boolean"},"showTotal":{"type":"boolean"},"slug":{"type":"string"},"submitLabel":{"type":"string"},"successMessage":{"type":"string"},"templateId":{"type":"string"},"theme":{"properties":{"accentColor":{"type":"string"},"backgroundColor":{"type":"string"},"bodyFont":{"type":"string"},"cornerRadius":{"type":"string"},"headingFont":{"type":"string"},"primaryColor":{"type":"string"},"textColor":{"type":"string"}},"required":["primaryColor","accentColor","backgroundColor","textColor","headingFont","bodyFont","cornerRadius"],"type":"object"},"title":{"type":"string"}},"required":["organization","slug","title","description","language","currency","layout","templateId","theme","showBranding","fields","buttons","allowNotes","allowNotesOnly","showTotal","submitLabel","notesLabel","successMessage","privacyText","bookingUrl","revision","items","captcha"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/catalog-requests":{"get":{"operationId":"GET /v1/catalog-requests","summary":"Lists the quote requests sent from catalog pages.","tags":["catalogRequests"],"x-feature":"catalogRequests","x-action":"read","parameters":[{"name":"pageId","in":"query","required":false,"schema":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"}},{"name":"companyId","in":"query","required":false,"schema":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"}},{"name":"contactId","in":"query","required":false,"schema":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"data":{"items":{"properties":{"attempts":{"type":"integer"},"availableAt":{"format":"date-time","type":"string"},"contactId":{"format":"uuid","type":"string"},"createdAt":{"format":"date-time","type":"string"},"currency":{"type":"string"},"dealId":{"type":"null"},"details":{"properties":{"name":{"type":"string"}},"required":["name"],"type":"object"},"email":{"format":"email","type":"string"},"id":{"format":"uuid","type":"string"},"idempotencyKey":{"format":"uuid","type":"string"},"items":{"items":{"properties":{"description":{"type":"string"},"id":{"format":"uuid","type":"string"},"kind":{"type":"string"},"name":{"type":"string"},"quantity":{"type":"integer"},"showPrice":{"type":"boolean"},"unitPrice":{"type":"integer"}},"required":["id","kind","name","quantity","showPrice","unitPrice","description"],"type":"object"},"type":"array"},"notes":{"type":"string"},"notifiedAt":{"format":"date-time","type":"string"},"organizationId":{"format":"uuid","type":"string"},"pageId":{"format":"uuid","type":"string"},"pageTitle":{"type":"string"},"pageVersion":{"type":"integer"},"processing":{"type":"string"},"state":{"type":"string"},"total":{"type":"integer"},"tracking":{"properties":{},"required":[],"type":"object"}},"required":["id","organizationId","pageId","idempotencyKey","state","email","details","notes","pageTitle","pageVersion","currency","items","total","tracking","contactId","dealId","notifiedAt","processing","attempts","availableAt","createdAt"],"type":"object"},"type":"array"}},"required":["data"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/catalog-requests/{id}":{"patch":{"operationId":"PATCH /v1/catalog-requests/{id}","summary":"Changes a quote request’s status or owner.","tags":["catalogRequests"],"x-feature":"catalogRequests","x-action":"update","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"state":{"type":"string","enum":["new","reviewing","closed","spam"]},"contactId":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"}}}}}},"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/catalog-requests/{id}/proposal":{"post":{"operationId":"POST /v1/catalog-requests/{id}/proposal","summary":"Turns a quote request into a proposal draft with the items asked for.","tags":["catalogRequests"],"x-feature":"catalogRequests","x-action":"create","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"201":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"id":{"format":"uuid","type":"string"}},"required":["id"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/companies":{"get":{"operationId":"GET /v1/companies","summary":"Lists and searches companies, with filters and sorting.","tags":["companies"],"x-feature":"companies","x-action":"read","parameters":[{"name":"page","in":"query","required":false,"schema":{"default":1,"type":"integer","minimum":1,"maximum":9007199254740991}},{"name":"pageSize","in":"query","required":false,"schema":{"default":25,"type":"integer","minimum":1,"maximum":100}},{"name":"q","in":"query","required":false,"schema":{"type":"string","minLength":1,"maxLength":200}},{"name":"archived","in":"query","required":false,"schema":{"type":"string"}},{"name":"ownerId","in":"query","required":false,"schema":{"type":"string"}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"data":{"items":{"properties":{"address":{"type":"null"},"archived":{"type":"boolean"},"city":{"type":"null"},"country":{"type":"null"},"createdAt":{"format":"date-time","type":"string"},"createdBy":{"format":"uuid","type":"string"},"customProperties":{"additionalProperties":{},"type":"object"},"description":{"type":"null"},"id":{"format":"uuid","type":"string"},"industry":{"type":"null"},"name":{"type":"string"},"organizationId":{"format":"uuid","type":"string"},"ownerId":{"format":"uuid","type":"string"},"postalCode":{"type":"null"},"size":{"type":"null"},"socialProfiles":{"properties":{},"required":[],"type":"object"},"state":{"type":"null"},"updatedAt":{"format":"date-time","type":"string"},"updatedBy":{"format":"uuid","type":"string"},"website":{"type":"null"}},"required":["id","organizationId","name","website","industry","size","country","state","city","postalCode","address","description","ownerId","socialProfiles","customProperties","archived","createdBy","updatedBy","createdAt","updatedAt"],"type":"object"},"type":"array"},"page":{"type":"integer"},"pageSize":{"type":"integer"},"total":{"type":"integer"}},"required":["data","page","pageSize","total"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"post":{"operationId":"POST /v1/companies","summary":"Creates a company.","tags":["companies"],"x-feature":"companies","x-action":"create","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"name":{"type":"string","minLength":1,"maxLength":200},"website":{"anyOf":[{"type":"string","maxLength":2000,"format":"uri"},{"type":"null"}]},"industry":{"anyOf":[{"type":"string","maxLength":100},{"type":"null"}]},"size":{"anyOf":[{"type":"string","enum":["1","2-10","11-50","51-200","201-500","501-1000","1001+"]},{"type":"null"}]},"country":{"anyOf":[{"type":"string","maxLength":100},{"type":"null"}]},"state":{"anyOf":[{"type":"string","maxLength":100},{"type":"null"}]},"city":{"anyOf":[{"type":"string","maxLength":100},{"type":"null"}]},"postalCode":{"anyOf":[{"type":"string","maxLength":20},{"type":"null"}]},"address":{"anyOf":[{"type":"string","maxLength":300},{"type":"null"}]},"description":{"anyOf":[{"type":"string","maxLength":5000},{"type":"null"}]},"ownerId":{"anyOf":[{"type":"string","minLength":1},{"type":"null"}]},"socialProfiles":{"type":"object","propertyNames":{"type":"string","enum":["facebook","instagram","whatsapp","linkedin","tiktok","x","discord","telegram","youtube"]},"additionalProperties":{"anyOf":[{"type":"string","maxLength":300},{"type":"null"}]}},"customProperties":{"type":"object","propertyNames":{"type":"string"},"additionalProperties":{}},"archived":{"type":"boolean"}},"required":["name"]}}}},"responses":{"201":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"address":{"type":["null","string"]},"archived":{"type":"boolean"},"city":{"type":["null","string"]},"contacts":{"type":"array"},"country":{"type":["null","string"]},"createdAt":{"format":"date-time","type":"string"},"createdBy":{"format":"uuid","type":"string"},"customProperties":{"additionalProperties":{},"type":"object"},"description":{"type":"null"},"id":{"format":"uuid","type":"string"},"industry":{"type":"null"},"name":{"type":"string"},"organizationId":{"format":"uuid","type":"string"},"ownerId":{"format":"uuid","type":["null","string"]},"postalCode":{"type":["null","string"]},"size":{"type":["null","string"]},"socialProfiles":{"properties":{},"required":[],"type":"object"},"state":{"type":["null","string"]},"updatedAt":{"format":"date-time","type":"string"},"updatedBy":{"format":"uuid","type":"string"},"website":{"format":"uri","type":["null","string"]}},"required":["address","archived","city","contacts","country","createdAt","createdBy","customProperties","description","id","industry","name","organizationId","ownerId","postalCode","size","socialProfiles","state","updatedAt","updatedBy","website"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/companies/{id}":{"delete":{"operationId":"DELETE /v1/companies/{id}","summary":"Deletes a company; its contacts stay.","tags":["companies"],"x-feature":"companies","x-action":"delete","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"204":{"description":"Done, with no content."},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"get":{"operationId":"GET /v1/companies/{id}","summary":"Returns a company with its contacts and properties.","tags":["companies"],"x-feature":"companies","x-action":"read","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"address":{"type":"null"},"archived":{"type":"boolean"},"city":{"type":"null"},"contacts":{"items":{"properties":{"avatar":{"type":"null"},"contactId":{"format":"uuid","type":"string"},"firstName":{"type":"string"},"isPrimary":{"type":"boolean"},"jobTitle":{"type":["null","string"]},"lastName":{"type":["null","string"]}},"required":["avatar","contactId","firstName","isPrimary","jobTitle","lastName"],"type":"object"},"type":"array"},"country":{"type":"null"},"createdAt":{"format":"date-time","type":"string"},"createdBy":{"format":"uuid","type":"string"},"customProperties":{"additionalProperties":{},"type":"object"},"description":{"type":"null"},"id":{"format":"uuid","type":"string"},"industry":{"type":"null"},"name":{"type":"string"},"organizationId":{"format":"uuid","type":"string"},"ownerId":{"format":"uuid","type":"string"},"postalCode":{"type":"null"},"size":{"type":["null","string"]},"socialProfiles":{"properties":{},"required":[],"type":"object"},"state":{"type":"null"},"updatedAt":{"format":"date-time","type":"string"},"updatedBy":{"format":"uuid","type":"string"},"website":{"format":"uri","type":["null","string"]}},"required":["address","archived","city","contacts","country","createdAt","createdBy","customProperties","description","id","industry","name","organizationId","ownerId","postalCode","size","socialProfiles","state","updatedAt","updatedBy","website"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"patch":{"operationId":"PATCH /v1/companies/{id}","summary":"Changes a company’s fields and custom properties.","tags":["companies"],"x-feature":"companies","x-action":"update","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"name":{"type":"string","minLength":1,"maxLength":200},"website":{"anyOf":[{"type":"string","maxLength":2000,"format":"uri"},{"type":"null"}]},"industry":{"anyOf":[{"type":"string","maxLength":100},{"type":"null"}]},"size":{"anyOf":[{"type":"string","enum":["1","2-10","11-50","51-200","201-500","501-1000","1001+"]},{"type":"null"}]},"country":{"anyOf":[{"type":"string","maxLength":100},{"type":"null"}]},"state":{"anyOf":[{"type":"string","maxLength":100},{"type":"null"}]},"city":{"anyOf":[{"type":"string","maxLength":100},{"type":"null"}]},"postalCode":{"anyOf":[{"type":"string","maxLength":20},{"type":"null"}]},"address":{"anyOf":[{"type":"string","maxLength":300},{"type":"null"}]},"description":{"anyOf":[{"type":"string","maxLength":5000},{"type":"null"}]},"ownerId":{"anyOf":[{"type":"string","minLength":1},{"type":"null"}]},"socialProfiles":{"type":"object","propertyNames":{"type":"string","enum":["facebook","instagram","whatsapp","linkedin","tiktok","x","discord","telegram","youtube"]},"additionalProperties":{"anyOf":[{"type":"string","maxLength":300},{"type":"null"}]}},"customProperties":{"type":"object","propertyNames":{"type":"string"},"additionalProperties":{}},"archived":{"type":"boolean"}}}}}},"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"address":{"type":"null"},"archived":{"type":"boolean"},"city":{"type":"null"},"contacts":{"items":{"properties":{"avatar":{"type":"null"},"contactId":{"format":"uuid","type":"string"},"firstName":{"type":"string"},"isPrimary":{"type":"boolean"},"jobTitle":{"type":"string"},"lastName":{"type":"null"}},"required":["contactId","firstName","lastName","avatar","jobTitle","isPrimary"],"type":"object"},"type":"array"},"country":{"type":"null"},"createdAt":{"format":"date-time","type":"string"},"createdBy":{"format":"uuid","type":"string"},"customProperties":{"additionalProperties":{},"type":"object"},"description":{"type":"null"},"id":{"format":"uuid","type":"string"},"industry":{"type":"null"},"name":{"type":"string"},"organizationId":{"format":"uuid","type":"string"},"ownerId":{"format":"uuid","type":"string"},"postalCode":{"type":"null"},"size":{"type":"null"},"socialProfiles":{"properties":{},"required":[],"type":"object"},"state":{"type":"null"},"updatedAt":{"format":"date-time","type":"string"},"updatedBy":{"format":"uuid","type":"string"},"website":{"type":"null"}},"required":["id","organizationId","name","website","industry","size","country","state","city","postalCode","address","description","ownerId","socialProfiles","customProperties","archived","createdBy","updatedBy","createdAt","updatedAt","contacts"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/companies/{id}/activity":{"get":{"operationId":"GET /v1/companies/{id}/activity","summary":"A company’s timeline: proposals, invoices, meetings, forms, events and notes.","tags":["companies"],"x-feature":"companies","x-action":"read","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}},{"name":"limit","in":"query","required":false,"schema":{"default":200,"type":"integer","minimum":1,"maximum":1000}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"lastViewedAt":{"format":"date-time","type":["null","string"]},"timeline":{"items":{"properties":{"actorName":{"type":["null","string"]},"approval":{"properties":{"id":{"format":"uuid","type":"string"},"title":{"type":"string"}},"required":["id","title"],"type":"object"},"contact":{"properties":{"id":{"format":"uuid","type":"string"},"name":{"type":"string"}},"required":["id","name"],"type":["null","object"]},"contactEvent":{"properties":{"channel":{"type":"null"},"event":{"type":"string"},"id":{"format":"uuid","type":"string"},"occurredAt":{"format":"date-time","type":"string"},"properties":{"additionalProperties":{},"type":"object"},"reference":{"type":"null"}},"required":["id","event","properties","channel","reference","occurredAt"],"type":"object"},"createdAt":{"format":"date-time","type":"string"},"data":{"additionalProperties":{},"type":"object"},"deal":{"properties":{"id":{"format":"uuid","type":"string"},"title":{"type":"string"}},"required":["id","title"],"type":["null","object"]},"id":{"format":"uuid","type":"string"},"payment":{"properties":{"appointment":{"type":"null"},"invoice":{"properties":{"id":{"format":"uuid","type":"string"},"number":{"type":"string"}},"required":["id","number"],"type":["null","object"]},"recorded":{"type":["null","string"]},"source":{"type":"string"}},"required":["appointment","invoice","recorded","source"],"type":"object"},"type":{"type":"string"}},"required":["actorName","contact","createdAt","data","deal","id","type"],"type":"object"},"type":"array"},"viewCount":{"type":"integer"}},"required":["lastViewedAt","timeline","viewCount"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/companies/{id}/history":{"get":{"operationId":"GET /v1/companies/{id}/history","summary":"Every change to a company’s properties, with who made it.","tags":["companies"],"x-feature":"companies","x-action":"read","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}},{"name":"field","in":"query","required":true,"schema":{"type":"string","maxLength":120,"pattern":"^[A-Za-z]+(\\.[\\w-]+)?$"}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"entries":{"items":{"properties":{"changedAt":{"format":"date-time","type":"string"},"changedBy":{"properties":{"id":{"format":"uuid","type":"string"},"name":{"type":"string"}},"required":["id","name"],"type":"object"},"id":{"format":"uuid","type":"string"},"newLabel":{"type":"null"},"newValue":{"type":"string"},"oldLabel":{"type":"null"},"oldValue":{"type":["null","string"]}},"required":["id","oldValue","newValue","changedAt","oldLabel","newLabel","changedBy"],"type":"object"},"type":"array"},"field":{"type":"string"},"limit":{"type":"integer"},"total":{"type":"integer"}},"required":["field","limit","total","entries"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/companies/{id}/payments":{"get":{"operationId":"GET /v1/companies/{id}/payments","summary":"What a company paid: its invoices’ and proposals’ payments.","tags":["payments"],"x-feature":"payments","x-action":"read","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}},{"name":"page","in":"query","required":false,"schema":{"default":1,"type":"integer","minimum":1,"maximum":9007199254740991}},{"name":"pageSize","in":"query","required":false,"schema":{"default":10,"type":"integer","minimum":1,"maximum":50}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"data":{"items":{"properties":{"amount":{"type":"integer"},"appointment":{"type":"null"},"at":{"format":"date-time","type":"string"},"currency":{"type":"string"},"deal":{"properties":{"id":{"format":"uuid","type":"string"},"reference":{"type":"null"},"title":{"type":"string"}},"required":["id","reference","title"],"type":["null","object"]},"file":{"type":"null"},"id":{"format":"uuid","type":"string"},"invoice":{"properties":{"id":{"format":"uuid","type":"string"},"number":{"type":"string"}},"required":["id","number"],"type":["null","object"]},"kind":{"type":"string"},"method":{"type":["null","string"]},"payerEmail":{"format":"email","type":["null","string"]},"payerName":{"type":["null","string"]},"recorded":{"properties":{"channel":{"type":"null"},"company":{"properties":{"id":{"format":"uuid","type":"string"},"name":{"type":"string"}},"required":["id","name"],"type":"object"},"contact":{"properties":{"id":{"format":"uuid","type":"string"},"name":{"type":"string"}},"required":["id","name"],"type":["null","object"]},"description":{"type":["null","string"]},"items":{"items":{"properties":{"description":{"type":"null"},"discount":{"properties":{"type":{"type":"string"},"value":{"type":"integer"}},"required":["type","value"],"type":["null","object"]},"id":{"format":"uuid","type":"string"},"name":{"type":"string"},"quantity":{"type":"integer"},"serviceId":{"format":"uuid","type":["null","string"]},"unitPrice":{"type":"integer"}},"required":["id","name","discount","quantity","serviceId","unitPrice","description"],"type":"object"},"type":"array"},"recordedBy":{"type":"string"},"reference":{"type":"null"}},"required":["description","items","contact","company","recordedBy","channel","reference"],"type":["null","object"]},"source":{"type":"string"},"status":{"type":"string"}},"required":["amount","appointment","at","currency","deal","file","id","invoice","kind","method","payerEmail","payerName","recorded","source","status"],"type":"object"},"type":"array"},"page":{"type":"integer"},"pageSize":{"type":"integer"},"paidTotals":{"items":{"properties":{"amount":{"type":"integer"},"currency":{"type":"string"}},"required":["amount","currency"],"type":"object"},"type":"array"},"total":{"type":"integer"}},"required":["data","page","pageSize","paidTotals","total"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/contact-events":{"get":{"operationId":"GET /v1/contact-events","summary":"Lists contact events, by contact, name, channel or date.","tags":["contactEvents"],"x-feature":"contactEvents","x-action":"read","parameters":[{"name":"contactId","in":"query","required":false,"schema":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"}},{"name":"companyId","in":"query","required":false,"schema":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"}},{"name":"event","in":"query","required":false,"schema":{"type":"string"}},{"name":"from","in":"query","required":false,"schema":{"type":"string","format":"date-time"}},{"name":"to","in":"query","required":false,"schema":{"type":"string","format":"date-time"}},{"name":"page","in":"query","required":false,"schema":{"default":1,"type":"integer","minimum":1,"maximum":9007199254740991}},{"name":"pageSize","in":"query","required":false,"schema":{"default":25,"type":"integer","minimum":1,"maximum":100}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"data":{"items":{"properties":{"channel":{"type":["null","string"]},"contactId":{"format":"uuid","type":"string"},"contactName":{"type":"string"},"createdAt":{"format":"date-time","type":"string"},"createdBy":{"format":"uuid","type":"string"},"createdByName":{"type":"string"},"event":{"type":"string"},"id":{"format":"uuid","type":"string"},"occurredAt":{"format":"date-time","type":"string"},"organizationId":{"format":"uuid","type":"string"},"properties":{"additionalProperties":{},"type":"object"},"reference":{"type":["null","string"]}},"required":["id","organizationId","contactId","event","properties","channel","reference","occurredAt","createdBy","createdAt","contactName","createdByName"],"type":"object"},"type":"array"},"page":{"type":"integer"},"pageSize":{"type":"integer"},"total":{"type":"integer"}},"required":["data","page","pageSize","total"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"post":{"operationId":"POST /v1/contact-events","summary":"Records something a contact did; a repeated `reference` is kept once.","tags":["contactEvents"],"x-feature":"contactEvents","x-action":"create","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"contactId":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},"email":{"type":"string","maxLength":320,"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,}$"},"name":{"type":"string","minLength":1,"maxLength":200},"event":{"type":"string"},"properties":{"default":{},"type":"object","propertyNames":{"type":"string","pattern":"^[A-Za-z0-9_.-]{1,64}$"},"additionalProperties":{"anyOf":[{"type":"string","maxLength":500},{"type":"number"},{"type":"boolean"},{"type":"null"}]}},"occurredAt":{"type":"string","format":"date-time"},"channel":{"anyOf":[{"type":"string","maxLength":60},{"type":"null"}]},"reference":{"type":"string","minLength":1,"maxLength":120,"pattern":"^[\\w.:-]+$"}},"required":["event"]}}}},"responses":{"201":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"channel":{"type":["null","string"]},"contactId":{"format":"uuid","type":"string"},"createdAt":{"format":"date-time","type":"string"},"createdBy":{"format":"uuid","type":"string"},"event":{"type":"string"},"id":{"format":"uuid","type":"string"},"occurredAt":{"format":"date-time","type":"string"},"organizationId":{"format":"uuid","type":"string"},"properties":{"additionalProperties":{},"type":"object"},"reference":{"type":["null","string"]}},"required":["id","organizationId","contactId","event","properties","channel","reference","occurredAt","createdBy","createdAt"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/contact-events/{id}":{"delete":{"operationId":"DELETE /v1/contact-events/{id}","summary":"Deletes a contact event.","tags":["contactEvents"],"x-feature":"contactEvents","x-action":"delete","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"204":{"description":"Done, with no content."},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"get":{"operationId":"GET /v1/contact-events/{id}","summary":"Returns a contact event with its properties.","tags":["contactEvents"],"x-feature":"contactEvents","x-action":"read","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"channel":{"type":"null"},"contactId":{"format":"uuid","type":"string"},"createdAt":{"format":"date-time","type":"string"},"createdBy":{"format":"uuid","type":"string"},"event":{"type":"string"},"id":{"format":"uuid","type":"string"},"occurredAt":{"format":"date-time","type":"string"},"organizationId":{"format":"uuid","type":"string"},"properties":{"additionalProperties":{},"type":"object"},"reference":{"type":"null"}},"required":["id","organizationId","contactId","event","properties","channel","reference","occurredAt","createdBy","createdAt"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/contact-events/batch":{"post":{"operationId":"POST /v1/contact-events/batch","summary":"Records up to 100 contact events at once, saying which were kept.","tags":["contactEvents"],"x-feature":"contactEvents","x-action":"create","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"events":{"minItems":1,"maxItems":100,"type":"array","items":{"type":"object","properties":{"contactId":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},"email":{"type":"string","maxLength":320,"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,}$"},"name":{"type":"string","minLength":1,"maxLength":200},"event":{"type":"string"},"properties":{"default":{},"type":"object","propertyNames":{"type":"string","pattern":"^[A-Za-z0-9_.-]{1,64}$"},"additionalProperties":{"anyOf":[{"type":"string","maxLength":500},{"type":"number"},{"type":"boolean"},{"type":"null"}]}},"occurredAt":{"type":"string","format":"date-time"},"channel":{"anyOf":[{"type":"string","maxLength":60},{"type":"null"}]},"reference":{"type":"string","minLength":1,"maxLength":120,"pattern":"^[\\w.:-]+$"}},"required":["event"]}}},"required":["events"]}}}},"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"recorded":{"type":"integer"},"results":{"items":{"properties":{"error":{"properties":{"code":{"type":"string"},"message":{"type":"string"}},"required":["code","message"],"type":"object"},"id":{"format":"uuid","type":"string"},"index":{"type":"integer"}},"required":["index"],"type":"object"},"type":"array"}},"required":["recorded","results"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/contact-events/names":{"get":{"operationId":"GET /v1/contact-events/names","summary":"Every event name in use, with how many and the latest.","tags":["contactEvents"],"x-feature":"contactEvents","x-action":"read","responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"items":{"properties":{"event":{"type":"string"},"lastAt":{"format":"date-time","type":"string"},"total":{"type":"integer"}},"required":["event","total","lastAt"],"type":"object"},"type":"array"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/contact-events/types":{"get":{"operationId":"GET /v1/contact-events/types","summary":"The activity types: which events show on contacts’ and companies’ pages, and how.","tags":["contactEvents"],"x-feature":"contactEvents","x-action":"read","responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"type":"array"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"post":{"operationId":"POST /v1/contact-events/types","summary":"Creates an activity type for an event name.","tags":["contactEvents"],"x-feature":"contactEvents","x-action":"create","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"event":{"type":"string"},"label":{"type":"string","minLength":1,"maxLength":80},"color":{"type":"string","enum":["gray","blue","teal","green","amber","orange","red","pink","violet"]},"icon":{"type":"string","enum":["activity","star","heart","thumbs-up","trophy","gift","cart","card","user-plus","log-in","mail","phone","message","calendar","map-pin","eye","download","rocket","zap","alert"]},"summary":{"anyOf":[{"type":"string","maxLength":300},{"type":"null"}]},"showOnCompany":{"default":true,"type":"boolean"},"notify":{"default":false,"type":"boolean"},"active":{"default":true,"type":"boolean"}},"required":["event","label","color","icon"]}}}},"responses":{"201":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"active":{"type":"boolean"},"color":{"type":"string"},"createdAt":{"format":"date-time","type":"string"},"event":{"type":"string"},"icon":{"type":"string"},"id":{"format":"uuid","type":"string"},"label":{"type":"string"},"notify":{"type":"boolean"},"organizationId":{"format":"uuid","type":"string"},"showOnCompany":{"type":"boolean"},"summary":{"type":"string"},"updatedAt":{"format":"date-time","type":"string"}},"required":["id","organizationId","event","label","color","icon","summary","showOnCompany","notify","active","createdAt","updatedAt"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/contact-events/types/{id}":{"delete":{"operationId":"DELETE /v1/contact-events/types/{id}","summary":"Deletes an activity type; its events stay, without showing as activity.","tags":["contactEvents"],"x-feature":"contactEvents","x-action":"delete","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"204":{"description":"Done, with no content."},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"put":{"operationId":"PUT /v1/contact-events/types/{id}","summary":"Changes an activity type: label, color, icon and summary.","tags":["contactEvents"],"x-feature":"contactEvents","x-action":"update","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"event":{"type":"string"},"label":{"type":"string","minLength":1,"maxLength":80},"color":{"type":"string","enum":["gray","blue","teal","green","amber","orange","red","pink","violet"]},"icon":{"type":"string","enum":["activity","star","heart","thumbs-up","trophy","gift","cart","card","user-plus","log-in","mail","phone","message","calendar","map-pin","eye","download","rocket","zap","alert"]},"summary":{"anyOf":[{"type":"string","maxLength":300},{"type":"null"}]},"showOnCompany":{"default":true,"type":"boolean"},"notify":{"default":false,"type":"boolean"},"active":{"default":true,"type":"boolean"}},"required":["event","label","color","icon"]}}}},"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"active":{"type":"boolean"},"color":{"type":"string"},"createdAt":{"format":"date-time","type":"string"},"event":{"type":"string"},"icon":{"type":"string"},"id":{"format":"uuid","type":"string"},"label":{"type":"string"},"notify":{"type":"boolean"},"organizationId":{"format":"uuid","type":"string"},"showOnCompany":{"type":"boolean"},"summary":{"type":"string"},"updatedAt":{"format":"date-time","type":"string"}},"required":["id","organizationId","event","label","color","icon","summary","showOnCompany","notify","active","createdAt","updatedAt"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/contacts":{"get":{"operationId":"GET /v1/contacts","summary":"Lists and searches contacts, with filters, tags and sorting.","tags":["contacts"],"x-feature":"contacts","x-action":"read","parameters":[{"name":"page","in":"query","required":false,"schema":{"default":1,"type":"integer","minimum":1,"maximum":9007199254740991}},{"name":"pageSize","in":"query","required":false,"schema":{"default":25,"type":"integer","minimum":1,"maximum":100}},{"name":"q","in":"query","required":false,"schema":{"type":"string","minLength":1,"maxLength":200}},{"name":"archived","in":"query","required":false,"schema":{"type":"string"}},{"name":"sort","in":"query","required":false,"schema":{"default":"createdAt","type":"string","enum":["createdAt","updatedAt","name","lastActivityAt"]}},{"name":"order","in":"query","required":false,"schema":{"default":"desc","type":"string","enum":["asc","desc"]}},{"name":"ownerId","in":"query","required":false,"schema":{"type":"string"}},{"name":"companyId","in":"query","required":false,"schema":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"}},{"name":"tagId","in":"query","required":false,"schema":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"}},{"name":"leadStatus","in":"query","required":false,"schema":{"type":"string","enum":["new","open","in_progress","connected","qualified","unqualified"]}},{"name":"lifecycleStage","in":"query","required":false,"schema":{"type":"string","enum":["subscriber","lead","opportunity","customer","evangelist","other"]}},{"name":"marketingOptIn","in":"query","required":false,"schema":{"type":"string","enum":["true","false"]}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"data":{"items":{"properties":{"address":{"type":"null"},"archived":{"type":"boolean"},"avatar":{"type":"null"},"birthday":{"format":"date","type":["null","string"]},"city":{"type":"null"},"companies":{"items":{"properties":{"companyId":{"format":"uuid","type":"string"},"isPrimary":{"type":"boolean"},"jobTitle":{"type":["null","string"]},"name":{"type":"string"}},"required":["companyId","isPrimary","jobTitle","name"],"type":"object"},"type":"array"},"country":{"type":"null"},"createdAt":{"format":"date-time","type":"string"},"createdBy":{"format":"uuid","type":["null","string"]},"customProperties":{"additionalProperties":{},"type":"object"},"department":{"type":"null"},"emails":{"items":{"properties":{"email":{"format":"email","type":"string"},"id":{"format":"uuid","type":"string"},"isPrimary":{"type":"boolean"},"label":{"type":"null"}},"required":["email","id","isPrimary","label"],"type":"object"},"type":"array"},"firstName":{"type":"string"},"id":{"format":"uuid","type":"string"},"jobTitle":{"type":"null"},"lastActivityAt":{"format":"date-time","type":["null","string"]},"lastName":{"type":["null","string"]},"leadStatus":{"type":"null"},"lifecycleStage":{"type":["null","string"]},"locale":{"type":"null"},"marketingOptIn":{"type":"boolean"},"marketingOptInAt":{"format":"date-time","type":["null","string"]},"organizationId":{"format":"uuid","type":"string"},"ownerId":{"format":"uuid","type":["null","string"]},"phones":{"items":{"properties":{"id":{"format":"uuid","type":"string"},"isPrimary":{"type":"boolean"},"label":{"type":"null"},"phone":{"type":"string"}},"required":["id","isPrimary","label","phone"],"type":"object"},"type":"array"},"postalCode":{"type":"null"},"socialProfiles":{"properties":{"instagram":{"type":"string"}},"required":[],"type":"object"},"source":{"type":["null","string"]},"state":{"type":"null"},"tags":{"items":{"properties":{"color":{"type":"string"},"id":{"format":"uuid","type":"string"},"name":{"type":"string"}},"required":["color","id","name"],"type":"object"},"type":"array"},"timezone":{"type":"null"},"updatedAt":{"format":"date-time","type":"string"},"updatedBy":{"format":"uuid","type":["null","string"]}},"required":["address","archived","avatar","birthday","city","companies","country","createdAt","createdBy","customProperties","department","emails","firstName","id","jobTitle","lastActivityAt","lastName","leadStatus","lifecycleStage","locale","marketingOptIn","marketingOptInAt","organizationId","ownerId","phones","postalCode","socialProfiles","source","state","tags","timezone","updatedAt","updatedBy"],"type":"object"},"type":"array"},"page":{"type":"integer"},"pageSize":{"type":"integer"},"total":{"type":"integer"}},"required":["data","page","pageSize","total"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"post":{"operationId":"POST /v1/contacts","summary":"Creates a contact with their emails, phones and properties.","tags":["contacts"],"x-feature":"contacts","x-action":"create","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"firstName":{"type":"string","minLength":1,"maxLength":100},"lastName":{"anyOf":[{"type":"string","maxLength":100},{"type":"null"}]},"jobTitle":{"anyOf":[{"type":"string","maxLength":150},{"type":"null"}]},"department":{"anyOf":[{"type":"string","maxLength":150},{"type":"null"}]},"avatar":{"anyOf":[{"type":"string","maxLength":2000,"format":"uri"},{"type":"null"}]},"birthday":{"anyOf":[{"type":"string","format":"date","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))$"},{"type":"null"}]},"locale":{"anyOf":[{"type":"string","maxLength":20},{"type":"null"}]},"timezone":{"anyOf":[{"type":"string","maxLength":64},{"type":"null"}]},"country":{"anyOf":[{"type":"string","maxLength":100},{"type":"null"}]},"state":{"anyOf":[{"type":"string","maxLength":100},{"type":"null"}]},"city":{"anyOf":[{"type":"string","maxLength":100},{"type":"null"}]},"postalCode":{"anyOf":[{"type":"string","maxLength":20},{"type":"null"}]},"address":{"anyOf":[{"type":"string","maxLength":300},{"type":"null"}]},"source":{"anyOf":[{"type":"string","maxLength":100},{"type":"null"}]},"leadStatus":{"anyOf":[{"type":"string","enum":["new","open","in_progress","connected","qualified","unqualified"]},{"type":"null"}]},"lifecycleStage":{"anyOf":[{"type":"string","enum":["subscriber","lead","opportunity","customer","evangelist","other"]},{"type":"null"}]},"marketingOptIn":{"type":"boolean"},"ownerId":{"anyOf":[{"type":"string","minLength":1},{"type":"null"}]},"socialProfiles":{"type":"object","propertyNames":{"type":"string","enum":["facebook","instagram","whatsapp","linkedin","tiktok","x","discord","telegram","youtube"]},"additionalProperties":{"anyOf":[{"type":"string","maxLength":300},{"type":"null"}]}},"customProperties":{"type":"object","propertyNames":{"type":"string"},"additionalProperties":{}},"archived":{"type":"boolean"},"emails":{"maxItems":20,"type":"array","items":{"type":"object","properties":{"email":{"type":"string","maxLength":320,"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,}$"},"label":{"anyOf":[{"type":"string","maxLength":50},{"type":"null"}]},"isPrimary":{"type":"boolean"}},"required":["email"]}},"phones":{"maxItems":20,"type":"array","items":{"type":"object","properties":{"phone":{"type":"string","minLength":3,"maxLength":40},"label":{"anyOf":[{"type":"string","maxLength":50},{"type":"null"}]},"isPrimary":{"type":"boolean"}},"required":["phone"]}},"companies":{"maxItems":50,"type":"array","items":{"type":"object","properties":{"companyId":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},"jobTitle":{"anyOf":[{"type":"string","maxLength":150},{"type":"null"}]},"isPrimary":{"type":"boolean"}},"required":["companyId"]}},"tagIds":{"default":[],"maxItems":500,"type":"array","items":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"}}},"required":["firstName"]}}}},"responses":{"201":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"address":{"type":"null"},"archived":{"type":"boolean"},"avatar":{"format":"uri","type":["null","string"]},"birthday":{"format":"date","type":["null","string"]},"city":{"type":["null","string"]},"companies":{"items":{"properties":{"companyId":{"format":"uuid","type":"string"},"isPrimary":{"type":"boolean"},"jobTitle":{"type":["null","string"]},"name":{"type":"string"}},"required":["companyId","isPrimary","jobTitle","name"],"type":"object"},"type":"array"},"country":{"type":["null","string"]},"createdAt":{"format":"date-time","type":"string"},"createdBy":{"format":"uuid","type":["null","string"]},"customProperties":{"additionalProperties":{},"type":"object"},"department":{"type":"null"},"emails":{"items":{"properties":{"email":{"format":"email","type":"string"},"id":{"format":"uuid","type":"string"},"isPrimary":{"type":"boolean"},"label":{"type":["null","string"]}},"required":["email","id","isPrimary","label"],"type":"object"},"type":"array"},"firstName":{"type":"string"},"id":{"format":"uuid","type":"string"},"jobTitle":{"type":["null","string"]},"lastActivityAt":{"type":"null"},"lastName":{"type":["null","string"]},"leadStatus":{"type":"null"},"lifecycleStage":{"type":["null","string"]},"locale":{"type":"null"},"marketingOptIn":{"type":"boolean"},"marketingOptInAt":{"format":"date-time","type":["null","string"]},"organizationId":{"format":"uuid","type":"string"},"ownerId":{"format":"uuid","type":["null","string"]},"phones":{"items":{"properties":{"id":{"format":"uuid","type":"string"},"isPrimary":{"type":"boolean"},"label":{"type":"null"},"phone":{"type":"string"}},"required":["id","isPrimary","label","phone"],"type":"object"},"type":"array"},"postalCode":{"type":"null"},"socialProfiles":{"properties":{"instagram":{"type":"string"},"whatsapp":{"type":"string"}},"required":[],"type":"object"},"source":{"type":"null"},"state":{"type":"null"},"tags":{"items":{"properties":{"color":{"type":"string"},"id":{"format":"uuid","type":"string"},"name":{"type":"string"}},"required":["color","id","name"],"type":"object"},"type":"array"},"timezone":{"type":"null"},"updatedAt":{"format":"date-time","type":"string"},"updatedBy":{"format":"uuid","type":["null","string"]}},"required":["address","archived","avatar","birthday","city","companies","country","createdAt","createdBy","customProperties","department","emails","firstName","id","jobTitle","lastActivityAt","lastName","leadStatus","lifecycleStage","locale","marketingOptIn","marketingOptInAt","organizationId","ownerId","phones","postalCode","socialProfiles","source","state","tags","timezone","updatedAt","updatedBy"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/contacts/{id}":{"delete":{"operationId":"DELETE /v1/contacts/{id}","summary":"Deletes a contact.","tags":["contacts"],"x-feature":"contacts","x-action":"delete","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"204":{"description":"Done, with no content."},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"get":{"operationId":"GET /v1/contacts/{id}","summary":"Returns a contact with their emails, phones, companies, tags and properties.","tags":["contacts"],"x-feature":"contacts","x-action":"read","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"address":{"type":"null"},"archived":{"type":"boolean"},"avatar":{"format":"uri","type":["null","string"]},"birthday":{"type":"null"},"city":{"type":["null","string"]},"companies":{"items":{"properties":{"companyId":{"format":"uuid","type":"string"},"isPrimary":{"type":"boolean"},"jobTitle":{"type":"null"},"name":{"type":"string"}},"required":["companyId","name","jobTitle","isPrimary"],"type":"object"},"type":"array"},"country":{"type":"null"},"createdAt":{"format":"date-time","type":"string"},"createdBy":{"format":"uuid","type":["null","string"]},"customProperties":{"additionalProperties":{},"type":"object"},"department":{"type":"null"},"emails":{"items":{"properties":{"email":{"format":"email","type":"string"},"id":{"format":"uuid","type":"string"},"isPrimary":{"type":"boolean"},"label":{"type":"null"}},"required":["email","id","isPrimary","label"],"type":"object"},"type":"array"},"firstName":{"type":"string"},"id":{"format":"uuid","type":"string"},"jobTitle":{"type":["null","string"]},"lastActivityAt":{"type":"null"},"lastName":{"type":["null","string"]},"leadStatus":{"type":"null"},"lifecycleStage":{"type":["null","string"]},"locale":{"type":"null"},"marketingOptIn":{"type":"boolean"},"marketingOptInAt":{"format":"date-time","type":["null","string"]},"organizationId":{"format":"uuid","type":"string"},"ownerId":{"format":"uuid","type":["null","string"]},"phones":{"items":{"properties":{"id":{"format":"uuid","type":"string"},"isPrimary":{"type":"boolean"},"label":{"type":"null"},"phone":{"type":"string"}},"required":["id","isPrimary","label","phone"],"type":"object"},"type":"array"},"postalCode":{"type":"null"},"socialProfiles":{"properties":{"instagram":{"format":"uri","type":"string"}},"required":[],"type":"object"},"source":{"type":["null","string"]},"state":{"type":"null"},"tags":{"items":{"properties":{"color":{"type":"string"},"id":{"format":"uuid","type":"string"},"name":{"type":"string"}},"required":["color","id","name"],"type":"object"},"type":"array"},"timezone":{"type":"null"},"updatedAt":{"format":"date-time","type":"string"},"updatedBy":{"format":"uuid","type":["null","string"]}},"required":["address","archived","avatar","birthday","city","companies","country","createdAt","createdBy","customProperties","department","emails","firstName","id","jobTitle","lastActivityAt","lastName","leadStatus","lifecycleStage","locale","marketingOptIn","marketingOptInAt","organizationId","ownerId","phones","postalCode","socialProfiles","source","state","tags","timezone","updatedAt","updatedBy"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"patch":{"operationId":"PATCH /v1/contacts/{id}","summary":"Changes a contact’s fields, emails, phones and custom properties.","tags":["contacts"],"x-feature":"contacts","x-action":"update","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"firstName":{"type":"string","minLength":1,"maxLength":100},"lastName":{"anyOf":[{"type":"string","maxLength":100},{"type":"null"}]},"jobTitle":{"anyOf":[{"type":"string","maxLength":150},{"type":"null"}]},"department":{"anyOf":[{"type":"string","maxLength":150},{"type":"null"}]},"avatar":{"anyOf":[{"type":"string","maxLength":2000,"format":"uri"},{"type":"null"}]},"birthday":{"anyOf":[{"type":"string","format":"date","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))$"},{"type":"null"}]},"locale":{"anyOf":[{"type":"string","maxLength":20},{"type":"null"}]},"timezone":{"anyOf":[{"type":"string","maxLength":64},{"type":"null"}]},"country":{"anyOf":[{"type":"string","maxLength":100},{"type":"null"}]},"state":{"anyOf":[{"type":"string","maxLength":100},{"type":"null"}]},"city":{"anyOf":[{"type":"string","maxLength":100},{"type":"null"}]},"postalCode":{"anyOf":[{"type":"string","maxLength":20},{"type":"null"}]},"address":{"anyOf":[{"type":"string","maxLength":300},{"type":"null"}]},"source":{"anyOf":[{"type":"string","maxLength":100},{"type":"null"}]},"leadStatus":{"anyOf":[{"type":"string","enum":["new","open","in_progress","connected","qualified","unqualified"]},{"type":"null"}]},"lifecycleStage":{"anyOf":[{"type":"string","enum":["subscriber","lead","opportunity","customer","evangelist","other"]},{"type":"null"}]},"marketingOptIn":{"type":"boolean"},"ownerId":{"anyOf":[{"type":"string","minLength":1},{"type":"null"}]},"socialProfiles":{"type":"object","propertyNames":{"type":"string","enum":["facebook","instagram","whatsapp","linkedin","tiktok","x","discord","telegram","youtube"]},"additionalProperties":{"anyOf":[{"type":"string","maxLength":300},{"type":"null"}]}},"customProperties":{"type":"object","propertyNames":{"type":"string"},"additionalProperties":{}},"archived":{"type":"boolean"},"emails":{"maxItems":20,"type":"array","items":{"type":"object","properties":{"email":{"type":"string","maxLength":320,"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,}$"},"label":{"anyOf":[{"type":"string","maxLength":50},{"type":"null"}]},"isPrimary":{"type":"boolean"}},"required":["email"]}},"phones":{"maxItems":20,"type":"array","items":{"type":"object","properties":{"phone":{"type":"string","minLength":3,"maxLength":40},"label":{"anyOf":[{"type":"string","maxLength":50},{"type":"null"}]},"isPrimary":{"type":"boolean"}},"required":["phone"]}},"companies":{"maxItems":50,"type":"array","items":{"type":"object","properties":{"companyId":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},"jobTitle":{"anyOf":[{"type":"string","maxLength":150},{"type":"null"}]},"isPrimary":{"type":"boolean"}},"required":["companyId"]}},"tagIds":{"maxItems":500,"type":"array","items":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"}}}}}}},"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"address":{"type":"null"},"archived":{"type":"boolean"},"avatar":{"format":"uri","type":["null","string"]},"birthday":{"format":"date","type":["null","string"]},"city":{"type":["null","string"]},"companies":{"items":{"properties":{"companyId":{"format":"uuid","type":"string"},"isPrimary":{"type":"boolean"},"jobTitle":{"type":["null","string"]},"name":{"type":"string"}},"required":["companyId","isPrimary","jobTitle","name"],"type":"object"},"type":"array"},"country":{"type":["null","string"]},"createdAt":{"format":"date-time","type":"string"},"createdBy":{"format":"uuid","type":["null","string"]},"customProperties":{"additionalProperties":{},"type":"object"},"department":{"type":"null"},"emails":{"items":{"properties":{"email":{"format":"email","type":"string"},"id":{"format":"uuid","type":"string"},"isPrimary":{"type":"boolean"},"label":{"type":["null","string"]}},"required":["email","id","isPrimary","label"],"type":"object"},"type":"array"},"firstName":{"type":"string"},"id":{"format":"uuid","type":"string"},"jobTitle":{"type":["null","string"]},"lastActivityAt":{"format":"date-time","type":["null","string"]},"lastName":{"type":["null","string"]},"leadStatus":{"type":"null"},"lifecycleStage":{"type":["null","string"]},"locale":{"type":"null"},"marketingOptIn":{"type":"boolean"},"marketingOptInAt":{"format":"date-time","type":["null","string"]},"organizationId":{"format":"uuid","type":"string"},"ownerId":{"format":"uuid","type":["null","string"]},"phones":{"items":{"properties":{"id":{"format":"uuid","type":"string"},"isPrimary":{"type":"boolean"},"label":{"type":"null"},"phone":{"type":"string"}},"required":["id","isPrimary","label","phone"],"type":"object"},"type":"array"},"postalCode":{"type":"null"},"socialProfiles":{"properties":{"instagram":{"type":"string"}},"required":[],"type":"object"},"source":{"type":["null","string"]},"state":{"type":"null"},"tags":{"items":{"properties":{"color":{"type":"string"},"id":{"format":"uuid","type":"string"},"name":{"type":"string"}},"required":["id","name","color"],"type":"object"},"type":"array"},"timezone":{"type":"null"},"updatedAt":{"format":"date-time","type":"string"},"updatedBy":{"format":"uuid","type":"string"}},"required":["address","archived","avatar","birthday","city","companies","country","createdAt","createdBy","customProperties","department","emails","firstName","id","jobTitle","lastActivityAt","lastName","leadStatus","lifecycleStage","locale","marketingOptIn","marketingOptInAt","organizationId","ownerId","phones","postalCode","socialProfiles","source","state","tags","timezone","updatedAt","updatedBy"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/contacts/{id}/activity":{"get":{"operationId":"GET /v1/contacts/{id}/activity","summary":"A contact’s timeline: proposals, invoices, meetings, forms, emails, events and notes.","tags":["contacts"],"x-feature":"contacts","x-action":"read","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}},{"name":"limit","in":"query","required":false,"schema":{"default":200,"type":"integer","minimum":1,"maximum":1000}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"lastViewedAt":{"format":"date-time","type":["null","string"]},"timeline":{"items":{"properties":{"actorName":{"type":["null","string"]},"appointment":{"properties":{"id":{"format":"uuid","type":"string"},"startsAt":{"format":"date-time","type":"string"},"status":{"type":"string"},"title":{"type":"string"}},"required":["id","title","startsAt","status"],"type":"object"},"approval":{"properties":{"id":{"format":"uuid","type":"string"},"title":{"type":"string"}},"required":["id","title"],"type":"object"},"contactEvent":{"properties":{"channel":{"type":"null"},"event":{"type":"string"},"id":{"format":"uuid","type":"string"},"occurredAt":{"format":"date-time","type":"string"},"properties":{"additionalProperties":{},"type":"object"},"reference":{"type":"null"}},"required":["id","event","properties","channel","reference","occurredAt"],"type":"object"},"contract":{"properties":{"id":{"format":"uuid","type":"string"},"title":{"type":"string"}},"required":["id","title"],"type":"object"},"createdAt":{"format":"date-time","type":"string"},"data":{"additionalProperties":{},"type":"object"},"deal":{"properties":{"id":{"format":"uuid","type":"string"},"title":{"type":"string"}},"required":["id","title"],"type":["null","object"]},"form":{"properties":{"id":{"format":"uuid","type":"string"},"name":{"type":"string"},"submissionId":{"format":"uuid","type":"string"}},"required":["id","name","submissionId"],"type":"object"},"id":{"format":"uuid","type":"string"},"payment":{"properties":{"appointment":{"type":"null"},"invoice":{"properties":{"id":{"format":"uuid","type":"string"},"number":{"type":"string"}},"required":["id","number"],"type":["null","object"]},"recorded":{"type":["null","string"]},"source":{"type":"string"}},"required":["appointment","invoice","recorded","source"],"type":"object"},"type":{"type":"string"}},"required":["actorName","createdAt","data","deal","id","type"],"type":"object"},"type":"array"},"viewCount":{"type":"integer"}},"required":["lastViewedAt","timeline","viewCount"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/contacts/{id}/companies/{companyId}":{"delete":{"operationId":"DELETE /v1/contacts/{id}/companies/{companyId}","summary":"Unlinks a contact from a company.","tags":["contacts"],"x-feature":"contacts","x-action":"update","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}},{"name":"companyId","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"204":{"description":"Done, with no content."},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"put":{"operationId":"PUT /v1/contacts/{id}/companies/{companyId}","summary":"Links a contact to a company, with their role there.","tags":["contacts"],"x-feature":"contacts","x-action":"update","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}},{"name":"companyId","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"jobTitle":{"anyOf":[{"type":"string","maxLength":150},{"type":"null"}]},"isPrimary":{"type":"boolean"}}}}}},"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"address":{"type":"null"},"archived":{"type":"boolean"},"avatar":{"type":"null"},"birthday":{"format":"date","type":["null","string"]},"city":{"type":"null"},"companies":{"items":{"properties":{"companyId":{"format":"uuid","type":"string"},"isPrimary":{"type":"boolean"},"jobTitle":{"type":["null","string"]},"name":{"type":"string"}},"required":["companyId","isPrimary","jobTitle","name"],"type":"object"},"type":"array"},"country":{"type":"null"},"createdAt":{"format":"date-time","type":"string"},"createdBy":{"format":"uuid","type":["null","string"]},"customProperties":{"additionalProperties":{},"type":"object"},"department":{"type":"null"},"emails":{"items":{"properties":{"email":{"format":"email","type":"string"},"id":{"format":"uuid","type":"string"},"isPrimary":{"type":"boolean"},"label":{"type":"null"}},"required":["email","id","isPrimary","label"],"type":"object"},"type":"array"},"firstName":{"type":"string"},"id":{"format":"uuid","type":"string"},"jobTitle":{"type":["null","string"]},"lastActivityAt":{"format":"date-time","type":["null","string"]},"lastName":{"type":["null","string"]},"leadStatus":{"type":"null"},"lifecycleStage":{"type":["null","string"]},"locale":{"type":"null"},"marketingOptIn":{"type":"boolean"},"marketingOptInAt":{"type":"null"},"organizationId":{"format":"uuid","type":"string"},"ownerId":{"format":"uuid","type":["null","string"]},"phones":{"items":{"properties":{"id":{"format":"uuid","type":"string"},"isPrimary":{"type":"boolean"},"label":{"type":"null"},"phone":{"type":"string"}},"required":["id","phone","label","isPrimary"],"type":"object"},"type":"array"},"postalCode":{"type":"null"},"socialProfiles":{"properties":{"instagram":{"type":"string"}},"required":[],"type":"object"},"source":{"type":["null","string"]},"state":{"type":"null"},"tags":{"type":"array"},"timezone":{"type":"null"},"updatedAt":{"format":"date-time","type":"string"},"updatedBy":{"format":"uuid","type":["null","string"]}},"required":["address","archived","avatar","birthday","city","companies","country","createdAt","createdBy","customProperties","department","emails","firstName","id","jobTitle","lastActivityAt","lastName","leadStatus","lifecycleStage","locale","marketingOptIn","marketingOptInAt","organizationId","ownerId","phones","postalCode","socialProfiles","source","state","tags","timezone","updatedAt","updatedBy"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/contacts/{id}/duplicates":{"get":{"operationId":"GET /v1/contacts/{id}/duplicates","summary":"Contacts sharing an email, phone or social profile with this one (Pro).","tags":["contacts"],"x-feature":"contacts","x-action":"read","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"items":{"properties":{"contact":{"properties":{"createdAt":{"format":"date-time","type":"string"},"email":{"format":"email","type":"string"},"firstName":{"type":"string"},"id":{"format":"uuid","type":"string"},"lastName":{"type":"null"},"ownerId":{"format":"uuid","type":"string"},"phone":{"type":"string"}},"required":["id","firstName","lastName","email","phone","ownerId","createdAt"],"type":"object"},"matches":{"items":{"properties":{"field":{"type":"string"},"kind":{"type":"string"},"value":{"type":"string"}},"required":["kind","field","value"],"type":"object"},"type":"array"}},"required":["contact","matches"],"type":"object"},"type":"array"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/contacts/{id}/history":{"get":{"operationId":"GET /v1/contacts/{id}/history","summary":"Every change to a contact’s properties, with who made it.","tags":["contacts"],"x-feature":"contacts","x-action":"read","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}},{"name":"field","in":"query","required":true,"schema":{"type":"string","maxLength":120,"pattern":"^[A-Za-z]+(\\.[\\w-]+)?$"}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"entries":{"items":{"properties":{"changedAt":{"format":"date-time","type":"string"},"changedBy":{"properties":{"id":{"format":"uuid","type":"string"},"name":{"type":"string"}},"required":["id","name"],"type":"object"},"id":{"format":"uuid","type":"string"},"newLabel":{"type":["null","string"]},"newValue":{"items":{"properties":{"id":{"format":"uuid","type":"string"},"jobTitle":{"type":"string"},"name":{"type":"string"}},"required":["id","name"],"type":"object"},"type":["array","string"]},"oldLabel":{"type":"null"},"oldValue":{"items":{"properties":{"id":{"format":"uuid","type":"string"},"name":{"type":"string"}},"required":["id","name"],"type":"object"},"type":["array","null","string"]}},"required":["changedAt","changedBy","id","newLabel","newValue","oldLabel","oldValue"],"type":"object"},"type":"array"},"field":{"type":"string"},"limit":{"type":"integer"},"total":{"type":"integer"}},"required":["entries","field","limit","total"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/contacts/{id}/merge":{"post":{"operationId":"POST /v1/contacts/{id}/merge","summary":"Merges another contact into this one, moving everything linked to it.","tags":["contacts"],"x-feature":"contacts","x-action":"update","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"contactId":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},"choose":{"default":{},"type":"object","propertyNames":{"type":"string","maxLength":120},"additionalProperties":{"type":"string","enum":["kept","merged"]}}},"required":["contactId"]}}}},"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"address":{"type":"null"},"archived":{"type":"boolean"},"avatar":{"type":"null"},"birthday":{"type":"null"},"city":{"type":"null"},"companies":{"items":{"properties":{"companyId":{"format":"uuid","type":"string"},"isPrimary":{"type":"boolean"},"jobTitle":{"type":"null"},"name":{"type":"string"}},"required":["companyId","name","jobTitle","isPrimary"],"type":"object"},"type":"array"},"country":{"type":"null"},"createdAt":{"format":"date-time","type":"string"},"createdBy":{"format":"uuid","type":"string"},"customProperties":{"additionalProperties":{},"type":"object"},"department":{"type":"null"},"emails":{"items":{"properties":{"email":{"format":"email","type":"string"},"id":{"format":"uuid","type":"string"},"isPrimary":{"type":"boolean"},"label":{"type":"null"}},"required":["id","email","label","isPrimary"],"type":"object"},"type":"array"},"firstName":{"type":"string"},"id":{"format":"uuid","type":"string"},"jobTitle":{"type":["null","string"]},"lastActivityAt":{"type":"null"},"lastName":{"type":["null","string"]},"leadStatus":{"type":"null"},"lifecycleStage":{"type":["null","string"]},"locale":{"type":"null"},"marketingOptIn":{"type":"boolean"},"marketingOptInAt":{"type":"null"},"organizationId":{"format":"uuid","type":"string"},"ownerId":{"format":"uuid","type":"string"},"phones":{"items":{"properties":{"id":{"format":"uuid","type":"string"},"isPrimary":{"type":"boolean"},"label":{"type":"null"},"phone":{"type":"string"}},"required":["id","phone","label","isPrimary"],"type":"object"},"type":"array"},"postalCode":{"type":"null"},"socialProfiles":{"properties":{"instagram":{"type":"string"},"whatsapp":{"type":"string"}},"required":[],"type":"object"},"source":{"type":"null"},"state":{"type":"null"},"tags":{"items":{"properties":{"color":{"type":"string"},"id":{"format":"uuid","type":"string"},"name":{"type":"string"}},"required":["id","name","color"],"type":"object"},"type":"array"},"timezone":{"type":"null"},"updatedAt":{"format":"date-time","type":"string"},"updatedBy":{"format":"uuid","type":"string"}},"required":["address","archived","avatar","birthday","city","companies","country","createdAt","createdBy","customProperties","department","emails","firstName","id","jobTitle","lastActivityAt","lastName","leadStatus","lifecycleStage","locale","marketingOptIn","marketingOptInAt","organizationId","ownerId","phones","postalCode","socialProfiles","source","state","tags","timezone","updatedAt","updatedBy"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/contacts/{id}/merges":{"get":{"operationId":"GET /v1/contacts/{id}/merges","summary":"The contacts merged into this one, as they were.","tags":["contacts"],"x-feature":"contacts","x-action":"read","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"items":{"properties":{"automatic":{"type":"boolean"},"createdAt":{"format":"date-time","type":"string"},"id":{"format":"uuid","type":"string"},"kept":{"properties":{"address":{"type":"null"},"archived":{"type":"boolean"},"avatar":{"type":"null"},"birthday":{"type":"null"},"city":{"type":"null"},"companies":{"type":"array"},"country":{"type":"null"},"createdAt":{"format":"date-time","type":"string"},"createdBy":{"format":"uuid","type":"string"},"customProperties":{"additionalProperties":{},"type":"object"},"department":{"type":"null"},"emails":{"items":{"properties":{"email":{"format":"email","type":"string"},"id":{"format":"uuid","type":"string"},"isPrimary":{"type":"boolean"},"label":{"type":"null"}},"required":["id","email","label","isPrimary"],"type":"object"},"type":"array"},"firstName":{"type":"string"},"id":{"format":"uuid","type":"string"},"jobTitle":{"type":"null"},"lastActivityAt":{"type":"null"},"lastName":{"type":"null"},"leadStatus":{"type":"null"},"lifecycleStage":{"type":["null","string"]},"locale":{"type":"null"},"marketingOptIn":{"type":"boolean"},"marketingOptInAt":{"type":"null"},"organizationId":{"format":"uuid","type":"string"},"ownerId":{"format":"uuid","type":"string"},"phones":{"items":{"properties":{"id":{"format":"uuid","type":"string"},"isPrimary":{"type":"boolean"},"label":{"type":"null"},"phone":{"type":"string"}},"required":["id","label","phone","isPrimary"],"type":"object"},"type":"array"},"postalCode":{"type":"null"},"socialProfiles":{"properties":{"instagram":{"format":"uri","type":"string"},"whatsapp":{"type":"string"}},"required":[],"type":"object"},"source":{"type":"null"},"state":{"type":"null"},"tags":{"type":"array"},"timezone":{"type":"null"},"updatedAt":{"format":"date-time","type":"string"},"updatedBy":{"format":"uuid","type":"string"}},"required":["id","city","tags","state","avatar","emails","locale","phones","source","address","country","ownerId","archived","birthday","jobTitle","lastName","timezone","companies","createdAt","createdBy","firstName","updatedAt","updatedBy","department","leadStatus","postalCode","lastActivityAt","lifecycleStage","marketingOptIn","organizationId","socialProfiles","customProperties","marketingOptInAt"],"type":"object"},"matches":{"items":{"properties":{"field":{"type":"string"},"kind":{"type":"string"},"value":{"type":"string"}},"required":["kind","value"],"type":"object"},"type":"array"},"merged":{"properties":{"address":{"type":"null"},"archived":{"type":"boolean"},"avatar":{"type":"null"},"birthday":{"type":"null"},"city":{"type":"null"},"companies":{"items":{"properties":{"companyId":{"format":"uuid","type":"string"},"isPrimary":{"type":"boolean"},"jobTitle":{"type":"null"},"name":{"type":"string"}},"required":["name","jobTitle","companyId","isPrimary"],"type":"object"},"type":"array"},"country":{"type":"null"},"createdAt":{"format":"date-time","type":"string"},"createdBy":{"format":"uuid","type":["null","string"]},"customProperties":{"additionalProperties":{},"type":"object"},"department":{"type":"null"},"emails":{"items":{"properties":{"email":{"format":"email","type":"string"},"id":{"format":"uuid","type":"string"},"isPrimary":{"type":"boolean"},"label":{"type":"null"}},"required":["id","email","label","isPrimary"],"type":"object"},"type":"array"},"firstName":{"type":"string"},"id":{"format":"uuid","type":"string"},"jobTitle":{"type":["null","string"]},"lastActivityAt":{"type":"null"},"lastName":{"type":["null","string"]},"leadStatus":{"type":"null"},"lifecycleStage":{"type":["null","string"]},"lists":{"items":{"format":"uuid","type":"string"},"type":"array"},"locale":{"type":"null"},"marketingOptIn":{"type":"boolean"},"marketingOptInAt":{"type":"null"},"organizationId":{"format":"uuid","type":"string"},"ownerId":{"format":"uuid","type":["null","string"]},"phones":{"items":{"properties":{"id":{"format":"uuid","type":"string"},"isPrimary":{"type":"boolean"},"label":{"type":"null"},"phone":{"type":"string"}},"required":["id","label","phone","isPrimary"],"type":"object"},"type":"array"},"postalCode":{"type":"null"},"socialProfiles":{"properties":{"instagram":{"type":"string"},"whatsapp":{"type":"string"}},"required":[],"type":"object"},"source":{"type":"null"},"state":{"type":"null"},"tags":{"type":"array"},"timezone":{"type":"null"},"updatedAt":{"format":"date-time","type":"string"},"updatedBy":{"format":"uuid","type":["null","string"]}},"required":["id","city","tags","lists","state","avatar","emails","locale","phones","source","address","country","ownerId","archived","birthday","jobTitle","lastName","timezone","companies","createdAt","createdBy","firstName","updatedAt","updatedBy","department","leadStatus","postalCode","lastActivityAt","lifecycleStage","marketingOptIn","organizationId","socialProfiles","customProperties","marketingOptInAt"],"type":"object"},"mergedBy":{"properties":{"id":{"format":"uuid","type":"string"},"name":{"type":"string"}},"required":["id","name"],"type":["null","object"]},"mergedContactId":{"format":"uuid","type":"string"},"mergedName":{"type":"string"}},"required":["id","mergedContactId","mergedName","merged","kept","automatic","matches","createdAt","mergedBy"],"type":"object"},"type":"array"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/contacts/{id}/merges/{mergeId}/history":{"get":{"operationId":"GET /v1/contacts/{id}/merges/{mergeId}/history","summary":"A merged contact’s own property history.","tags":["contacts"],"x-feature":"contacts","x-action":"read","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}},{"name":"mergeId","in":"path","required":true,"schema":{"type":"string"}},{"name":"field","in":"query","required":true,"schema":{"type":"string","maxLength":120,"pattern":"^[A-Za-z]+(\\.[\\w-]+)?$"}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"entries":{"items":{"properties":{"changedAt":{"format":"date-time","type":"string"},"changedBy":{"properties":{"id":{"format":"uuid","type":"string"},"name":{"type":"string"}},"required":["id","name"],"type":"object"},"id":{"format":"uuid","type":"string"},"newLabel":{"type":"null"},"newValue":{"type":"string"},"oldLabel":{"type":"null"},"oldValue":{"type":"string"}},"required":["id","oldValue","newValue","changedAt","oldLabel","newLabel","changedBy"],"type":"object"},"type":"array"},"field":{"type":"string"},"limit":{"type":"integer"},"total":{"type":"integer"}},"required":["field","limit","total","entries"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/contacts/{id}/payments":{"get":{"operationId":"GET /v1/contacts/{id}/payments","summary":"What a contact paid, newest first.","tags":["payments"],"x-feature":"payments","x-action":"read","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}},{"name":"page","in":"query","required":false,"schema":{"default":1,"type":"integer","minimum":1,"maximum":9007199254740991}},{"name":"pageSize","in":"query","required":false,"schema":{"default":10,"type":"integer","minimum":1,"maximum":50}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"data":{"items":{"properties":{"amount":{"type":"integer"},"appointment":{"type":"null"},"at":{"format":"date-time","type":"string"},"currency":{"type":"string"},"deal":{"properties":{"id":{"format":"uuid","type":"string"},"reference":{"type":"null"},"title":{"type":"string"}},"required":["id","reference","title"],"type":["null","object"]},"file":{"type":"null"},"id":{"format":"uuid","type":"string"},"invoice":{"properties":{"id":{"format":"uuid","type":"string"},"number":{"type":"string"}},"required":["id","number"],"type":["null","object"]},"kind":{"type":"string"},"method":{"type":["null","string"]},"payerEmail":{"format":"email","type":["null","string"]},"payerName":{"type":["null","string"]},"recorded":{"properties":{"channel":{"type":["null","string"]},"company":{"properties":{"id":{"format":"uuid","type":"string"},"name":{"type":"string"}},"required":["id","name"],"type":["null","object"]},"contact":{"properties":{"id":{"format":"uuid","type":"string"},"name":{"type":"string"}},"required":["id","name"],"type":"object"},"description":{"type":["null","string"]},"items":{"items":{"properties":{"description":{"type":"null"},"discount":{"properties":{"type":{"type":"string"},"value":{"type":"integer"}},"required":["type","value"],"type":["null","object"]},"id":{"format":"uuid","type":"string"},"name":{"type":"string"},"quantity":{"type":"integer"},"serviceId":{"format":"uuid","type":["null","string"]},"unitPrice":{"type":"integer"}},"required":["id","name","discount","quantity","serviceId","unitPrice","description"],"type":"object"},"type":"array"},"recordedBy":{"type":"string"},"reference":{"type":["null","string"]}},"required":["description","items","contact","company","recordedBy","channel","reference"],"type":["null","object"]},"source":{"type":"string"},"status":{"type":"string"}},"required":["amount","appointment","at","currency","deal","file","id","invoice","kind","method","payerEmail","payerName","recorded","source","status"],"type":"object"},"type":"array"},"page":{"type":"integer"},"pageSize":{"type":"integer"},"paidTotals":{"items":{"properties":{"amount":{"type":"integer"},"currency":{"type":"string"}},"required":["amount","currency"],"type":"object"},"type":"array"},"total":{"type":"integer"}},"required":["data","page","pageSize","paidTotals","total"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/contract-templates":{"get":{"operationId":"GET /v1/contract-templates","summary":"Lists the contract templates.","tags":["contracts"],"x-feature":"contracts","x-action":"read","parameters":[{"name":"page","in":"query","required":false,"schema":{"default":1,"type":"integer","minimum":1,"maximum":9007199254740991}},{"name":"pageSize","in":"query","required":false,"schema":{"default":25,"type":"integer","minimum":1,"maximum":100}},{"name":"q","in":"query","required":false,"schema":{"type":"string","minLength":1,"maxLength":200}},{"name":"archived","in":"query","required":false,"schema":{"type":"string"}},{"name":"sort","in":"query","required":false,"schema":{"default":"updatedAt","type":"string","enum":["updatedAt","name"]}},{"name":"order","in":"query","required":false,"schema":{"default":"desc","type":"string","enum":["asc","desc"]}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"data":{"items":{"properties":{"contracts":{"properties":{"signed":{"type":"integer"},"total":{"type":"integer"}},"required":["total","signed"],"type":"object"},"createdAt":{"format":"date-time","type":"string"},"currency":{"type":"string"},"description":{"type":"null"},"fields":{"type":"integer"},"id":{"format":"uuid","type":"string"},"items":{"type":"integer"},"name":{"type":"string"},"title":{"type":"string"},"updatedAt":{"format":"date-time","type":"string"}},"required":["id","name","description","title","currency","fields","items","contracts","createdAt","updatedAt"],"type":"object"},"type":"array"},"page":{"type":"integer"},"pageSize":{"type":"integer"},"total":{"type":"integer"}},"required":["data","page","pageSize","total"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"post":{"operationId":"POST /v1/contract-templates","summary":"Creates a contract template.","tags":["contracts"],"x-feature":"contracts","x-action":"create","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"name":{"type":"string","minLength":1,"maxLength":120},"description":{"anyOf":[{"type":"string","maxLength":500},{"type":"null"}]},"title":{"type":"string","minLength":1,"maxLength":200},"body":{"default":"","type":"string","maxLength":200000},"fields":{"maxItems":50,"type":"array","items":{"type":"object","properties":{"key":{"type":"string","pattern":"^[a-zA-Z][a-zA-Z0-9_]{0,39}$"},"label":{"type":"string","minLength":1,"maxLength":100},"type":{"type":"string","enum":["text","longText","number","money","date","email","phone","taxId","address","select","checkbox"]},"filledBy":{"type":"string","enum":["team","signer"]},"required":{"default":false,"type":"boolean"},"help":{"anyOf":[{"type":"string","maxLength":200},{"type":"null"}]},"options":{"maxItems":30,"type":"array","items":{"type":"string","minLength":1,"maxLength":100}},"defaultValue":{"anyOf":[{"anyOf":[{"type":"string","maxLength":5000},{"type":"number"},{"type":"boolean"}]},{"type":"null"}]}},"required":["key","label","type","filledBy"]}},"items":{"maxItems":100,"type":"array","items":{"type":"object","properties":{"serviceId":{"anyOf":[{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},{"type":"null"}]},"name":{"type":"string","minLength":1,"maxLength":200},"description":{"anyOf":[{"type":"string","maxLength":1000},{"type":"null"}]},"quantity":{"type":"number","exclusiveMinimum":0,"maximum":1000000,"multipleOf":0.01},"unitPrice":{"type":"integer","minimum":0,"maximum":10000000000000}},"required":["name","quantity","unitPrice"]}},"currency":{"type":"string","pattern":"^[A-Za-z]{3}$"},"discount":{"anyOf":[{"oneOf":[{"type":"object","properties":{"type":{"type":"string","const":"percent"},"value":{"type":"number","exclusiveMinimum":0,"maximum":100,"multipleOf":0.01}},"required":["type","value"]},{"type":"object","properties":{"type":{"type":"string","const":"amount"},"value":{"type":"integer","exclusiveMinimum":0,"maximum":10000000000000}},"required":["type","value"]}]},{"type":"null"}]},"language":{"anyOf":[{"type":"string","enum":["pt","es","en","fr"]},{"type":"null"}]},"roles":{"default":[],"maxItems":10,"type":"array","items":{"type":"string","minLength":1,"maxLength":60}},"settings":{"type":"object","properties":{"requireTaxId":{"default":true,"type":"boolean"},"verifySignerEmail":{"default":true,"type":"boolean"},"expiresInDays":{"default":30,"anyOf":[{"type":"integer","minimum":1,"maximum":365},{"type":"null"}]},"chargeOnSign":{"default":false,"type":"boolean"}}}},"required":["name"]}}}},"responses":{"201":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"body":{"type":"string"},"createdAt":{"format":"date-time","type":"string"},"createdBy":{"format":"uuid","type":"string"},"currency":{"type":"string"},"description":{"type":"null"},"discount":{"properties":{"type":{"type":"string"},"value":{"type":"integer"}},"required":["type","value"],"type":["null","object"]},"fields":{"items":{"properties":{"defaultValue":{"type":"integer"},"filledBy":{"type":"string"},"key":{"type":"string"},"label":{"type":"string"},"options":{"items":{"type":"string"},"type":"array"},"required":{"type":"boolean"},"type":{"type":"string"}},"required":["key","type","label","filledBy","required"],"type":"object"},"type":"array"},"id":{"format":"uuid","type":"string"},"items":{"items":{"properties":{"name":{"type":"string"},"quantity":{"type":"integer"},"unitPrice":{"type":"integer"}},"required":["name","quantity","unitPrice"],"type":"object"},"type":"array"},"language":{"type":"null"},"name":{"type":"string"},"organizationId":{"format":"uuid","type":"string"},"roles":{"items":{"type":"string"},"type":"array"},"settings":{"properties":{"chargeOnSign":{"type":"boolean"},"expiresInDays":{"type":"integer"},"requireTaxId":{"type":"boolean"},"verifySignerEmail":{"type":"boolean"}},"required":["chargeOnSign","requireTaxId","expiresInDays","verifySignerEmail"],"type":"object"},"title":{"type":"string"},"updatedAt":{"format":"date-time","type":"string"},"updatedBy":{"format":"uuid","type":"string"},"variables":{"properties":{"organization.name":{"type":"string"},"organization.postalAddress":{"type":"null"}},"required":["organization.name","organization.postalAddress"],"type":"object"}},"required":["id","organizationId","name","description","title","body","fields","items","currency","discount","language","roles","settings","createdBy","updatedBy","createdAt","updatedAt","variables"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/contract-templates/{id}":{"delete":{"operationId":"DELETE /v1/contract-templates/{id}","summary":"Deletes a contract template.","tags":["contracts"],"x-feature":"contracts","x-action":"delete","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"204":{"description":"Done, with no content."},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"get":{"operationId":"GET /v1/contract-templates/{id}","summary":"Returns a contract template with its text, fields and settings.","tags":["contracts"],"x-feature":"contracts","x-action":"read","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"patch":{"operationId":"PATCH /v1/contract-templates/{id}","summary":"Changes a contract template; contracts made from it keep their copy.","tags":["contracts"],"x-feature":"contracts","x-action":"update","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"name":{"type":"string","minLength":1,"maxLength":120},"description":{"anyOf":[{"type":"string","maxLength":500},{"type":"null"}]},"title":{"type":"string","minLength":1,"maxLength":200},"body":{"type":"string","maxLength":200000},"fields":{"maxItems":50,"type":"array","items":{"type":"object","properties":{"key":{"type":"string","pattern":"^[a-zA-Z][a-zA-Z0-9_]{0,39}$"},"label":{"type":"string","minLength":1,"maxLength":100},"type":{"type":"string","enum":["text","longText","number","money","date","email","phone","taxId","address","select","checkbox"]},"filledBy":{"type":"string","enum":["team","signer"]},"required":{"default":false,"type":"boolean"},"help":{"anyOf":[{"type":"string","maxLength":200},{"type":"null"}]},"options":{"maxItems":30,"type":"array","items":{"type":"string","minLength":1,"maxLength":100}},"defaultValue":{"anyOf":[{"anyOf":[{"type":"string","maxLength":5000},{"type":"number"},{"type":"boolean"}]},{"type":"null"}]}},"required":["key","label","type","filledBy"]}},"items":{"maxItems":100,"type":"array","items":{"type":"object","properties":{"serviceId":{"anyOf":[{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},{"type":"null"}]},"name":{"type":"string","minLength":1,"maxLength":200},"description":{"anyOf":[{"type":"string","maxLength":1000},{"type":"null"}]},"quantity":{"type":"number","exclusiveMinimum":0,"maximum":1000000,"multipleOf":0.01},"unitPrice":{"type":"integer","minimum":0,"maximum":10000000000000}},"required":["name","quantity","unitPrice"]}},"currency":{"type":"string","pattern":"^[A-Za-z]{3}$"},"discount":{"anyOf":[{"oneOf":[{"type":"object","properties":{"type":{"type":"string","const":"percent"},"value":{"type":"number","exclusiveMinimum":0,"maximum":100,"multipleOf":0.01}},"required":["type","value"]},{"type":"object","properties":{"type":{"type":"string","const":"amount"},"value":{"type":"integer","exclusiveMinimum":0,"maximum":10000000000000}},"required":["type","value"]}]},{"type":"null"}]},"language":{"anyOf":[{"type":"string","enum":["pt","es","en","fr"]},{"type":"null"}]},"roles":{"maxItems":10,"type":"array","items":{"type":"string","minLength":1,"maxLength":60}},"settings":{"type":"object","properties":{"requireTaxId":{"default":true,"type":"boolean"},"verifySignerEmail":{"default":true,"type":"boolean"},"expiresInDays":{"default":30,"anyOf":[{"type":"integer","minimum":1,"maximum":365},{"type":"null"}]},"chargeOnSign":{"default":false,"type":"boolean"}}}}}}}},"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/contract-templates/{id}/duplicate":{"post":{"operationId":"POST /v1/contract-templates/{id}/duplicate","summary":"Copies a contract template.","tags":["contracts"],"x-feature":"contracts","x-action":"create","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"201":{"description":"Success.","content":{"application/json":{"schema":{}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/contract-templates/variables":{"get":{"operationId":"GET /v1/contract-templates/variables","summary":"The `{{...}}` variables a contract can show: contact, company, organization and fields.","tags":["contracts"],"x-feature":"contracts","x-action":"read","responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/contracts":{"get":{"operationId":"GET /v1/contracts","summary":"Lists contracts, by status, contact or template.","tags":["contracts"],"x-feature":"contracts","x-action":"read","parameters":[{"name":"page","in":"query","required":false,"schema":{"default":1,"type":"integer","minimum":1,"maximum":9007199254740991}},{"name":"pageSize","in":"query","required":false,"schema":{"default":25,"type":"integer","minimum":1,"maximum":100}},{"name":"q","in":"query","required":false,"schema":{"type":"string","minLength":1,"maxLength":200}},{"name":"archived","in":"query","required":false,"schema":{"type":"string"}},{"name":"status","in":"query","required":false,"schema":{"type":"string","enum":["draft","sent","signed","declined","canceled","expired"]}},{"name":"templateId","in":"query","required":false,"schema":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"}},{"name":"contactId","in":"query","required":false,"schema":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"}},{"name":"companyId","in":"query","required":false,"schema":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"}},{"name":"ownerId","in":"query","required":false,"schema":{"type":"string","minLength":1}},{"name":"sort","in":"query","required":false,"schema":{"default":"createdAt","type":"string","enum":["createdAt","title"]}},{"name":"order","in":"query","required":false,"schema":{"default":"desc","type":"string","enum":["asc","desc"]}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"data":{"items":{"properties":{"completedAt":{"format":"date-time","type":"string"},"contact":{"properties":{"id":{"format":"uuid","type":"string"},"name":{"type":"string"}},"required":["id","name"],"type":"object"},"createdAt":{"format":"date-time","type":"string"},"currency":{"type":"string"},"expiresAt":{"format":"date-time","type":"string"},"id":{"format":"uuid","type":"string"},"ownerId":{"format":"uuid","type":"string"},"sentAt":{"format":"date-time","type":"string"},"signers":{"properties":{"signed":{"type":"integer"},"total":{"type":"integer"}},"required":["total","signed"],"type":"object"},"status":{"type":"string"},"template":{"properties":{"id":{"format":"uuid","type":"string"},"name":{"type":"string"}},"required":["id","name"],"type":"object"},"title":{"type":"string"},"total":{"type":"integer"}},"required":["id","title","status","total","currency","template","contact","signers","ownerId","expiresAt","sentAt","completedAt","createdAt"],"type":"object"},"type":"array"},"page":{"type":"integer"},"pageSize":{"type":"integer"},"total":{"type":"integer"}},"required":["data","page","pageSize","total"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"post":{"operationId":"POST /v1/contracts","summary":"Creates a contract draft from a template.","tags":["contracts"],"x-feature":"contracts","x-action":"create","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"templateId":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},"title":{"type":"string","minLength":1,"maxLength":200},"contactId":{"anyOf":[{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},{"type":"null"}]},"companyId":{"anyOf":[{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},{"type":"null"}]},"message":{"anyOf":[{"type":"string","maxLength":5000},{"type":"null"}]},"signers":{"maxItems":10,"type":"array","items":{"type":"object","properties":{"contactId":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},"email":{"type":"string","maxLength":320,"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,}$"},"name":{"type":"string","minLength":1,"maxLength":200},"role":{"anyOf":[{"type":"string","maxLength":60},{"type":"null"}]}}}},"values":{"type":"object","propertyNames":{"type":"string"},"additionalProperties":{"anyOf":[{"type":"string","maxLength":5000},{"type":"number"},{"type":"boolean"},{"type":"null"}]}}}}}}},"responses":{"201":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"body":{"type":"string"},"canceledAt":{"type":"null"},"company":{"type":"null"},"completedAt":{"type":"null"},"contact":{"properties":{"id":{"format":"uuid","type":"string"},"name":{"type":"string"}},"required":["id","name"],"type":["null","object"]},"contentHash":{"type":"null"},"context":{"additionalProperties":{},"type":"object"},"createdAt":{"format":"date-time","type":"string"},"createdBy":{"format":"uuid","type":"string"},"currency":{"type":"string"},"discount":{"properties":{"type":{"type":"string"},"value":{"type":"integer"}},"required":["type","value"],"type":["null","object"]},"expiresAt":{"type":"null"},"fields":{"items":{"properties":{"defaultValue":{"type":"integer"},"filledBy":{"type":"string"},"key":{"type":"string"},"label":{"type":"string"},"options":{"items":{"type":"string"},"type":"array"},"required":{"type":"boolean"},"type":{"type":"string"}},"required":["key","type","label","filledBy","required"],"type":"object"},"type":"array"},"id":{"format":"uuid","type":"string"},"invoiceId":{"type":"null"},"items":{"items":{"properties":{"name":{"type":"string"},"quantity":{"type":"integer"},"unitPrice":{"type":"integer"}},"required":["name","quantity","unitPrice"],"type":"object"},"type":"array"},"language":{"type":"null"},"message":{"type":"null"},"organizationId":{"format":"uuid","type":"string"},"ownerId":{"format":"uuid","type":"string"},"payment":{"type":"null"},"sentAt":{"type":"null"},"settings":{"properties":{"chargeOnSign":{"type":"boolean"},"expiresInDays":{"type":"integer"},"requireTaxId":{"type":"boolean"},"verifySignerEmail":{"type":"boolean"}},"required":["chargeOnSign","requireTaxId","expiresInDays","verifySignerEmail"],"type":"object"},"signers":{"items":{"properties":{"contactId":{"format":"uuid","type":["null","string"]},"decidedAt":{"type":"null"},"declineReason":{"type":"null"},"documentHash":{"type":"null"},"email":{"format":"email","type":"string"},"firstViewedAt":{"type":"null"},"id":{"format":"uuid","type":"string"},"ipAddress":{"type":"null"},"lastViewedAt":{"type":"null"},"name":{"type":["null","string"]},"position":{"type":"integer"},"role":{"type":["null","string"]},"sendCount":{"type":"integer"},"sentAt":{"type":"null"},"signature":{"type":"null"},"signerName":{"type":"null"},"signerTaxId":{"type":"null"},"status":{"type":"string"},"url":{"type":"null"},"userAgent":{"type":"null"},"verification":{"type":"null"},"viewCount":{"type":"integer"}},"required":["id","contactId","name","email","role","position","status","url","sentAt","sendCount","viewCount","firstViewedAt","lastViewedAt","decidedAt","signerName","signerTaxId","signature","documentHash","ipAddress","userAgent","declineReason","verification"],"type":"object"},"type":"array"},"status":{"type":"string"},"template":{"properties":{"id":{"format":"uuid","type":"string"},"name":{"type":"string"},"roles":{"items":{"type":"string"},"type":"array"}},"required":["id","name","roles"],"type":["null","object"]},"title":{"type":"string"},"total":{"type":"integer"},"updatedAt":{"format":"date-time","type":"string"},"updatedBy":{"format":"uuid","type":"string"},"values":{"additionalProperties":{},"type":"object"}},"required":["id","organizationId","title","status","message","ownerId","body","fields","values","items","currency","discount","language","settings","contentHash","invoiceId","expiresAt","sentAt","completedAt","canceledAt","createdBy","updatedBy","createdAt","updatedAt","total","contact","company","template","context","payment","signers"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/contracts/{id}":{"delete":{"operationId":"DELETE /v1/contracts/{id}","summary":"Deletes a contract.","tags":["contracts"],"x-feature":"contracts","x-action":"delete","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"204":{"description":"Done, with no content."},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"get":{"operationId":"GET /v1/contracts/{id}","summary":"Returns a contract with its signers and their signatures.","tags":["contracts"],"x-feature":"contracts","x-action":"read","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"body":{"type":"string"},"canceledAt":{"type":"null"},"company":{"type":"null"},"completedAt":{"format":"date-time","type":["null","string"]},"contact":{"properties":{"id":{"format":"uuid","type":"string"},"name":{"type":"string"}},"required":["id","name"],"type":["null","object"]},"contentHash":{"type":["null","string"]},"context":{"additionalProperties":{},"type":"object"},"createdAt":{"format":"date-time","type":"string"},"createdBy":{"format":"uuid","type":"string"},"currency":{"type":"string"},"discount":{"properties":{"type":{"type":"string"},"value":{"type":"integer"}},"required":["type","value"],"type":["null","object"]},"expiresAt":{"format":"date-time","type":["null","string"]},"fields":{"items":{"properties":{"defaultValue":{"type":"integer"},"filledBy":{"type":"string"},"key":{"type":"string"},"label":{"type":"string"},"options":{"items":{"type":"string"},"type":"array"},"required":{"type":"boolean"},"type":{"type":"string"}},"required":["key","type","label","filledBy","required"],"type":"object"},"type":"array"},"id":{"format":"uuid","type":"string"},"invoiceId":{"format":"uuid","type":["null","string"]},"items":{"items":{"properties":{"name":{"type":"string"},"quantity":{"type":"integer"},"unitPrice":{"type":"integer"}},"required":["name","quantity","unitPrice"],"type":"object"},"type":"array"},"language":{"type":["null","string"]},"message":{"type":"null"},"organizationId":{"format":"uuid","type":"string"},"ownerId":{"format":"uuid","type":"string"},"payment":{"properties":{"amount":{"type":"integer"},"canPay":{"type":"boolean"},"currency":{"type":"string"},"invoice":{"properties":{"id":{"format":"uuid","type":"string"},"number":{"type":"string"},"url":{"format":"uri","type":"string"}},"required":["id","number","url"],"type":"object"},"paidAt":{"type":"null"},"status":{"type":"string"}},"required":["amount","currency","status","paidAt","canPay","invoice"],"type":["null","object"]},"sentAt":{"format":"date-time","type":["null","string"]},"settings":{"properties":{"chargeOnSign":{"type":"boolean"},"expiresInDays":{"type":"integer"},"requireTaxId":{"type":"boolean"},"verifySignerEmail":{"type":"boolean"}},"required":["chargeOnSign","requireTaxId","expiresInDays","verifySignerEmail"],"type":"object"},"signers":{"items":{"properties":{"contactId":{"format":"uuid","type":["null","string"]},"decidedAt":{"format":"date-time","type":["null","string"]},"declineReason":{"type":["null","string"]},"documentHash":{"type":["null","string"]},"email":{"format":"email","type":"string"},"firstViewedAt":{"format":"date-time","type":["null","string"]},"id":{"format":"uuid","type":"string"},"ipAddress":{"type":["null","string"]},"lastViewedAt":{"format":"date-time","type":["null","string"]},"name":{"type":["null","string"]},"position":{"type":"integer"},"role":{"type":["null","string"]},"sendCount":{"type":"integer"},"sentAt":{"format":"date-time","type":["null","string"]},"signature":{"properties":{"image":{"type":"string"},"kind":{"type":"string"},"text":{"type":"string"}},"required":["kind"],"type":["null","object"]},"signerName":{"type":["null","string"]},"signerTaxId":{"type":["null","string"]},"status":{"type":"string"},"url":{"format":"uri","type":["null","string"]},"userAgent":{"type":"null"},"verification":{"properties":{"sendCount":{"type":"integer"},"sentAt":{"format":"date-time","type":"string"},"verifiedAt":{"format":"date-time","type":["null","string"]}},"required":["sentAt","sendCount","verifiedAt"],"type":["null","object"]},"viewCount":{"type":"integer"}},"required":["id","contactId","name","email","role","position","status","url","sentAt","sendCount","viewCount","firstViewedAt","lastViewedAt","decidedAt","signerName","signerTaxId","signature","documentHash","ipAddress","userAgent","declineReason","verification"],"type":"object"},"type":"array"},"status":{"type":"string"},"template":{"properties":{"id":{"format":"uuid","type":"string"},"name":{"type":"string"},"roles":{"items":{"type":"string"},"type":"array"}},"required":["id","name","roles"],"type":["null","object"]},"title":{"type":"string"},"total":{"type":"integer"},"updatedAt":{"format":"date-time","type":"string"},"updatedBy":{"format":"uuid","type":"string"},"values":{"additionalProperties":{},"type":"object"}},"required":["id","organizationId","title","status","message","ownerId","body","fields","values","items","currency","discount","language","settings","contentHash","invoiceId","expiresAt","sentAt","completedAt","canceledAt","createdBy","updatedBy","createdAt","updatedAt","total","contact","company","template","context","payment","signers"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"patch":{"operationId":"PATCH /v1/contracts/{id}","summary":"Changes a contract draft: text, fields, prices and signers.","tags":["contracts"],"x-feature":"contracts","x-action":"update","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"title":{"type":"string","minLength":1,"maxLength":200},"body":{"type":"string","maxLength":200000},"fields":{"maxItems":50,"type":"array","items":{"type":"object","properties":{"key":{"type":"string","pattern":"^[a-zA-Z][a-zA-Z0-9_]{0,39}$"},"label":{"type":"string","minLength":1,"maxLength":100},"type":{"type":"string","enum":["text","longText","number","money","date","email","phone","taxId","address","select","checkbox"]},"filledBy":{"type":"string","enum":["team","signer"]},"required":{"default":false,"type":"boolean"},"help":{"anyOf":[{"type":"string","maxLength":200},{"type":"null"}]},"options":{"maxItems":30,"type":"array","items":{"type":"string","minLength":1,"maxLength":100}},"defaultValue":{"anyOf":[{"anyOf":[{"type":"string","maxLength":5000},{"type":"number"},{"type":"boolean"}]},{"type":"null"}]}},"required":["key","label","type","filledBy"]}},"items":{"maxItems":100,"type":"array","items":{"type":"object","properties":{"serviceId":{"anyOf":[{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},{"type":"null"}]},"name":{"type":"string","minLength":1,"maxLength":200},"description":{"anyOf":[{"type":"string","maxLength":1000},{"type":"null"}]},"quantity":{"type":"number","exclusiveMinimum":0,"maximum":1000000,"multipleOf":0.01},"unitPrice":{"type":"integer","minimum":0,"maximum":10000000000000}},"required":["name","quantity","unitPrice"]}},"currency":{"type":"string","pattern":"^[A-Za-z]{3}$"},"discount":{"anyOf":[{"oneOf":[{"type":"object","properties":{"type":{"type":"string","const":"percent"},"value":{"type":"number","exclusiveMinimum":0,"maximum":100,"multipleOf":0.01}},"required":["type","value"]},{"type":"object","properties":{"type":{"type":"string","const":"amount"},"value":{"type":"integer","exclusiveMinimum":0,"maximum":10000000000000}},"required":["type","value"]}]},{"type":"null"}]},"language":{"anyOf":[{"type":"string","enum":["pt","es","en","fr"]},{"type":"null"}]},"contactId":{"anyOf":[{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},{"type":"null"}]},"companyId":{"anyOf":[{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},{"type":"null"}]},"message":{"anyOf":[{"type":"string","maxLength":5000},{"type":"null"}]},"signers":{"maxItems":10,"type":"array","items":{"type":"object","properties":{"contactId":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},"email":{"type":"string","maxLength":320,"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,}$"},"name":{"type":"string","minLength":1,"maxLength":200},"role":{"anyOf":[{"type":"string","maxLength":60},{"type":"null"}]}}}},"values":{"type":"object","propertyNames":{"type":"string"},"additionalProperties":{"anyOf":[{"type":"string","maxLength":5000},{"type":"number"},{"type":"boolean"},{"type":"null"}]}},"settings":{"type":"object","properties":{"requireTaxId":{"default":true,"type":"boolean"},"verifySignerEmail":{"default":true,"type":"boolean"},"expiresInDays":{"default":30,"anyOf":[{"type":"integer","minimum":1,"maximum":365},{"type":"null"}]},"chargeOnSign":{"default":false,"type":"boolean"}}},"expiresAt":{"anyOf":[{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"},{"type":"null"}]}}}}}},"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"body":{"type":"string"},"canceledAt":{"type":"null"},"company":{"type":"null"},"completedAt":{"type":"null"},"contact":{"properties":{"id":{"format":"uuid","type":"string"},"name":{"type":"string"}},"required":["id","name"],"type":["null","object"]},"contentHash":{"type":"null"},"context":{"additionalProperties":{},"type":"object"},"createdAt":{"format":"date-time","type":"string"},"createdBy":{"format":"uuid","type":"string"},"currency":{"type":"string"},"discount":{"properties":{"type":{"type":"string"},"value":{"type":"integer"}},"required":["type","value"],"type":["null","object"]},"expiresAt":{"format":"date-time","type":["null","string"]},"fields":{"items":{"properties":{"defaultValue":{"type":"integer"},"filledBy":{"type":"string"},"key":{"type":"string"},"label":{"type":"string"},"options":{"items":{"type":"string"},"type":"array"},"required":{"type":"boolean"},"type":{"type":"string"}},"required":["key","type","label","filledBy","required"],"type":"object"},"type":"array"},"id":{"format":"uuid","type":"string"},"invoiceId":{"type":"null"},"items":{"items":{"properties":{"name":{"type":"string"},"quantity":{"type":"integer"},"unitPrice":{"type":"integer"}},"required":["name","quantity","unitPrice"],"type":"object"},"type":"array"},"language":{"type":"null"},"message":{"type":"null"},"organizationId":{"format":"uuid","type":"string"},"ownerId":{"format":"uuid","type":"string"},"payment":{"type":"null"},"sentAt":{"type":"null"},"settings":{"properties":{"chargeOnSign":{"type":"boolean"},"expiresInDays":{"type":"integer"},"requireTaxId":{"type":"boolean"},"verifySignerEmail":{"type":"boolean"}},"required":["chargeOnSign","requireTaxId","expiresInDays","verifySignerEmail"],"type":"object"},"signers":{"items":{"properties":{"contactId":{"format":"uuid","type":["null","string"]},"decidedAt":{"type":"null"},"declineReason":{"type":"null"},"documentHash":{"type":"null"},"email":{"format":"email","type":"string"},"firstViewedAt":{"type":"null"},"id":{"format":"uuid","type":"string"},"ipAddress":{"type":"null"},"lastViewedAt":{"type":"null"},"name":{"type":["null","string"]},"position":{"type":"integer"},"role":{"type":["null","string"]},"sendCount":{"type":"integer"},"sentAt":{"type":"null"},"signature":{"type":"null"},"signerName":{"type":"null"},"signerTaxId":{"type":"null"},"status":{"type":"string"},"url":{"type":"null"},"userAgent":{"type":"null"},"verification":{"type":"null"},"viewCount":{"type":"integer"}},"required":["id","contactId","name","email","role","position","status","url","sentAt","sendCount","viewCount","firstViewedAt","lastViewedAt","decidedAt","signerName","signerTaxId","signature","documentHash","ipAddress","userAgent","declineReason","verification"],"type":"object"},"type":"array"},"status":{"type":"string"},"template":{"properties":{"id":{"format":"uuid","type":"string"},"name":{"type":"string"},"roles":{"items":{"type":"string"},"type":"array"}},"required":["id","name","roles"],"type":["null","object"]},"title":{"type":"string"},"total":{"type":"integer"},"updatedAt":{"format":"date-time","type":"string"},"updatedBy":{"format":"uuid","type":"string"},"values":{"additionalProperties":{},"type":"object"}},"required":["id","organizationId","title","status","message","ownerId","body","fields","values","items","currency","discount","language","settings","contentHash","invoiceId","expiresAt","sentAt","completedAt","canceledAt","createdBy","updatedBy","createdAt","updatedAt","total","contact","company","template","context","payment","signers"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/contracts/{id}/cancel":{"post":{"operationId":"POST /v1/contracts/{id}/cancel","summary":"Cancels a sent contract; its links stop working.","tags":["contracts"],"x-feature":"contracts","x-action":"update","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"body":{"type":"string"},"canceledAt":{"format":"date-time","type":"string"},"company":{"type":"null"},"completedAt":{"type":"null"},"contact":{"type":"null"},"contentHash":{"type":"string"},"context":{"additionalProperties":{},"type":"object"},"createdAt":{"format":"date-time","type":"string"},"createdBy":{"format":"uuid","type":"string"},"currency":{"type":"string"},"discount":{"type":"null"},"expiresAt":{"format":"date-time","type":"string"},"fields":{"type":"array"},"id":{"format":"uuid","type":"string"},"invoiceId":{"type":"null"},"items":{"type":"array"},"language":{"type":"string"},"message":{"type":"null"},"organizationId":{"format":"uuid","type":"string"},"ownerId":{"format":"uuid","type":"string"},"payment":{"type":"null"},"sentAt":{"format":"date-time","type":"string"},"settings":{"properties":{"chargeOnSign":{"type":"boolean"},"expiresInDays":{"type":"integer"},"requireTaxId":{"type":"boolean"},"verifySignerEmail":{"type":"boolean"}},"required":["chargeOnSign","requireTaxId","expiresInDays","verifySignerEmail"],"type":"object"},"signers":{"items":{"properties":{"contactId":{"type":"null"},"decidedAt":{"type":"null"},"declineReason":{"type":"null"},"documentHash":{"type":"null"},"email":{"format":"email","type":"string"},"firstViewedAt":{"type":"null"},"id":{"format":"uuid","type":"string"},"ipAddress":{"type":"null"},"lastViewedAt":{"type":"null"},"name":{"type":"string"},"position":{"type":"integer"},"role":{"type":"null"},"sendCount":{"type":"integer"},"sentAt":{"format":"date-time","type":"string"},"signature":{"type":"null"},"signerName":{"type":"null"},"signerTaxId":{"type":"null"},"status":{"type":"string"},"url":{"format":"uri","type":"string"},"userAgent":{"type":"null"},"verification":{"type":"null"},"viewCount":{"type":"integer"}},"required":["id","contactId","name","email","role","position","status","url","sentAt","sendCount","viewCount","firstViewedAt","lastViewedAt","decidedAt","signerName","signerTaxId","signature","documentHash","ipAddress","userAgent","declineReason","verification"],"type":"object"},"type":"array"},"status":{"type":"string"},"template":{"type":"null"},"title":{"type":"string"},"total":{"type":"integer"},"updatedAt":{"format":"date-time","type":"string"},"updatedBy":{"format":"uuid","type":"string"},"values":{"additionalProperties":{},"type":"object"}},"required":["id","organizationId","title","status","message","ownerId","body","fields","values","items","currency","discount","language","settings","contentHash","invoiceId","expiresAt","sentAt","completedAt","canceledAt","createdBy","updatedBy","createdAt","updatedAt","total","contact","company","template","context","payment","signers"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/contracts/{id}/duplicate":{"post":{"operationId":"POST /v1/contracts/{id}/duplicate","summary":"A new draft with the same content and signers.","tags":["contracts"],"x-feature":"contracts","x-action":"create","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"201":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"body":{"type":"string"},"canceledAt":{"type":"null"},"company":{"type":"null"},"completedAt":{"type":"null"},"contact":{"properties":{"id":{"format":"uuid","type":"string"},"name":{"type":"string"}},"required":["id","name"],"type":"object"},"contentHash":{"type":"null"},"context":{"additionalProperties":{},"type":"object"},"createdAt":{"format":"date-time","type":"string"},"createdBy":{"format":"uuid","type":"string"},"currency":{"type":"string"},"discount":{"properties":{"type":{"type":"string"},"value":{"type":"integer"}},"required":["type","value"],"type":"object"},"expiresAt":{"type":"null"},"fields":{"items":{"properties":{"defaultValue":{"type":"integer"},"filledBy":{"type":"string"},"key":{"type":"string"},"label":{"type":"string"},"options":{"items":{"type":"string"},"type":"array"},"required":{"type":"boolean"},"type":{"type":"string"}},"required":["key","type","label","filledBy","required"],"type":"object"},"type":"array"},"id":{"format":"uuid","type":"string"},"invoiceId":{"type":"null"},"items":{"items":{"properties":{"name":{"type":"string"},"quantity":{"type":"integer"},"unitPrice":{"type":"integer"}},"required":["name","quantity","unitPrice"],"type":"object"},"type":"array"},"language":{"type":"string"},"message":{"type":"null"},"organizationId":{"format":"uuid","type":"string"},"ownerId":{"format":"uuid","type":"string"},"payment":{"type":"null"},"sentAt":{"type":"null"},"settings":{"properties":{"chargeOnSign":{"type":"boolean"},"expiresInDays":{"type":"integer"},"requireTaxId":{"type":"boolean"},"verifySignerEmail":{"type":"boolean"}},"required":["chargeOnSign","requireTaxId","expiresInDays","verifySignerEmail"],"type":"object"},"signers":{"items":{"properties":{"contactId":{"format":"uuid","type":["null","string"]},"decidedAt":{"type":"null"},"declineReason":{"type":"null"},"documentHash":{"type":"null"},"email":{"format":"email","type":"string"},"firstViewedAt":{"type":"null"},"id":{"format":"uuid","type":"string"},"ipAddress":{"type":"null"},"lastViewedAt":{"type":"null"},"name":{"type":"string"},"position":{"type":"integer"},"role":{"type":"string"},"sendCount":{"type":"integer"},"sentAt":{"type":"null"},"signature":{"type":"null"},"signerName":{"type":"null"},"signerTaxId":{"type":"null"},"status":{"type":"string"},"url":{"type":"null"},"userAgent":{"type":"null"},"verification":{"type":"null"},"viewCount":{"type":"integer"}},"required":["id","contactId","name","email","role","position","status","url","sentAt","sendCount","viewCount","firstViewedAt","lastViewedAt","decidedAt","signerName","signerTaxId","signature","documentHash","ipAddress","userAgent","declineReason","verification"],"type":"object"},"type":"array"},"status":{"type":"string"},"template":{"properties":{"id":{"format":"uuid","type":"string"},"name":{"type":"string"},"roles":{"items":{"type":"string"},"type":"array"}},"required":["id","name","roles"],"type":"object"},"title":{"type":"string"},"total":{"type":"integer"},"updatedAt":{"format":"date-time","type":"string"},"updatedBy":{"format":"uuid","type":"string"},"values":{"additionalProperties":{},"type":"object"}},"required":["id","organizationId","title","status","message","ownerId","body","fields","values","items","currency","discount","language","settings","contentHash","invoiceId","expiresAt","sentAt","completedAt","canceledAt","createdBy","updatedBy","createdAt","updatedAt","total","contact","company","template","context","payment","signers"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/contracts/{id}/send":{"post":{"operationId":"POST /v1/contracts/{id}/send","summary":"Sends the draft: each signer uses one of the month’s signatures and gets their link.","tags":["contracts"],"x-feature":"contracts","x-action":"update","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"body":{"type":"string"},"canceledAt":{"type":"null"},"company":{"type":"null"},"completedAt":{"type":"null"},"contact":{"properties":{"id":{"format":"uuid","type":"string"},"name":{"type":"string"}},"required":["id","name"],"type":["null","object"]},"contentHash":{"type":"string"},"context":{"additionalProperties":{},"type":"object"},"createdAt":{"format":"date-time","type":"string"},"createdBy":{"format":"uuid","type":"string"},"currency":{"type":"string"},"discount":{"properties":{"type":{"type":"string"},"value":{"type":"integer"}},"required":["type","value"],"type":["null","object"]},"expiresAt":{"format":"date-time","type":"string"},"fields":{"items":{"properties":{"defaultValue":{"type":"integer"},"filledBy":{"type":"string"},"key":{"type":"string"},"label":{"type":"string"},"options":{"items":{"type":"string"},"type":"array"},"required":{"type":"boolean"},"type":{"type":"string"}},"required":["key","type","label","filledBy","required"],"type":"object"},"type":"array"},"id":{"format":"uuid","type":"string"},"invoiceId":{"type":"null"},"items":{"items":{"properties":{"name":{"type":"string"},"quantity":{"type":"integer"},"unitPrice":{"type":"integer"}},"required":["name","quantity","unitPrice"],"type":"object"},"type":"array"},"language":{"type":"string"},"message":{"type":"null"},"organizationId":{"format":"uuid","type":"string"},"ownerId":{"format":"uuid","type":"string"},"payment":{"type":"null"},"sentAt":{"format":"date-time","type":"string"},"settings":{"properties":{"chargeOnSign":{"type":"boolean"},"expiresInDays":{"type":"integer"},"requireTaxId":{"type":"boolean"},"verifySignerEmail":{"type":"boolean"}},"required":["chargeOnSign","requireTaxId","expiresInDays","verifySignerEmail"],"type":"object"},"signers":{"items":{"properties":{"contactId":{"format":"uuid","type":["null","string"]},"decidedAt":{"type":"null"},"declineReason":{"type":"null"},"documentHash":{"type":"null"},"email":{"format":"email","type":"string"},"firstViewedAt":{"type":"null"},"id":{"format":"uuid","type":"string"},"ipAddress":{"type":"null"},"lastViewedAt":{"type":"null"},"name":{"type":["null","string"]},"position":{"type":"integer"},"role":{"type":["null","string"]},"sendCount":{"type":"integer"},"sentAt":{"format":"date-time","type":["null","string"]},"signature":{"type":"null"},"signerName":{"type":"null"},"signerTaxId":{"type":"null"},"status":{"type":"string"},"url":{"format":"uri","type":"string"},"userAgent":{"type":"null"},"verification":{"type":"null"},"viewCount":{"type":"integer"}},"required":["id","contactId","name","email","role","position","status","url","sentAt","sendCount","viewCount","firstViewedAt","lastViewedAt","decidedAt","signerName","signerTaxId","signature","documentHash","ipAddress","userAgent","declineReason","verification"],"type":"object"},"type":"array"},"status":{"type":"string"},"template":{"properties":{"id":{"format":"uuid","type":"string"},"name":{"type":"string"},"roles":{"items":{"type":"string"},"type":"array"}},"required":["id","name","roles"],"type":["null","object"]},"title":{"type":"string"},"total":{"type":"integer"},"updatedAt":{"format":"date-time","type":"string"},"updatedBy":{"format":"uuid","type":"string"},"values":{"additionalProperties":{},"type":"object"}},"required":["id","organizationId","title","status","message","ownerId","body","fields","values","items","currency","discount","language","settings","contentHash","invoiceId","expiresAt","sentAt","completedAt","canceledAt","createdBy","updatedBy","createdAt","updatedAt","total","contact","company","template","context","payment","signers"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/contracts/{id}/signers/{signerId}/resend":{"post":{"operationId":"POST /v1/contracts/{id}/signers/{signerId}/resend","summary":"Emails a signer their link again.","tags":["contracts"],"x-feature":"contracts","x-action":"update","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}},{"name":"signerId","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/contracts/{id}/signers/{signerId}/verification/resend":{"post":{"operationId":"POST /v1/contracts/{id}/signers/{signerId}/verification/resend","summary":"Sends a signer a new link to confirm their email address.","tags":["contracts"],"x-feature":"contracts","x-action":"update","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}},{"name":"signerId","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/custom-properties":{"get":{"operationId":"GET /v1/custom-properties","summary":"The custom properties of contacts, companies and deals.","tags":["customProperties"],"x-feature":"customProperties","x-action":"read","responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/custom-properties/{entity}":{"get":{"operationId":"GET /v1/custom-properties/{entity}","summary":"The custom properties of one kind of record.","tags":["customProperties"],"x-feature":"customProperties","x-action":"read","parameters":[{"name":"entity","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"post":{"operationId":"POST /v1/custom-properties/{entity}","summary":"Creates a custom property: its type, options and where it shows.","tags":["customProperties"],"x-feature":"customProperties","x-action":"create","parameters":[{"name":"entity","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"key":{"type":"string","pattern":"^[a-z][a-z0-9_]{0,49}$"},"label":{"type":"string","minLength":1,"maxLength":100},"description":{"anyOf":[{"type":"string","maxLength":300},{"type":"null"}]},"type":{"type":"string","enum":["text","number","boolean","date","select","multiselect","url"]},"options":{"default":[],"maxItems":100,"type":"array","items":{"type":"object","properties":{"value":{"type":"string","minLength":1,"maxLength":100},"label":{"type":"string","minLength":1,"maxLength":100}},"required":["value","label"]}},"required":{"default":false,"type":"boolean"},"position":{"default":0,"type":"integer","minimum":0,"maximum":9007199254740991}},"required":["key","label","type"]}}}},"responses":{"201":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"createdAt":{"format":"date-time","type":"string"},"createdBy":{"format":"uuid","type":"string"},"description":{"type":"null"},"entityType":{"type":"string"},"id":{"format":"uuid","type":"string"},"key":{"type":"string"},"label":{"type":"string"},"options":{"items":{"properties":{"label":{"type":"string"},"value":{"type":"string"}},"required":["label","value"],"type":"object"},"type":"array"},"organizationId":{"format":"uuid","type":"string"},"position":{"type":"integer"},"required":{"type":"boolean"},"type":{"type":"string"},"updatedAt":{"format":"date-time","type":"string"},"updatedBy":{"format":"uuid","type":"string"}},"required":["createdAt","createdBy","description","entityType","id","key","label","options","organizationId","position","required","type","updatedAt","updatedBy"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/custom-properties/{entity}/{id}":{"delete":{"operationId":"DELETE /v1/custom-properties/{entity}/{id}","summary":"Deletes a custom property and its values.","tags":["customProperties"],"x-feature":"customProperties","x-action":"delete","parameters":[{"name":"entity","in":"path","required":true,"schema":{"type":"string"}},{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"204":{"description":"Done, with no content."},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"patch":{"operationId":"PATCH /v1/custom-properties/{entity}/{id}","summary":"Changes a custom property’s label, options or order.","tags":["customProperties"],"x-feature":"customProperties","x-action":"update","parameters":[{"name":"entity","in":"path","required":true,"schema":{"type":"string"}},{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"label":{"type":"string","minLength":1,"maxLength":100},"description":{"anyOf":[{"type":"string","maxLength":300},{"type":"null"}]},"options":{"default":[],"maxItems":100,"type":"array","items":{"type":"object","properties":{"value":{"type":"string","minLength":1,"maxLength":100},"label":{"type":"string","minLength":1,"maxLength":100}},"required":["value","label"]}},"required":{"default":false,"type":"boolean"},"position":{"default":0,"type":"integer","minimum":0,"maximum":9007199254740991}}}}}},"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/dashboard":{"get":{"operationId":"GET /v1/dashboard","summary":"The main dashboard for a period: totals, proposals by status, acceptance rate and a daily series.","tags":["dashboard"],"x-feature":"dashboard","x-action":"read","parameters":[{"name":"days","in":"query","required":false,"schema":{"default":30,"type":"integer","minimum":7,"maximum":90}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"approvals":{"properties":{"approved":{"type":"integer"},"waiting":{"type":"integer"}},"required":["approved","waiting"],"type":"object"},"calendar":{"properties":{"completed":{"type":"integer"},"completedPrevious":{"type":"integer"},"requests":{"type":"integer"},"today":{"type":"integer"},"upcoming":{"items":{"properties":{"contactName":{"type":"null"},"id":{"format":"uuid","type":"string"},"startsAt":{"format":"date-time","type":"string"},"status":{"type":"string"},"title":{"type":"string"}},"required":["id","title","startsAt","status","contactName"],"type":"object"},"type":"array"}},"required":["completed","completedPrevious","requests","today","upcoming"],"type":"object"},"deals":{"properties":{"acceptanceRate":{"type":["integer","null"]},"acceptedAmount":{"type":"integer"},"byStatus":{"properties":{"accepted":{"properties":{"amount":{"type":"integer"},"count":{"type":"integer"}},"required":["count","amount"],"type":"object"}},"required":[],"type":"object"},"openAmount":{"type":"integer"},"openCount":{"type":"integer"}},"required":["acceptanceRate","acceptedAmount","byStatus","openAmount","openCount"],"type":"object"},"emails":{"properties":{"opened":{"properties":{"current":{"type":"integer"},"previous":{"type":"integer"}},"required":["current","previous"],"type":"object"},"sent":{"properties":{"current":{"type":"integer"},"previous":{"type":"integer"}},"required":["current","previous"],"type":"object"}},"required":["opened","sent"],"type":"object"},"forms":{"properties":{"previous":{"type":"integer"},"submissions":{"type":"integer"}},"required":["previous","submissions"],"type":"object"},"invoices":{"properties":{"openAmount":{"type":"integer"},"openCount":{"type":"integer"},"overdueAmount":{"type":"integer"},"overdueCount":{"type":"integer"},"paidAmount":{"type":"integer"},"paidPrevious":{"type":"integer"}},"required":["openAmount","openCount","overdueAmount","overdueCount","paidAmount","paidPrevious"],"type":"object"},"messages":{"properties":{"unread":{"type":"integer"}},"required":["unread"],"type":"object"},"received":{"properties":{"current":{"type":"integer"},"previous":{"type":"integer"}},"required":["current","previous"],"type":"object"},"recent":{"items":{"properties":{"contactName":{"type":["null","string"]},"createdAt":{"format":"date-time","type":"string"},"dealId":{"format":"uuid","type":"string"},"dealTitle":{"type":"string"},"id":{"format":"uuid","type":"string"},"type":{"type":"string"}},"required":["id","type","createdAt","dealId","dealTitle","contactName"],"type":"object"},"type":"array"},"series":{"items":{"properties":{"accepted":{"type":"integer"},"acceptedAmount":{"type":"integer"},"date":{"format":"date","type":"string"},"sent":{"type":"integer"},"viewed":{"type":"integer"}},"required":["accepted","acceptedAmount","date","sent","viewed"],"type":"object"},"type":"array"},"surveys":{"properties":{"nps":{"properties":{"detractors":{"type":"integer"},"passives":{"type":"integer"},"promoters":{"type":"integer"},"score":{"type":["integer","null"]}},"required":["detractors","passives","promoters","score"],"type":"object"},"previous":{"type":"integer"},"responses":{"type":"integer"}},"required":["nps","previous","responses"],"type":"object"},"tasks":{"properties":{"mine":{"type":"integer"},"open":{"type":"integer"},"overdue":{"type":"integer"}},"required":["mine","open","overdue"],"type":"object"},"totals":{"properties":{"companies":{"type":"integer"},"contacts":{"type":"integer"},"deals":{"type":"integer"}},"required":["companies","contacts","deals"],"type":"object"},"traffic":{"properties":{"clicks":{"properties":{"current":{"type":"integer"},"previous":{"type":"integer"}},"required":["current","previous"],"type":"object"},"views":{"properties":{"current":{"type":"integer"},"previous":{"type":"integer"}},"required":["current","previous"],"type":"object"}},"required":["clicks","views"],"type":"object"}},"required":["approvals","calendar","deals","emails","forms","invoices","messages","received","recent","series","surveys","tasks","totals","traffic"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/dashboard/{section}":{"get":{"operationId":"GET /v1/dashboard/{section}","summary":"One dashboard’s numbers for a period: sales, marketing, calendar or messages.","tags":["dashboard"],"x-feature":"dashboard","x-action":"read","parameters":[{"name":"section","in":"path","required":true,"schema":{"type":"string"}},{"name":"days","in":"query","required":false,"schema":{"default":30,"type":"integer","minimum":7,"maximum":90}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"acceptedAmount":{"type":"integer"},"acceptedPrevious":{"type":"integer"},"activities":{"properties":{"averageInbound":{"type":["integer","null"]},"averageMessages":{"type":["integer","null"]},"averageOutbound":{"type":["integer","null"]},"averageSeconds":{"type":["null","number"]},"current":{"type":"integer"},"previous":{"type":"integer"},"previousAverageMessages":{"type":"null"}},"required":["current","previous","averageMessages","previousAverageMessages","averageInbound","averageOutbound","averageSeconds"],"type":"object"},"aging":{"properties":{"current":{"properties":{"amount":{"type":"integer"},"count":{"type":"integer"}},"required":["count","amount"],"type":"object"},"late30":{"properties":{"amount":{"type":"integer"},"count":{"type":"integer"}},"required":["count","amount"],"type":"object"},"late60":{"properties":{"amount":{"type":"integer"},"count":{"type":"integer"}},"required":["count","amount"],"type":"object"},"late90":{"properties":{"amount":{"type":"integer"},"count":{"type":"integer"}},"required":["count","amount"],"type":"object"}},"required":["current","late30","late60","late90"],"type":"object"},"approvals":{"properties":{},"required":[],"type":"object"},"booked":{"properties":{"current":{"type":"integer"},"previous":{"type":"integer"}},"required":["current","previous"],"type":"object"},"byChannel":{"items":{"properties":{"activities":{"type":"integer"},"channel":{"type":"string"},"chats":{"type":"integer"},"responseSeconds":{"type":["integer","null"]}},"required":["channel","chats","activities","responseSeconds"],"type":"object"},"type":"array"},"byPage":{"items":{"properties":{"count":{"type":"integer"},"id":{"type":"null"},"title":{"type":"null"}},"required":["id","title","count"],"type":"object"},"type":"array"},"byStatus":{"properties":{"scheduled":{"type":"integer"}},"required":["scheduled"],"type":"object"},"cancelRate":{"type":"integer"},"catalogRequests":{"properties":{"amount":{"type":"integer"},"current":{"type":"integer"},"previous":{"type":"integer"},"withDeal":{"type":"integer"}},"required":["current","previous","amount","withDeal"],"type":"object"},"chats":{"properties":{"current":{"type":"integer"},"previous":{"type":"integer"}},"required":["current","previous"],"type":"object"},"contactChannels":{"properties":{"forms":{"type":"integer"},"manual":{"type":"integer"}},"required":[],"type":"object"},"contacts":{"properties":{"current":{"type":"integer"},"previous":{"type":"integer"}},"required":["current","previous"],"type":"object"},"daysToAccept":{"type":"null"},"emails":{"properties":{"bounced":{"type":"integer"},"campaigns":{"type":"array"},"clicked":{"properties":{"current":{"type":"integer"},"previous":{"type":"integer"}},"required":["current","previous"],"type":"object"},"opened":{"properties":{"current":{"type":"integer"},"previous":{"type":"integer"}},"required":["current","previous"],"type":"object"},"sent":{"properties":{"current":{"type":"integer"},"previous":{"type":"integer"}},"required":["current","previous"],"type":"object"},"unsubscribed":{"type":"integer"}},"required":["sent","opened","clicked","bounced","unsubscribed","campaigns"],"type":"object"},"funnel":{"properties":{"accepted":{"type":"integer"},"declined":{"type":"integer"},"sent":{"type":"integer"},"viewed":{"type":"integer"}},"required":["sent","viewed","accepted","declined"],"type":"object"},"hours":{"items":{"type":"integer"},"type":"array"},"invitations":{"properties":{"answered":{"type":"integer"},"invited":{"type":"integer"}},"required":["invited","answered"],"type":"object"},"meetings":{"properties":{"current":{"type":"integer"},"previous":{"type":"integer"}},"required":["current","previous"],"type":"object"},"messages":{"properties":{"inbound":{"type":"integer"},"outbound":{"type":"integer"}},"required":["inbound","outbound"],"type":"object"},"newContacts":{"type":"integer"},"noShowRate":{"type":"null"},"nps":{"properties":{"detractors":{"type":"integer"},"passives":{"type":"integer"},"promoters":{"type":"integer"},"score":{"type":["integer","null"]}},"required":["score","promoters","passives","detractors"],"type":"object"},"npsPrevious":{"type":"null"},"paidAmount":{"type":"integer"},"paidByChannel":{"properties":{"invoice":{"type":"integer"},"manual":{"type":"integer"}},"required":["invoice","manual"],"type":"object"},"paidPrevious":{"type":"integer"},"pendingRequests":{"type":"integer"},"response":{"properties":{"answered":{"type":"integer"},"averageSeconds":{"type":["integer","null"]},"medianSeconds":{"type":["integer","null"]},"previousAverageSeconds":{"type":"null"},"turns":{"type":"integer"},"within":{"properties":{"h1":{"type":"integer"},"h24":{"type":"integer"},"m5":{"type":"integer"}},"required":["m5","h1","h24"],"type":"object"}},"required":["turns","answered","averageSeconds","medianSeconds","previousAverageSeconds","within"],"type":"object"},"responses":{"properties":{"current":{"type":"integer"},"previous":{"type":"integer"}},"required":["current","previous"],"type":"object"},"series":{"items":{"properties":{"accepted":{"type":"integer"},"acceptedAmount":{"type":"integer"},"canceled":{"type":"integer"},"contacts":{"type":"integer"},"date":{"format":"date","type":"string"},"held":{"type":"integer"},"inbound":{"type":"integer"},"noShow":{"type":"integer"},"outbound":{"type":"integer"},"paidAmount":{"type":"integer"},"responses":{"type":"integer"},"sent":{"type":"integer"},"submissions":{"type":"integer"}},"required":["date"],"type":"object"},"type":"array"},"sources":{"properties":{"page":{"type":"integer"}},"required":[],"type":"object"},"submissions":{"properties":{"current":{"type":"integer"},"previous":{"type":"integer"},"withContact":{"type":"integer"}},"required":["current","previous","withContact"],"type":"object"},"team":{"items":{"properties":{"answered":{"type":"integer"},"averageSeconds":{"type":"integer"},"name":{"type":["null","string"]},"userId":{"format":"uuid","type":["null","string"]}},"required":["userId","name","answered","averageSeconds"],"type":"object"},"type":"array"},"topForms":{"items":{"properties":{"count":{"type":"integer"},"id":{"format":"uuid","type":"string"},"name":{"type":"string"}},"required":["id","name","count"],"type":"object"},"type":"array"},"topOpen":{"type":"array"},"topSurveys":{"items":{"properties":{"answered":{"type":"integer"},"id":{"format":"uuid","type":"string"},"invited":{"type":"integer"},"name":{"type":"string"},"responses":{"type":"integer"}},"required":["id","name","responses","invited","answered"],"type":"object"},"type":"array"},"traffic":{"properties":{"byKind":{"properties":{"catalog":{"type":"integer"},"files":{"type":"integer"},"links":{"type":"integer"},"microsite":{"type":"integer"},"shortLinks":{"type":"integer"}},"required":["links","microsite","shortLinks","files","catalog"],"type":"object"},"clicks":{"properties":{"current":{"type":"integer"},"previous":{"type":"integer"}},"required":["current","previous"],"type":"object"},"downloads":{"properties":{"current":{"type":"integer"},"previous":{"type":"integer"}},"required":["current","previous"],"type":"object"},"series":{"items":{"properties":{"clicks":{"type":"integer"},"date":{"format":"date","type":"string"},"downloads":{"type":"integer"},"views":{"type":"integer"}},"required":["date","views","clicks","downloads"],"type":"object"},"type":"array"},"top":{"items":{"properties":{"count":{"type":"integer"},"id":{"format":"uuid","type":"string"},"name":{"type":"string"},"what":{"type":"string"}},"required":["what","id","name","count"],"type":"object"},"type":"array"},"views":{"properties":{"current":{"type":"integer"},"previous":{"type":"integer"}},"required":["current","previous"],"type":"object"}},"required":["series","views","clicks","downloads","byKind","top"],"type":"object"},"upcoming":{"items":{"properties":{"contactName":{"type":"null"},"id":{"format":"uuid","type":"string"},"startsAt":{"format":"date-time","type":"string"},"status":{"type":"string"},"title":{"type":"string"}},"required":["id","title","startsAt","status","contactName"],"type":"object"},"type":"array"},"waiting":{"properties":{"count":{"type":"integer"},"oldest":{"format":"date-time","type":["null","string"]}},"required":["count","oldest"],"type":"object"},"weekdays":{"items":{"type":"integer"},"type":"array"}},"required":["series"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/deal-defaults":{"get":{"operationId":"GET /v1/deal-defaults","summary":"What new proposals start with: validity, texts, settings.","tags":["deals"],"x-feature":"deals","x-action":"read","responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"acceptPayments":{"type":"boolean"},"currency":{"type":"string"},"depositPercent":{"type":["integer","null"]},"nextReference":{"type":["null","string"]},"notifications":{"properties":{"accepted":{"type":"boolean"},"declined":{"type":"boolean"},"question":{"type":"boolean"},"viewed":{"type":"boolean"}},"required":["viewed","accepted","declined","question"],"type":"object"},"paymentDueDays":{"type":"null"},"paymentTerms":{"type":"string"},"reference":{"properties":{"auto":{"type":"boolean"},"digits":{"type":"integer"},"next":{"type":"integer"},"prefix":{"type":"string"}},"required":["auto","prefix","digits","next"],"type":"object"},"terms":{"type":["null","string"]},"validityDays":{"type":"integer"},"verifySignerEmail":{"type":"boolean"}},"required":["currency","validityDays","depositPercent","terms","notifications","reference","verifySignerEmail","acceptPayments","paymentTerms","paymentDueDays","nextReference"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"put":{"operationId":"PUT /v1/deal-defaults","summary":"Changes what new proposals start with.","tags":["deals"],"x-feature":"deals","x-action":"update","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"currency":{"type":"string","pattern":"^[A-Z]{3}$"},"validityDays":{"type":"integer","minimum":1,"maximum":365},"depositPercent":{"anyOf":[{"type":"integer","minimum":0,"maximum":100},{"type":"null"}]},"terms":{"anyOf":[{"type":"string","maxLength":50000},{"type":"null"}]},"notifications":{"type":"object","properties":{"viewed":{"type":"boolean"},"accepted":{"type":"boolean"},"declined":{"type":"boolean"},"question":{"type":"boolean"}},"required":["viewed","accepted","declined","question"]},"verifySignerEmail":{"default":false,"type":"boolean"},"acceptPayments":{"default":false,"type":"boolean"},"paymentTerms":{"default":"on_acceptance","type":"string","enum":["on_acceptance","days_after"]},"paymentDueDays":{"default":null,"anyOf":[{"type":"integer","minimum":1,"maximum":365},{"type":"null"}]},"reference":{"type":"object","properties":{"auto":{"type":"boolean"},"prefix":{"type":"string","maxLength":20},"digits":{"type":"integer","minimum":1,"maximum":8},"next":{"type":"integer","minimum":1,"maximum":999999999}},"required":["auto","prefix","digits","next"]}},"required":["currency","validityDays","depositPercent","terms","notifications","reference"]}}}},"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"acceptPayments":{"type":"boolean"},"currency":{"type":"string"},"depositPercent":{"type":"integer"},"nextReference":{"type":"string"},"notifications":{"properties":{"accepted":{"type":"boolean"},"declined":{"type":"boolean"},"question":{"type":"boolean"},"viewed":{"type":"boolean"}},"required":["viewed","accepted","declined","question"],"type":"object"},"paymentDueDays":{"type":"null"},"paymentTerms":{"type":"string"},"reference":{"properties":{"auto":{"type":"boolean"},"digits":{"type":"integer"},"next":{"type":"integer"},"prefix":{"type":"string"}},"required":["auto","prefix","digits","next"],"type":"object"},"terms":{"type":"string"},"validityDays":{"type":"integer"},"verifySignerEmail":{"type":"boolean"}},"required":["currency","validityDays","depositPercent","terms","notifications","reference","verifySignerEmail","acceptPayments","paymentTerms","paymentDueDays","nextReference"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/deal-templates":{"get":{"operationId":"GET /v1/deal-templates","summary":"Lists the proposal templates to start a proposal from.","tags":["deals"],"x-feature":"deals","x-action":"read","responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"items":{"properties":{"description":{"type":"string"},"id":{"type":"string"},"name":{"type":"string"},"theme":{"properties":{"accentColor":{"type":"string"},"backgroundColor":{"type":"string"},"bodyFont":{"type":"string"},"cornerRadius":{"type":"string"},"headingFont":{"type":"string"},"primaryColor":{"type":"string"},"textColor":{"type":"string"}},"required":["primaryColor","accentColor","backgroundColor","textColor","headingFont","bodyFont","cornerRadius"],"type":"object"}},"required":["id","name","description","theme"],"type":"object"},"type":"array"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/deals":{"get":{"operationId":"GET /v1/deals","summary":"Lists and searches proposals, by status, owner, contact or date.","tags":["deals"],"x-feature":"deals","x-action":"read","parameters":[{"name":"page","in":"query","required":false,"schema":{"default":1,"type":"integer","minimum":1,"maximum":9007199254740991}},{"name":"pageSize","in":"query","required":false,"schema":{"default":25,"type":"integer","minimum":1,"maximum":100}},{"name":"q","in":"query","required":false,"schema":{"type":"string","minLength":1,"maxLength":200}},{"name":"archived","in":"query","required":false,"schema":{"type":"string"}},{"name":"status","in":"query","required":false,"schema":{"maxItems":8,"type":"array","items":{"type":"string","enum":["draft","sent","viewed","negotiating","accepted","declined","expired","paid"]}}},{"name":"companyId","in":"query","required":false,"schema":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"}},{"name":"ownerId","in":"query","required":false,"schema":{"type":"string"}},{"name":"contactId","in":"query","required":false,"schema":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"}},{"name":"dueFrom","in":"query","required":false,"schema":{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"}},{"name":"dueBefore","in":"query","required":false,"schema":{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"}},{"name":"sort","in":"query","required":false,"schema":{"default":"createdAt","type":"string","enum":["createdAt","updatedAt","title","totalAmount","validUntil","viewCount"]}},{"name":"order","in":"query","required":false,"schema":{"default":"desc","type":"string","enum":["asc","desc"]}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"data":{"items":{"properties":{"acceptedAt":{"format":"date-time","type":["null","string"]},"archived":{"type":"boolean"},"companyId":{"format":"uuid","type":["null","string"]},"companyName":{"type":["null","string"]},"createdAt":{"format":"date-time","type":"string"},"currency":{"type":"string"},"hasUnpublishedChanges":{"type":"boolean"},"id":{"format":"uuid","type":"string"},"lastViewedAt":{"format":"date-time","type":["null","string"]},"ownerId":{"format":"uuid","type":"string"},"ownerImage":{"type":"null"},"ownerName":{"type":"string"},"paidAt":{"format":"date-time","type":["null","string"]},"reference":{"type":["null","string"]},"sentAt":{"format":"date-time","type":["null","string"]},"status":{"type":"string"},"title":{"type":"string"},"totalAmount":{"type":"integer"},"updatedAt":{"format":"date-time","type":"string"},"validUntil":{"format":"date-time","type":"string"},"viewCount":{"type":"integer"}},"required":["acceptedAt","archived","companyId","companyName","createdAt","currency","hasUnpublishedChanges","id","lastViewedAt","ownerId","ownerImage","ownerName","paidAt","reference","sentAt","status","title","totalAmount","updatedAt","validUntil","viewCount"],"type":"object"},"type":"array"},"page":{"type":"integer"},"pageSize":{"type":"integer"},"total":{"type":"integer"}},"required":["data","page","pageSize","total"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"post":{"operationId":"POST /v1/deals","summary":"Creates a proposal draft.","tags":["deals"],"x-feature":"deals","x-action":"create","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"title":{"anyOf":[{"type":"string","maxLength":200},{"type":"null"}]},"reference":{"anyOf":[{"type":"string","maxLength":60},{"type":"null"}]},"companyId":{"anyOf":[{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},{"type":"null"}]},"primaryContactId":{"anyOf":[{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},{"type":"null"}]},"ownerId":{"type":"string","minLength":1},"currency":{"type":"string","pattern":"^[A-Z]{3}$"},"validUntil":{"type":"string","minLength":1},"depositPercent":{"anyOf":[{"type":"integer","minimum":0,"maximum":100},{"type":"null"}]},"language":{"anyOf":[{"type":"string","enum":["pt","es","en","fr"]},{"type":"null"}]},"content":{"default":{},"type":"object","properties":{"summary":{"anyOf":[{"type":"string","maxLength":20000},{"type":"null"}]},"scope":{"anyOf":[{"type":"string","maxLength":50000},{"type":"null"}]},"terms":{"anyOf":[{"type":"string","maxLength":50000},{"type":"null"}]},"packages":{"maxItems":3,"type":"array","items":{"type":"object","properties":{"id":{"type":"string","minLength":1,"maxLength":64},"name":{"type":"string","minLength":1,"maxLength":100},"description":{"anyOf":[{"type":"string","maxLength":2000},{"type":"null"}]},"recommended":{"default":false,"type":"boolean"},"items":{"maxItems":50,"type":"array","items":{"type":"object","properties":{"id":{"type":"string","minLength":1,"maxLength":64},"serviceId":{"anyOf":[{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},{"type":"null"}]},"name":{"type":"string","minLength":1,"maxLength":200},"description":{"anyOf":[{"type":"string","maxLength":2000},{"type":"null"}]},"quantity":{"default":1,"type":"number","exclusiveMinimum":0,"maximum":100000},"unitPrice":{"type":"integer","minimum":0,"maximum":10000000000000},"optional":{"default":false,"type":"boolean"}},"required":["name","unitPrice"]}},"discount":{"anyOf":[{"oneOf":[{"type":"object","properties":{"type":{"type":"string","const":"percent"},"value":{"type":"number","exclusiveMinimum":0,"maximum":100,"multipleOf":0.01}},"required":["type","value"]},{"type":"object","properties":{"type":{"type":"string","const":"amount"},"value":{"type":"integer","exclusiveMinimum":0,"maximum":10000000000000}},"required":["type","value"]}]},{"type":"null"}]}},"required":["name"]}},"items":{"maxItems":100,"type":"array","items":{"type":"object","properties":{"id":{"type":"string","minLength":1,"maxLength":64},"serviceId":{"anyOf":[{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},{"type":"null"}]},"name":{"type":"string","minLength":1,"maxLength":200},"description":{"anyOf":[{"type":"string","maxLength":2000},{"type":"null"}]},"quantity":{"default":1,"type":"number","exclusiveMinimum":0,"maximum":100000},"unitPrice":{"type":"integer","minimum":0,"maximum":10000000000000},"optional":{"default":false,"type":"boolean"}},"required":["name","unitPrice"]}}}},"notifications":{"type":"object","properties":{"viewed":{"type":"boolean"},"accepted":{"type":"boolean"},"declined":{"type":"boolean"},"question":{"type":"boolean"}}},"verifySignerEmail":{"type":"boolean"},"acceptPayments":{"type":"boolean"},"paymentTerms":{"type":"string","enum":["on_acceptance","on_date","days_after"]},"paymentDueDate":{"anyOf":[{"type":"string","format":"date","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))$"},{"type":"null"}]},"paymentDueDays":{"anyOf":[{"type":"integer","minimum":1,"maximum":365},{"type":"null"}]},"customProperties":{"type":"object","propertyNames":{"type":"string"},"additionalProperties":{}},"archived":{"type":"boolean"}}}}}},"responses":{"201":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"acceptPayments":{"type":"boolean"},"acceptance":{"type":"null"},"acceptedAt":{"type":"null"},"archived":{"type":"boolean"},"catalogRequestId":{"type":"null"},"clientSelection":{"type":"null"},"company":{"properties":{"id":{"format":"uuid","type":"string"},"name":{"type":"string"}},"required":["id","name"],"type":["null","object"]},"companyId":{"format":"uuid","type":["null","string"]},"content":{"properties":{"items":{"items":{"properties":{"description":{"type":"null"},"id":{"format":"uuid","type":"string"},"name":{"type":"string"},"optional":{"type":"boolean"},"quantity":{"type":"integer"},"serviceId":{"format":"uuid","type":["null","string"]},"unitPrice":{"type":"integer"}},"required":["description","id","name","optional","quantity","serviceId","unitPrice"],"type":"object"},"type":"array"},"packages":{"items":{"properties":{"description":{"type":"null"},"discount":{"properties":{"type":{"type":"string"},"value":{"type":"integer"}},"required":["type","value"],"type":["null","object"]},"id":{"format":"uuid","type":"string"},"items":{"items":{"properties":{"description":{"type":"null"},"id":{"format":"uuid","type":"string"},"name":{"type":"string"},"optional":{"type":"boolean"},"quantity":{"type":"integer"},"serviceId":{"type":"null"},"unitPrice":{"type":"integer"}},"required":["description","id","name","optional","quantity","serviceId","unitPrice"],"type":"object"},"type":"array"},"name":{"type":"string"},"recommended":{"type":"boolean"}},"required":["description","discount","id","items","name","recommended"],"type":"object"},"type":"array"},"scope":{"type":"null"},"summary":{"type":["null","string"]},"terms":{"type":["null","string"]}},"required":["items","packages","scope","summary","terms"],"type":"object"},"createdAt":{"format":"date-time","type":"string"},"createdBy":{"format":"uuid","type":["null","string"]},"currency":{"type":"string"},"currentVersion":{"type":"integer"},"customProperties":{"additionalProperties":{},"type":"object"},"declineComment":{"type":"null"},"declineReason":{"type":"null"},"declinedAt":{"type":"null"},"depositPercent":{"type":["integer","null"]},"firstViewedAt":{"type":"null"},"hasUnpublishedChanges":{"type":"boolean"},"id":{"format":"uuid","type":"string"},"invoice":{"type":"null"},"invoiceId":{"type":"null"},"language":{"type":["null","string"]},"lastViewedAt":{"type":"null"},"locked":{"type":"boolean"},"notifications":{"properties":{"accepted":{"type":"boolean"},"declined":{"type":"boolean"},"question":{"type":"boolean"},"viewed":{"type":"boolean"}},"required":["accepted","declined","question","viewed"],"type":"object"},"organizationId":{"format":"uuid","type":"string"},"owner":{"properties":{"image":{"type":"null"},"memberId":{"format":"uuid","type":"string"},"name":{"type":"string"},"userId":{"format":"uuid","type":"string"}},"required":["image","memberId","name","userId"],"type":"object"},"ownerId":{"format":"uuid","type":"string"},"paidAt":{"type":"null"},"payment":{"type":"null"},"paymentDueDate":{"type":"null"},"paymentDueDays":{"type":["integer","null"]},"paymentTerms":{"type":"string"},"primaryContactId":{"format":"uuid","type":["null","string"]},"publicId":{"type":"string"},"reference":{"type":["null","string"]},"reminderSentAt":{"type":"null"},"sentAt":{"type":"null"},"share":{"properties":{"channels":{"items":{"properties":{"available":{"type":"boolean"},"id":{"type":"string"}},"required":["available","id"],"type":"object"},"type":"array"},"recipients":{"type":"array"},"url":{"type":"null"}},"required":["channels","recipients","url"],"type":"object"},"signatureVerification":{"type":"null"},"status":{"type":"string"},"title":{"type":["null","string"]},"totalAmount":{"type":"integer"},"updatedAt":{"format":"date-time","type":"string"},"updatedBy":{"format":"uuid","type":["null","string"]},"validUntil":{"format":"date-time","type":"string"},"verifySignerEmail":{"type":"boolean"},"viewCount":{"type":"integer"}},"required":["acceptPayments","acceptance","acceptedAt","archived","catalogRequestId","clientSelection","company","companyId","content","createdAt","createdBy","currency","currentVersion","customProperties","declineComment","declineReason","declinedAt","depositPercent","firstViewedAt","hasUnpublishedChanges","id","invoice","invoiceId","language","lastViewedAt","locked","notifications","organizationId","owner","ownerId","paidAt","payment","paymentDueDate","paymentDueDays","paymentTerms","primaryContactId","publicId","reference","reminderSentAt","sentAt","share","signatureVerification","status","title","totalAmount","updatedAt","updatedBy","validUntil","verifySignerEmail","viewCount"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/deals/{id}":{"delete":{"operationId":"DELETE /v1/deals/{id}","summary":"Deletes a proposal.","tags":["deals"],"x-feature":"deals","x-action":"delete","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"204":{"description":"Done, with no content."},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"get":{"operationId":"GET /v1/deals/{id}","summary":"Returns a proposal with its content, packages, recipients and status.","tags":["deals"],"x-feature":"deals","x-action":"read","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"acceptPayments":{"type":"boolean"},"acceptance":{"properties":{"acceptedAt":{"format":"date-time","type":"string"},"chosen":{"properties":{"addOns":{"items":{"properties":{"id":{"format":"uuid","type":"string"},"name":{"type":"string"},"total":{"type":"integer"}},"required":["id","name","total"],"type":"object"},"type":"array"},"included":{"items":{"properties":{"id":{"format":"uuid","type":"string"},"name":{"type":"string"},"total":{"type":"integer"}},"required":["id","name","total"],"type":"object"},"type":"array"},"package":{"properties":{"id":{"format":"uuid","type":"string"},"items":{"items":{"properties":{"id":{"format":"uuid","type":"string"},"name":{"type":"string"},"quantity":{"type":"integer"},"total":{"type":"integer"}},"required":["id","name","quantity","total"],"type":"object"},"type":"array"},"name":{"type":"string"},"total":{"type":"integer"}},"required":["id","items","name","total"],"type":"object"}},"required":["addOns","included","package"],"type":"object"},"dealId":{"format":"uuid","type":"string"},"depositAmount":{"type":["integer","null"]},"id":{"format":"uuid","type":"string"},"ipAddress":{"type":"string"},"organizationId":{"format":"uuid","type":"string"},"recipientId":{"format":"uuid","type":["null","string"]},"selection":{"properties":{"optionalItemIds":{"items":{"format":"uuid","type":"string"},"type":"array"},"packageId":{"format":"uuid","type":"string"}},"required":["optionalItemIds","packageId"],"type":"object"},"signerEmail":{"format":"email","type":["null","string"]},"signerName":{"type":"string"},"signerTaxId":{"type":"string"},"totalAmount":{"type":"integer"},"userAgent":{"type":["null","string"]},"version":{"type":"integer"},"versionHash":{"type":"string"},"versionId":{"format":"uuid","type":"string"}},"required":["acceptedAt","chosen","dealId","depositAmount","id","ipAddress","organizationId","recipientId","selection","signerEmail","signerName","signerTaxId","totalAmount","userAgent","version","versionHash","versionId"],"type":["null","object"]},"acceptedAt":{"format":"date-time","type":["null","string"]},"archived":{"type":"boolean"},"catalogRequestId":{"type":"null"},"clientSelection":{"properties":{"optionalItemIds":{"items":{"format":"uuid","type":"string"},"type":"array"},"packageId":{"format":"uuid","type":"string"}},"required":["optionalItemIds","packageId"],"type":["null","object"]},"company":{"properties":{"id":{"format":"uuid","type":"string"},"name":{"type":"string"}},"required":["id","name"],"type":["null","object"]},"companyId":{"format":"uuid","type":["null","string"]},"content":{"properties":{"items":{"items":{"properties":{"description":{"type":"null"},"id":{"format":"uuid","type":"string"},"name":{"type":"string"},"optional":{"type":"boolean"},"quantity":{"type":"integer"},"serviceId":{"type":"null"},"unitPrice":{"type":"integer"}},"required":["description","id","name","optional","quantity","serviceId","unitPrice"],"type":"object"},"type":"array"},"packages":{"items":{"properties":{"description":{"type":"null"},"discount":{"properties":{"type":{"type":"string"},"value":{"type":"integer"}},"required":["type","value"],"type":["null","object"]},"id":{"format":"uuid","type":"string"},"items":{"items":{"properties":{"description":{"type":"null"},"id":{"format":"uuid","type":"string"},"name":{"type":"string"},"optional":{"type":"boolean"},"quantity":{"type":"integer"},"serviceId":{"type":"null"},"unitPrice":{"type":"integer"}},"required":["description","id","name","optional","quantity","serviceId","unitPrice"],"type":"object"},"type":"array"},"name":{"type":"string"},"recommended":{"type":"boolean"}},"required":["description","discount","id","items","name","recommended"],"type":"object"},"type":"array"},"scope":{"type":"null"},"summary":{"type":["null","string"]},"terms":{"type":["null","string"]}},"required":["items","packages","scope","summary","terms"],"type":"object"},"createdAt":{"format":"date-time","type":"string"},"createdBy":{"format":"uuid","type":"string"},"currency":{"type":"string"},"currentVersion":{"type":"integer"},"customProperties":{"additionalProperties":{},"type":"object"},"declineComment":{"type":["null","string"]},"declineReason":{"type":["null","string"]},"declinedAt":{"format":"date-time","type":["null","string"]},"depositPercent":{"type":["integer","null"]},"firstViewedAt":{"format":"date-time","type":["null","string"]},"hasUnpublishedChanges":{"type":"boolean"},"id":{"format":"uuid","type":"string"},"invoice":{"properties":{"currency":{"type":"string"},"dueDate":{"format":"date","type":"string"},"id":{"format":"uuid","type":"string"},"number":{"type":"string"},"paidAt":{"format":"date-time","type":["null","string"]},"status":{"type":"string"},"total":{"type":"integer"}},"required":["id","number","status","total","currency","dueDate","paidAt"],"type":["null","object"]},"invoiceId":{"format":"uuid","type":["null","string"]},"language":{"type":"null"},"lastViewedAt":{"format":"date-time","type":["null","string"]},"locked":{"type":"boolean"},"notifications":{"properties":{"accepted":{"type":"boolean"},"declined":{"type":"boolean"},"question":{"type":"boolean"},"viewed":{"type":"boolean"}},"required":["accepted","declined","question","viewed"],"type":"object"},"organizationId":{"format":"uuid","type":"string"},"owner":{"properties":{"image":{"type":"null"},"memberId":{"format":"uuid","type":"string"},"name":{"type":"string"},"userId":{"format":"uuid","type":"string"}},"required":["image","memberId","name","userId"],"type":"object"},"ownerId":{"format":"uuid","type":"string"},"paidAt":{"format":"date-time","type":["null","string"]},"payment":{"properties":{"amount":{"type":"integer"},"applicationFee":{"type":"integer"},"createdAt":{"format":"date-time","type":"string"},"currency":{"type":"string"},"id":{"format":"uuid","type":"string"},"paidAt":{"format":"date-time","type":"string"},"payerEmail":{"format":"email","type":"string"},"payerName":{"type":"string"},"status":{"type":"string"}},"required":["id","status","amount","currency","applicationFee","payerName","payerEmail","paidAt","createdAt"],"type":["null","object"]},"paymentDueDate":{"type":"null"},"paymentDueDays":{"type":"null"},"paymentTerms":{"type":"string"},"primaryContactId":{"format":"uuid","type":["null","string"]},"publicId":{"type":"string"},"reference":{"type":"null"},"reminderSentAt":{"type":"null"},"sentAt":{"format":"date-time","type":["null","string"]},"share":{"properties":{"channels":{"items":{"properties":{"available":{"type":"boolean"},"id":{"type":"string"}},"required":["available","id"],"type":"object"},"type":"array"},"recipients":{"items":{"properties":{"channel":{"type":"string"},"contactId":{"format":"uuid","type":"string"},"createdAt":{"format":"date-time","type":"string"},"firstName":{"type":"string"},"firstViewedAt":{"format":"date-time","type":["null","string"]},"id":{"format":"uuid","type":"string"},"lastName":{"type":"null"},"lastViewedAt":{"format":"date-time","type":["null","string"]},"mergedContactId":{"type":"null"},"token":{"type":"string"},"url":{"format":"uri","type":"string"},"viewCount":{"type":"integer"}},"required":["id","contactId","firstName","lastName","channel","token","viewCount","firstViewedAt","lastViewedAt","createdAt","mergedContactId","url"],"type":"object"},"type":"array"},"url":{"format":"uri","type":["null","string"]}},"required":["channels","recipients","url"],"type":"object"},"signatureVerification":{"properties":{"email":{"format":"email","type":"string"},"sendCount":{"type":"integer"},"sentAt":{"format":"date-time","type":"string"},"verifiedAt":{"format":"date-time","type":["null","string"]},"verifiedIp":{"type":["null","string"]},"verifiedUserAgent":{"type":"null"}},"required":["email","sendCount","sentAt","verifiedAt","verifiedIp","verifiedUserAgent"],"type":["null","object"]},"status":{"type":"string"},"title":{"type":"string"},"totalAmount":{"type":"integer"},"updatedAt":{"format":"date-time","type":"string"},"updatedBy":{"format":"uuid","type":"string"},"validUntil":{"format":"date-time","type":"string"},"verifySignerEmail":{"type":"boolean"},"viewCount":{"type":"integer"}},"required":["acceptPayments","acceptance","acceptedAt","archived","catalogRequestId","clientSelection","company","companyId","content","createdAt","createdBy","currency","currentVersion","customProperties","declineComment","declineReason","declinedAt","depositPercent","firstViewedAt","hasUnpublishedChanges","id","invoice","invoiceId","language","lastViewedAt","locked","notifications","organizationId","owner","ownerId","paidAt","payment","paymentDueDate","paymentDueDays","paymentTerms","primaryContactId","publicId","reference","reminderSentAt","sentAt","share","signatureVerification","status","title","totalAmount","updatedAt","updatedBy","validUntil","verifySignerEmail","viewCount"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"patch":{"operationId":"PATCH /v1/deals/{id}","summary":"Changes a proposal draft: content, items, packages, client and settings.","tags":["deals"],"x-feature":"deals","x-action":"update","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"title":{"anyOf":[{"type":"string","maxLength":200},{"type":"null"}]},"reference":{"anyOf":[{"type":"string","maxLength":60},{"type":"null"}]},"companyId":{"anyOf":[{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},{"type":"null"}]},"primaryContactId":{"anyOf":[{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},{"type":"null"}]},"ownerId":{"type":"string","minLength":1},"currency":{"type":"string","pattern":"^[A-Z]{3}$"},"validUntil":{"type":"string","minLength":1},"depositPercent":{"anyOf":[{"type":"integer","minimum":0,"maximum":100},{"type":"null"}]},"language":{"anyOf":[{"type":"string","enum":["pt","es","en","fr"]},{"type":"null"}]},"content":{"type":"object","properties":{"summary":{"anyOf":[{"type":"string","maxLength":20000},{"type":"null"}]},"scope":{"anyOf":[{"type":"string","maxLength":50000},{"type":"null"}]},"terms":{"anyOf":[{"type":"string","maxLength":50000},{"type":"null"}]},"packages":{"maxItems":3,"type":"array","items":{"type":"object","properties":{"id":{"type":"string","minLength":1,"maxLength":64},"name":{"type":"string","minLength":1,"maxLength":100},"description":{"anyOf":[{"type":"string","maxLength":2000},{"type":"null"}]},"recommended":{"default":false,"type":"boolean"},"items":{"maxItems":50,"type":"array","items":{"type":"object","properties":{"id":{"type":"string","minLength":1,"maxLength":64},"serviceId":{"anyOf":[{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},{"type":"null"}]},"name":{"type":"string","minLength":1,"maxLength":200},"description":{"anyOf":[{"type":"string","maxLength":2000},{"type":"null"}]},"quantity":{"default":1,"type":"number","exclusiveMinimum":0,"maximum":100000},"unitPrice":{"type":"integer","minimum":0,"maximum":10000000000000},"optional":{"default":false,"type":"boolean"}},"required":["name","unitPrice"]}},"discount":{"anyOf":[{"oneOf":[{"type":"object","properties":{"type":{"type":"string","const":"percent"},"value":{"type":"number","exclusiveMinimum":0,"maximum":100,"multipleOf":0.01}},"required":["type","value"]},{"type":"object","properties":{"type":{"type":"string","const":"amount"},"value":{"type":"integer","exclusiveMinimum":0,"maximum":10000000000000}},"required":["type","value"]}]},{"type":"null"}]}},"required":["name"]}},"items":{"maxItems":100,"type":"array","items":{"type":"object","properties":{"id":{"type":"string","minLength":1,"maxLength":64},"serviceId":{"anyOf":[{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},{"type":"null"}]},"name":{"type":"string","minLength":1,"maxLength":200},"description":{"anyOf":[{"type":"string","maxLength":2000},{"type":"null"}]},"quantity":{"default":1,"type":"number","exclusiveMinimum":0,"maximum":100000},"unitPrice":{"type":"integer","minimum":0,"maximum":10000000000000},"optional":{"default":false,"type":"boolean"}},"required":["name","unitPrice"]}}}},"notifications":{"type":"object","properties":{"viewed":{"type":"boolean"},"accepted":{"type":"boolean"},"declined":{"type":"boolean"},"question":{"type":"boolean"}}},"verifySignerEmail":{"type":"boolean"},"acceptPayments":{"type":"boolean"},"paymentTerms":{"type":"string","enum":["on_acceptance","on_date","days_after"]},"paymentDueDate":{"anyOf":[{"type":"string","format":"date","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))$"},{"type":"null"}]},"paymentDueDays":{"anyOf":[{"type":"integer","minimum":1,"maximum":365},{"type":"null"}]},"customProperties":{"type":"object","propertyNames":{"type":"string"},"additionalProperties":{}},"archived":{"type":"boolean"}}}}}},"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"acceptPayments":{"type":"boolean"},"acceptance":{"properties":{"acceptedAt":{"format":"date-time","type":"string"},"chosen":{"properties":{"addOns":{"items":{"properties":{"id":{"format":"uuid","type":"string"},"name":{"type":"string"},"total":{"type":"integer"}},"required":["id","name","total"],"type":"object"},"type":"array"},"included":{"items":{"properties":{"id":{"format":"uuid","type":"string"},"name":{"type":"string"},"total":{"type":"integer"}},"required":["id","name","total"],"type":"object"},"type":"array"},"package":{"properties":{"id":{"format":"uuid","type":"string"},"items":{"items":{"properties":{"id":{"format":"uuid","type":"string"},"name":{"type":"string"},"quantity":{"type":"integer"},"total":{"type":"integer"}},"required":["id","name","quantity","total"],"type":"object"},"type":"array"},"name":{"type":"string"},"total":{"type":"integer"}},"required":["id","name","total","items"],"type":"object"}},"required":["package","included","addOns"],"type":"object"},"dealId":{"format":"uuid","type":"string"},"depositAmount":{"type":"integer"},"id":{"format":"uuid","type":"string"},"ipAddress":{"type":"string"},"organizationId":{"format":"uuid","type":"string"},"recipientId":{"format":"uuid","type":"string"},"selection":{"properties":{"optionalItemIds":{"items":{"format":"uuid","type":"string"},"type":"array"},"packageId":{"format":"uuid","type":"string"}},"required":["packageId","optionalItemIds"],"type":"object"},"signerEmail":{"format":"email","type":"string"},"signerName":{"type":"string"},"signerTaxId":{"type":"string"},"totalAmount":{"type":"integer"},"userAgent":{"type":"string"},"version":{"type":"integer"},"versionHash":{"type":"string"},"versionId":{"format":"uuid","type":"string"}},"required":["acceptedAt","chosen","dealId","depositAmount","id","ipAddress","organizationId","recipientId","selection","signerEmail","signerName","signerTaxId","totalAmount","userAgent","version","versionHash","versionId"],"type":["null","object"]},"acceptedAt":{"format":"date-time","type":["null","string"]},"archived":{"type":"boolean"},"catalogRequestId":{"type":"null"},"clientSelection":{"properties":{"optionalItemIds":{"items":{"format":"uuid","type":"string"},"type":"array"},"packageId":{"format":"uuid","type":"string"}},"required":["optionalItemIds","packageId"],"type":["null","object"]},"company":{"properties":{"id":{"format":"uuid","type":"string"},"name":{"type":"string"}},"required":["id","name"],"type":["null","object"]},"companyId":{"format":"uuid","type":["null","string"]},"content":{"properties":{"items":{"items":{"properties":{"description":{"type":"null"},"id":{"format":"uuid","type":"string"},"name":{"type":"string"},"optional":{"type":"boolean"},"quantity":{"type":"integer"},"serviceId":{"type":"null"},"unitPrice":{"type":"integer"}},"required":["description","id","name","optional","quantity","serviceId","unitPrice"],"type":"object"},"type":"array"},"packages":{"items":{"properties":{"description":{"type":"null"},"discount":{"type":"null"},"id":{"format":"uuid","type":"string"},"items":{"items":{"properties":{"description":{"type":"null"},"id":{"format":"uuid","type":"string"},"name":{"type":"string"},"optional":{"type":"boolean"},"quantity":{"type":"integer"},"serviceId":{"type":"null"},"unitPrice":{"type":"integer"}},"required":["id","name","optional","quantity","serviceId","unitPrice","description"],"type":"object"},"type":"array"},"name":{"type":"string"},"recommended":{"type":"boolean"}},"required":["id","name","items","discount","description","recommended"],"type":"object"},"type":"array"},"scope":{"type":"null"},"summary":{"type":["null","string"]},"terms":{"type":["null","string"]}},"required":["items","packages","scope","summary","terms"],"type":"object"},"createdAt":{"format":"date-time","type":"string"},"createdBy":{"format":"uuid","type":"string"},"currency":{"type":"string"},"currentVersion":{"type":"integer"},"customProperties":{"additionalProperties":{},"type":"object"},"declineComment":{"type":"null"},"declineReason":{"type":"null"},"declinedAt":{"type":"null"},"depositPercent":{"type":["integer","null"]},"firstViewedAt":{"format":"date-time","type":["null","string"]},"hasUnpublishedChanges":{"type":"boolean"},"id":{"format":"uuid","type":"string"},"invoice":{"type":"null"},"invoiceId":{"type":"null"},"language":{"type":["null","string"]},"lastViewedAt":{"format":"date-time","type":["null","string"]},"locked":{"type":"boolean"},"notifications":{"properties":{"accepted":{"type":"boolean"},"declined":{"type":"boolean"},"question":{"type":"boolean"},"viewed":{"type":"boolean"}},"required":["accepted","declined","question","viewed"],"type":"object"},"organizationId":{"format":"uuid","type":"string"},"owner":{"properties":{"image":{"type":"null"},"memberId":{"format":"uuid","type":"string"},"name":{"type":"string"},"userId":{"format":"uuid","type":"string"}},"required":["image","memberId","name","userId"],"type":"object"},"ownerId":{"format":"uuid","type":"string"},"paidAt":{"type":"null"},"payment":{"type":"null"},"paymentDueDate":{"type":"null"},"paymentDueDays":{"type":"null"},"paymentTerms":{"type":"string"},"primaryContactId":{"format":"uuid","type":["null","string"]},"publicId":{"type":"string"},"reference":{"type":"null"},"reminderSentAt":{"type":"null"},"sentAt":{"format":"date-time","type":["null","string"]},"share":{"properties":{"channels":{"items":{"properties":{"available":{"type":"boolean"},"id":{"type":"string"}},"required":["available","id"],"type":"object"},"type":"array"},"recipients":{"items":{"properties":{"channel":{"type":"string"},"contactId":{"format":"uuid","type":"string"},"createdAt":{"format":"date-time","type":"string"},"firstName":{"type":"string"},"firstViewedAt":{"format":"date-time","type":"string"},"id":{"format":"uuid","type":"string"},"lastName":{"type":"null"},"lastViewedAt":{"format":"date-time","type":"string"},"mergedContactId":{"type":"null"},"token":{"type":"string"},"url":{"format":"uri","type":"string"},"viewCount":{"type":"integer"}},"required":["id","contactId","firstName","lastName","channel","token","viewCount","firstViewedAt","lastViewedAt","createdAt","mergedContactId","url"],"type":"object"},"type":"array"},"url":{"format":"uri","type":["null","string"]}},"required":["channels","recipients","url"],"type":"object"},"signatureVerification":{"type":"null"},"status":{"type":"string"},"title":{"type":["null","string"]},"totalAmount":{"type":"integer"},"updatedAt":{"format":"date-time","type":"string"},"updatedBy":{"format":"uuid","type":"string"},"validUntil":{"format":"date-time","type":"string"},"verifySignerEmail":{"type":"boolean"},"viewCount":{"type":"integer"}},"required":["acceptPayments","acceptance","acceptedAt","archived","catalogRequestId","clientSelection","company","companyId","content","createdAt","createdBy","currency","currentVersion","customProperties","declineComment","declineReason","declinedAt","depositPercent","firstViewedAt","hasUnpublishedChanges","id","invoice","invoiceId","language","lastViewedAt","locked","notifications","organizationId","owner","ownerId","paidAt","payment","paymentDueDate","paymentDueDays","paymentTerms","primaryContactId","publicId","reference","reminderSentAt","sentAt","share","signatureVerification","status","title","totalAmount","updatedAt","updatedBy","validUntil","verifySignerEmail","viewCount"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/deals/{id}/activity":{"get":{"operationId":"GET /v1/deals/{id}/activity","summary":"A proposal’s timeline: sent, viewed, questions, accepted or declined.","tags":["deals"],"x-feature":"deals","x-action":"read","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"clientSelection":{"properties":{"optionalItemIds":{"items":{"format":"uuid","type":"string"},"type":"array"},"packageId":{"format":"uuid","type":"string"}},"required":["packageId","optionalItemIds"],"type":["null","object"]},"events":{"items":{"properties":{"actorId":{"format":"uuid","type":["null","string"]},"createdAt":{"format":"date-time","type":"string"},"data":{"additionalProperties":{},"type":"object"},"dealId":{"format":"uuid","type":"string"},"id":{"format":"uuid","type":"string"},"organizationId":{"format":"uuid","type":"string"},"recipientId":{"format":"uuid","type":["null","string"]},"type":{"type":"string"}},"required":["id","organizationId","dealId","type","recipientId","actorId","data","createdAt"],"type":"object"},"type":"array"},"firstViewedAt":{"format":"date-time","type":["null","string"]},"lastViewedAt":{"format":"date-time","type":["null","string"]},"recipients":{"items":{"properties":{"channel":{"type":"string"},"contactId":{"format":"uuid","type":"string"},"createdAt":{"format":"date-time","type":"string"},"firstName":{"type":"string"},"firstViewedAt":{"format":"date-time","type":"string"},"id":{"format":"uuid","type":"string"},"lastName":{"type":"null"},"lastViewedAt":{"format":"date-time","type":"string"},"mergedContactId":{"type":"null"},"token":{"type":"string"},"viewCount":{"type":"integer"}},"required":["id","contactId","firstName","lastName","channel","token","viewCount","firstViewedAt","lastViewedAt","createdAt","mergedContactId"],"type":"object"},"type":"array"},"sectionSeconds":{"properties":{"pricing":{"type":"integer"},"terms":{"type":"integer"}},"required":[],"type":"object"},"totalSeconds":{"type":"integer"},"versions":{"items":{"properties":{"createdAt":{"format":"date-time","type":"string"},"hash":{"type":"string"},"supersededAt":{"format":"date-time","type":["null","string"]},"version":{"type":"integer"}},"required":["version","hash","createdAt","supersededAt"],"type":"object"},"type":"array"},"viewCount":{"type":"integer"},"views":{"items":{"properties":{"dealId":{"format":"uuid","type":"string"},"durationSeconds":{"type":"integer"},"id":{"format":"uuid","type":"string"},"ipAddress":{"type":"string"},"lastSeenAt":{"format":"date-time","type":"string"},"organizationId":{"format":"uuid","type":"string"},"recipientId":{"format":"uuid","type":"string"},"sectionSeconds":{"properties":{"pricing":{"type":"integer"},"terms":{"type":"integer"}},"required":[],"type":"object"},"startedAt":{"format":"date-time","type":"string"},"userAgent":{"type":"null"},"version":{"type":"integer"}},"required":["id","organizationId","dealId","recipientId","version","ipAddress","userAgent","durationSeconds","sectionSeconds","startedAt","lastSeenAt"],"type":"object"},"type":"array"}},"required":["viewCount","firstViewedAt","lastViewedAt","totalSeconds","sectionSeconds","clientSelection","recipients","versions","views","events"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/deals/{id}/decline":{"post":{"operationId":"POST /v1/deals/{id}/decline","summary":"Marks a proposal as declined.","tags":["deals"],"x-feature":"deals","x-action":"update","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"reason":{"type":"string","enum":["price","timeline","scope","other"]},"comment":{"anyOf":[{"type":"string","maxLength":2000},{"type":"null"}]}},"required":["reason"]}}}},"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/deals/{id}/duplicate":{"post":{"operationId":"POST /v1/deals/{id}/duplicate","summary":"A new draft with the same content.","tags":["deals"],"x-feature":"deals","x-action":"create","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"201":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"acceptPayments":{"type":"boolean"},"acceptance":{"type":"null"},"acceptedAt":{"type":"null"},"archived":{"type":"boolean"},"catalogRequestId":{"type":"null"},"clientSelection":{"type":"null"},"company":{"type":"null"},"companyId":{"type":"null"},"content":{"properties":{"items":{"type":"array"},"packages":{"type":"array"},"scope":{"type":"null"},"summary":{"type":"null"},"terms":{"type":["null","string"]}},"required":["items","packages","scope","summary","terms"],"type":"object"},"createdAt":{"format":"date-time","type":"string"},"createdBy":{"format":"uuid","type":"string"},"currency":{"type":"string"},"currentVersion":{"type":"integer"},"customProperties":{"additionalProperties":{},"type":"object"},"declineComment":{"type":"null"},"declineReason":{"type":"null"},"declinedAt":{"type":"null"},"depositPercent":{"type":["integer","null"]},"firstViewedAt":{"type":"null"},"hasUnpublishedChanges":{"type":"boolean"},"id":{"format":"uuid","type":"string"},"invoice":{"type":"null"},"invoiceId":{"type":"null"},"language":{"type":"null"},"lastViewedAt":{"type":"null"},"locked":{"type":"boolean"},"notifications":{"properties":{"accepted":{"type":"boolean"},"declined":{"type":"boolean"},"question":{"type":"boolean"},"viewed":{"type":"boolean"}},"required":["accepted","declined","question","viewed"],"type":"object"},"organizationId":{"format":"uuid","type":"string"},"owner":{"properties":{"image":{"type":"null"},"memberId":{"format":"uuid","type":"string"},"name":{"type":"string"},"userId":{"format":"uuid","type":"string"}},"required":["image","memberId","name","userId"],"type":"object"},"ownerId":{"format":"uuid","type":"string"},"paidAt":{"type":"null"},"payment":{"type":"null"},"paymentDueDate":{"type":"null"},"paymentDueDays":{"type":"null"},"paymentTerms":{"type":"string"},"primaryContactId":{"type":"null"},"publicId":{"type":"string"},"reference":{"type":["null","string"]},"reminderSentAt":{"type":"null"},"sentAt":{"type":"null"},"share":{"properties":{"channels":{"items":{"properties":{"available":{"type":"boolean"},"id":{"type":"string"}},"required":["available","id"],"type":"object"},"type":"array"},"recipients":{"type":"array"},"url":{"type":"null"}},"required":["channels","recipients","url"],"type":"object"},"signatureVerification":{"type":"null"},"status":{"type":"string"},"title":{"type":"string"},"totalAmount":{"type":"integer"},"updatedAt":{"format":"date-time","type":"string"},"updatedBy":{"format":"uuid","type":"string"},"validUntil":{"format":"date-time","type":"string"},"verifySignerEmail":{"type":"boolean"},"viewCount":{"type":"integer"}},"required":["acceptPayments","acceptance","acceptedAt","archived","catalogRequestId","clientSelection","company","companyId","content","createdAt","createdBy","currency","currentVersion","customProperties","declineComment","declineReason","declinedAt","depositPercent","firstViewedAt","hasUnpublishedChanges","id","invoice","invoiceId","language","lastViewedAt","locked","notifications","organizationId","owner","ownerId","paidAt","payment","paymentDueDate","paymentDueDays","paymentTerms","primaryContactId","publicId","reference","reminderSentAt","sentAt","share","signatureVerification","status","title","totalAmount","updatedAt","updatedBy","validUntil","verifySignerEmail","viewCount"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/deals/{id}/history":{"get":{"operationId":"GET /v1/deals/{id}/history","summary":"Every change to a proposal’s properties, with who made it.","tags":["deals"],"x-feature":"deals","x-action":"read","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}},{"name":"field","in":"query","required":true,"schema":{"type":"string","maxLength":120,"pattern":"^[A-Za-z]+(\\.[\\w-]+)?$"}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"entries":{"items":{"properties":{"changedAt":{"format":"date-time","type":"string"},"changedBy":{"properties":{"id":{"format":"uuid","type":"string"},"name":{"type":"string"}},"required":["id","name"],"type":"object"},"id":{"format":"uuid","type":"string"},"newLabel":{"type":["null","string"]},"newValue":{"type":"string"},"oldLabel":{"type":"null"},"oldValue":{"type":["null","string"]}},"required":["id","oldValue","newValue","changedAt","oldLabel","newLabel","changedBy"],"type":"object"},"type":"array"},"field":{"type":"string"},"limit":{"type":"integer"},"total":{"type":"integer"}},"required":["field","limit","total","entries"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/deals/{id}/preview":{"get":{"operationId":"GET /v1/deals/{id}/preview","summary":"The proposal as the client would see it.","tags":["deals"],"x-feature":"deals","x-action":"read","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"selection":{"properties":{"optionalItemIds":{"type":"array"},"packageId":{"format":"uuid","type":["null","string"]}},"required":["optionalItemIds","packageId"],"type":"object"},"snapshot":{"properties":{"company":{"properties":{"name":{"type":"string"}},"required":["name"],"type":["null","object"]},"content":{"properties":{"items":{"items":{"properties":{"description":{"type":"null"},"id":{"format":"uuid","type":"string"},"name":{"type":"string"},"optional":{"type":"boolean"},"quantity":{"type":"integer"},"serviceId":{"type":"null"},"unitPrice":{"type":"integer"}},"required":["description","id","name","optional","quantity","serviceId","unitPrice"],"type":"object"},"type":"array"},"packages":{"items":{"properties":{"description":{"type":"null"},"discount":{"type":"null"},"id":{"format":"uuid","type":"string"},"items":{"items":{"properties":{"description":{"type":"null"},"id":{"format":"uuid","type":"string"},"name":{"type":"string"},"optional":{"type":"boolean"},"quantity":{"type":"integer"},"serviceId":{"type":"null"},"unitPrice":{"type":"integer"}},"required":["id","name","optional","quantity","serviceId","unitPrice","description"],"type":"object"},"type":"array"},"name":{"type":"string"},"recommended":{"type":"boolean"}},"required":["id","name","items","discount","description","recommended"],"type":"object"},"type":"array"},"scope":{"type":"null"},"summary":{"type":["null","string"]},"terms":{"type":["null","string"]}},"required":["items","packages","scope","summary","terms"],"type":"object"},"currency":{"type":"string"},"depositPercent":{"type":["integer","null"]},"language":{"type":"string"},"organization":{"properties":{"logo":{"type":"null"},"name":{"type":"string"}},"required":["logo","name"],"type":"object"},"reference":{"type":["null","string"]},"templateId":{"type":"string"},"theme":{"properties":{"accentColor":{"type":"string"},"backgroundColor":{"type":"string"},"bodyFont":{"type":"string"},"cornerRadius":{"type":"string"},"headingFont":{"type":"string"},"logoUrl":{"format":"uri","type":"string"},"primaryColor":{"type":"string"},"textColor":{"type":"string"}},"required":["accentColor","backgroundColor","bodyFont","cornerRadius","headingFont","primaryColor","textColor"],"type":"object"},"title":{"type":["null","string"]},"validUntil":{"format":"date-time","type":"string"}},"required":["company","content","currency","depositPercent","language","organization","reference","templateId","theme","title","validUntil"],"type":"object"},"totals":{"properties":{"depositAmount":{"type":["integer","null"]},"total":{"type":"integer"}},"required":["depositAmount","total"],"type":"object"},"url":{"format":"uri","type":"string"}},"required":["selection","snapshot","totals","url"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"post":{"operationId":"POST /v1/deals/{id}/preview","summary":"The proposal as the client would see it with unsaved edits; saves nothing.","tags":["deals"],"x-feature":"deals","x-action":"read","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"title":{"anyOf":[{"type":"string","maxLength":200},{"type":"null"}]},"reference":{"anyOf":[{"type":"string","maxLength":60},{"type":"null"}]},"companyId":{"anyOf":[{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},{"type":"null"}]},"primaryContactId":{"anyOf":[{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},{"type":"null"}]},"ownerId":{"type":"string","minLength":1},"currency":{"type":"string","pattern":"^[A-Z]{3}$"},"validUntil":{"type":"string","minLength":1},"depositPercent":{"anyOf":[{"type":"integer","minimum":0,"maximum":100},{"type":"null"}]},"language":{"anyOf":[{"type":"string","enum":["pt","es","en","fr"]},{"type":"null"}]},"content":{"type":"object","properties":{"summary":{"anyOf":[{"type":"string","maxLength":20000},{"type":"null"}]},"scope":{"anyOf":[{"type":"string","maxLength":50000},{"type":"null"}]},"terms":{"anyOf":[{"type":"string","maxLength":50000},{"type":"null"}]},"packages":{"maxItems":3,"type":"array","items":{"type":"object","properties":{"id":{"type":"string","minLength":1,"maxLength":64},"name":{"type":"string","minLength":1,"maxLength":100},"description":{"anyOf":[{"type":"string","maxLength":2000},{"type":"null"}]},"recommended":{"default":false,"type":"boolean"},"items":{"maxItems":50,"type":"array","items":{"type":"object","properties":{"id":{"type":"string","minLength":1,"maxLength":64},"serviceId":{"anyOf":[{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},{"type":"null"}]},"name":{"type":"string","minLength":1,"maxLength":200},"description":{"anyOf":[{"type":"string","maxLength":2000},{"type":"null"}]},"quantity":{"default":1,"type":"number","exclusiveMinimum":0,"maximum":100000},"unitPrice":{"type":"integer","minimum":0,"maximum":10000000000000},"optional":{"default":false,"type":"boolean"}},"required":["name","unitPrice"]}},"discount":{"anyOf":[{"oneOf":[{"type":"object","properties":{"type":{"type":"string","const":"percent"},"value":{"type":"number","exclusiveMinimum":0,"maximum":100,"multipleOf":0.01}},"required":["type","value"]},{"type":"object","properties":{"type":{"type":"string","const":"amount"},"value":{"type":"integer","exclusiveMinimum":0,"maximum":10000000000000}},"required":["type","value"]}]},{"type":"null"}]}},"required":["name"]}},"items":{"maxItems":100,"type":"array","items":{"type":"object","properties":{"id":{"type":"string","minLength":1,"maxLength":64},"serviceId":{"anyOf":[{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},{"type":"null"}]},"name":{"type":"string","minLength":1,"maxLength":200},"description":{"anyOf":[{"type":"string","maxLength":2000},{"type":"null"}]},"quantity":{"default":1,"type":"number","exclusiveMinimum":0,"maximum":100000},"unitPrice":{"type":"integer","minimum":0,"maximum":10000000000000},"optional":{"default":false,"type":"boolean"}},"required":["name","unitPrice"]}}}},"notifications":{"type":"object","properties":{"viewed":{"type":"boolean"},"accepted":{"type":"boolean"},"declined":{"type":"boolean"},"question":{"type":"boolean"}}},"verifySignerEmail":{"type":"boolean"},"acceptPayments":{"type":"boolean"},"paymentTerms":{"type":"string","enum":["on_acceptance","on_date","days_after"]},"paymentDueDate":{"anyOf":[{"type":"string","format":"date","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))$"},{"type":"null"}]},"paymentDueDays":{"anyOf":[{"type":"integer","minimum":1,"maximum":365},{"type":"null"}]},"customProperties":{"type":"object","propertyNames":{"type":"string"},"additionalProperties":{}},"archived":{"type":"boolean"},"templateId":{"type":"string","enum":["classic","modern","minimal","bold"]},"theme":{"type":"object","properties":{"primaryColor":{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"accentColor":{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"backgroundColor":{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"textColor":{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"headingFont":{"type":"string","pattern":"^[A-Za-z0-9 ]{1,60}$"},"bodyFont":{"type":"string","pattern":"^[A-Za-z0-9 ]{1,60}$"},"coverImageUrl":{"type":"string","maxLength":2000,"format":"uri"},"cornerRadius":{"type":"string","enum":["none","small","medium","large"]}},"additionalProperties":false}}}}}},"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"selection":{"properties":{"optionalItemIds":{"type":"array"},"packageId":{"format":"uuid","type":["null","string"]}},"required":["optionalItemIds","packageId"],"type":"object"},"snapshot":{"properties":{"company":{"properties":{"name":{"type":"string"}},"required":["name"],"type":["null","object"]},"content":{"properties":{"items":{"items":{"properties":{"description":{"type":"null"},"id":{"format":"uuid","type":"string"},"name":{"type":"string"},"optional":{"type":"boolean"},"quantity":{"type":"integer"},"serviceId":{"type":"null"},"unitPrice":{"type":"integer"}},"required":["id","serviceId","name","description","quantity","unitPrice","optional"],"type":"object"},"type":"array"},"packages":{"items":{"properties":{"description":{"type":"null"},"discount":{"properties":{"type":{"type":"string"},"value":{"type":"integer"}},"required":["type","value"],"type":"object"},"id":{"format":"uuid","type":"string"},"items":{"items":{"properties":{"description":{"type":"null"},"id":{"format":"uuid","type":"string"},"name":{"type":"string"},"optional":{"type":"boolean"},"quantity":{"type":"integer"},"serviceId":{"type":"null"},"unitPrice":{"type":"integer"}},"required":["id","serviceId","name","description","quantity","unitPrice","optional"],"type":"object"},"type":"array"},"name":{"type":"string"},"recommended":{"type":"boolean"}},"required":["id","name","description","recommended","items","discount"],"type":"object"},"type":"array"},"scope":{"type":"null"},"summary":{"type":"null"},"terms":{"type":"null"}},"required":["items","packages","scope","summary","terms"],"type":"object"},"currency":{"type":"string"},"depositPercent":{"type":["integer","null"]},"language":{"type":"string"},"organization":{"properties":{"logo":{"type":"null"},"name":{"type":"string"}},"required":["logo","name"],"type":"object"},"reference":{"type":"null"},"templateId":{"type":"string"},"theme":{"properties":{"accentColor":{"type":"string"},"backgroundColor":{"type":"string"},"bodyFont":{"type":"string"},"cornerRadius":{"type":"string"},"headingFont":{"type":"string"},"primaryColor":{"type":"string"},"textColor":{"type":"string"}},"required":["accentColor","backgroundColor","bodyFont","cornerRadius","headingFont","primaryColor","textColor"],"type":"object"},"title":{"type":"string"},"validUntil":{"format":"date-time","type":"string"}},"required":["company","content","currency","depositPercent","language","organization","reference","templateId","theme","title","validUntil"],"type":"object"},"totals":{"properties":{"depositAmount":{"type":["integer","null"]},"total":{"type":"integer"}},"required":["depositAmount","total"],"type":"object"},"url":{"format":"uri","type":"string"}},"required":["selection","snapshot","totals","url"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/deals/{id}/questions":{"get":{"operationId":"GET /v1/deals/{id}/questions","summary":"Questions clients asked on the proposal’s page, newest first.","tags":["deals"],"x-feature":"deals","x-action":"read","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"items":{"properties":{"answer":{"type":"null"},"answerSentTo":{"type":"null"},"answeredAt":{"type":"null"},"answeredBy":{"type":"null"},"contact":{"properties":{"emails":{"items":{"format":"email","type":"string"},"type":"array"},"id":{"format":"uuid","type":"string"},"name":{"type":"string"},"phones":{"type":"array"},"socialProfiles":{"properties":{},"required":[],"type":"object"}},"required":["emails","id","name","phones","socialProfiles"],"type":"object"},"createdAt":{"format":"date-time","type":"string"},"email":{"format":"email","type":"string"},"fromRecipientLink":{"type":"boolean"},"id":{"format":"uuid","type":"string"},"message":{"type":"string"},"name":{"type":"string"}},"required":["answer","answerSentTo","answeredAt","answeredBy","contact","createdAt","email","fromRecipientLink","id","message","name"],"type":"object"},"type":"array"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/deals/{id}/questions/{questionId}":{"patch":{"operationId":"PATCH /v1/deals/{id}/questions/{questionId}","summary":"Marks a client’s question as answered or not.","tags":["deals"],"x-feature":"deals","x-action":"update","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}},{"name":"questionId","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"answered":{"type":"boolean"}},"required":["answered"]}}}},"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"answer":{"type":"null"},"answerSentTo":{"type":"null"},"answeredAt":{"format":"date-time","type":["null","string"]},"answeredBy":{"type":["null","string"]},"contact":{"properties":{"emails":{"items":{"format":"email","type":"string"},"type":"array"},"id":{"format":"uuid","type":"string"},"name":{"type":"string"},"phones":{"type":"array"},"socialProfiles":{"properties":{},"required":[],"type":"object"}},"required":["id","name","emails","phones","socialProfiles"],"type":"object"},"createdAt":{"format":"date-time","type":"string"},"email":{"format":"email","type":"string"},"fromRecipientLink":{"type":"boolean"},"id":{"format":"uuid","type":"string"},"message":{"type":"string"},"name":{"type":"string"}},"required":["id","message","name","email","answeredAt","answer","answerSentTo","createdAt","fromRecipientLink","answeredBy","contact"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/deals/{id}/questions/{questionId}/reply":{"post":{"operationId":"POST /v1/deals/{id}/questions/{questionId}/reply","summary":"Emails a reply to whoever asked the question, and keeps it with it.","tags":["deals"],"x-feature":"deals","x-action":"update","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}},{"name":"questionId","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"message":{"type":"string","minLength":1,"maxLength":5000}},"required":["message"]}}}},"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"answer":{"type":"string"},"answerSentTo":{"format":"email","type":"string"},"answeredAt":{"format":"date-time","type":"string"},"answeredBy":{"type":"string"},"contact":{"properties":{"emails":{"items":{"format":"email","type":"string"},"type":"array"},"id":{"format":"uuid","type":"string"},"name":{"type":"string"},"phones":{"type":"array"},"socialProfiles":{"properties":{},"required":[],"type":"object"}},"required":["id","name","emails","phones","socialProfiles"],"type":"object"},"createdAt":{"format":"date-time","type":"string"},"email":{"format":"email","type":"string"},"fromRecipientLink":{"type":"boolean"},"id":{"format":"uuid","type":"string"},"message":{"type":"string"},"name":{"type":"string"}},"required":["id","message","name","email","answeredAt","answer","answerSentTo","createdAt","fromRecipientLink","answeredBy","contact"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/deals/{id}/recipients":{"post":{"operationId":"POST /v1/deals/{id}/recipients","summary":"Adds a contact to send the proposal to and returns their tracked link.","tags":["deals"],"x-feature":"deals","x-action":"update","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"contactId":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},"channel":{"default":"link","type":"string","enum":["link","email","whatsapp"]}},"required":["contactId"]}}}},"responses":{"201":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"channel":{"type":"string"},"contactId":{"format":"uuid","type":"string"},"createdAt":{"format":"date-time","type":"string"},"firstName":{"type":"string"},"firstViewedAt":{"type":"null"},"id":{"format":"uuid","type":"string"},"lastName":{"type":["null","string"]},"lastViewedAt":{"type":"null"},"mergedContactId":{"type":"null"},"token":{"type":"string"},"url":{"format":"uri","type":"string"},"viewCount":{"type":"integer"}},"required":["channel","contactId","createdAt","firstName","firstViewedAt","id","lastName","lastViewedAt","mergedContactId","token","url","viewCount"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/deals/{id}/recipients/{recipientId}":{"delete":{"operationId":"DELETE /v1/deals/{id}/recipients/{recipientId}","summary":"Removes a recipient; their link stops working.","tags":["deals"],"x-feature":"deals","x-action":"update","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}},{"name":"recipientId","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"204":{"description":"Done, with no content."},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/deals/{id}/reopen":{"post":{"operationId":"POST /v1/deals/{id}/reopen","summary":"Reopens a declined or expired proposal, with a validity date ahead.","tags":["deals"],"x-feature":"deals","x-action":"update","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"validUntil":{"default":null,"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}]}}}}}},"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"acceptPayments":{"type":"boolean"},"acceptance":{"type":"null"},"acceptedAt":{"type":"null"},"archived":{"type":"boolean"},"catalogRequestId":{"type":"null"},"clientSelection":{"type":"null"},"company":{"type":"null"},"companyId":{"type":"null"},"content":{"properties":{"items":{"items":{"properties":{"description":{"type":"null"},"id":{"format":"uuid","type":"string"},"name":{"type":"string"},"optional":{"type":"boolean"},"quantity":{"type":"integer"},"serviceId":{"type":"null"},"unitPrice":{"type":"integer"}},"required":["id","name","optional","quantity","serviceId","unitPrice","description"],"type":"object"},"type":"array"},"packages":{"items":{"properties":{"description":{"type":"null"},"discount":{"type":"null"},"id":{"format":"uuid","type":"string"},"items":{"items":{"properties":{"description":{"type":"null"},"id":{"format":"uuid","type":"string"},"name":{"type":"string"},"optional":{"type":"boolean"},"quantity":{"type":"integer"},"serviceId":{"type":"null"},"unitPrice":{"type":"integer"}},"required":["id","name","optional","quantity","serviceId","unitPrice","description"],"type":"object"},"type":"array"},"name":{"type":"string"},"recommended":{"type":"boolean"}},"required":["id","name","items","discount","description","recommended"],"type":"object"},"type":"array"},"scope":{"type":"null"},"summary":{"type":"string"},"terms":{"type":"string"}},"required":["items","scope","terms","summary","packages"],"type":"object"},"createdAt":{"format":"date-time","type":"string"},"createdBy":{"format":"uuid","type":"string"},"currency":{"type":"string"},"currentVersion":{"type":"integer"},"customProperties":{"additionalProperties":{},"type":"object"},"declineComment":{"type":"null"},"declineReason":{"type":"null"},"declinedAt":{"type":"null"},"depositPercent":{"type":"integer"},"firstViewedAt":{"type":"null"},"hasUnpublishedChanges":{"type":"boolean"},"id":{"format":"uuid","type":"string"},"invoice":{"type":"null"},"invoiceId":{"type":"null"},"language":{"type":"null"},"lastViewedAt":{"type":"null"},"locked":{"type":"boolean"},"notifications":{"properties":{"accepted":{"type":"boolean"},"declined":{"type":"boolean"},"question":{"type":"boolean"},"viewed":{"type":"boolean"}},"required":["viewed","accepted","declined","question"],"type":"object"},"organizationId":{"format":"uuid","type":"string"},"owner":{"properties":{"image":{"type":"null"},"memberId":{"format":"uuid","type":"string"},"name":{"type":"string"},"userId":{"format":"uuid","type":"string"}},"required":["memberId","userId","name","image"],"type":"object"},"ownerId":{"format":"uuid","type":"string"},"paidAt":{"type":"null"},"payment":{"type":"null"},"paymentDueDate":{"type":"null"},"paymentDueDays":{"type":"null"},"paymentTerms":{"type":"string"},"primaryContactId":{"type":"null"},"publicId":{"type":"string"},"reference":{"type":"null"},"reminderSentAt":{"type":"null"},"sentAt":{"format":"date-time","type":"string"},"share":{"properties":{"channels":{"items":{"properties":{"available":{"type":"boolean"},"id":{"type":"string"}},"required":["id","available"],"type":"object"},"type":"array"},"recipients":{"type":"array"},"url":{"format":"uri","type":"string"}},"required":["url","channels","recipients"],"type":"object"},"signatureVerification":{"type":"null"},"status":{"type":"string"},"title":{"type":"string"},"totalAmount":{"type":"integer"},"updatedAt":{"format":"date-time","type":"string"},"updatedBy":{"format":"uuid","type":"string"},"validUntil":{"format":"date-time","type":"string"},"verifySignerEmail":{"type":"boolean"},"viewCount":{"type":"integer"}},"required":["id","organizationId","catalogRequestId","publicId","title","reference","status","companyId","primaryContactId","ownerId","language","currency","totalAmount","validUntil","depositPercent","content","notifications","verifySignerEmail","acceptPayments","paymentTerms","paymentDueDate","paymentDueDays","invoiceId","paidAt","customProperties","currentVersion","hasUnpublishedChanges","clientSelection","viewCount","sentAt","firstViewedAt","lastViewedAt","acceptedAt","declinedAt","declineReason","declineComment","reminderSentAt","archived","createdBy","updatedBy","createdAt","updatedAt","signatureVerification","owner","company","acceptance","payment","invoice","locked","share"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/deals/{id}/send":{"post":{"operationId":"POST /v1/deals/{id}/send","summary":"Sends the proposal, or publishes the edited draft as the next version on the same link.","tags":["deals"],"x-feature":"deals","x-action":"update","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"acceptPayments":{"type":"boolean"},"acceptance":{"type":"null"},"acceptedAt":{"type":"null"},"archived":{"type":"boolean"},"catalogRequestId":{"type":"null"},"clientSelection":{"properties":{"optionalItemIds":{"items":{"format":"uuid","type":"string"},"type":"array"},"packageId":{"format":"uuid","type":"string"}},"required":["optionalItemIds","packageId"],"type":["null","object"]},"company":{"properties":{"id":{"format":"uuid","type":"string"},"name":{"type":"string"}},"required":["id","name"],"type":["null","object"]},"companyId":{"format":"uuid","type":["null","string"]},"content":{"properties":{"items":{"items":{"properties":{"description":{"type":"null"},"id":{"format":"uuid","type":"string"},"name":{"type":"string"},"optional":{"type":"boolean"},"quantity":{"type":"integer"},"serviceId":{"type":"null"},"unitPrice":{"type":"integer"}},"required":["description","id","name","optional","quantity","serviceId","unitPrice"],"type":"object"},"type":"array"},"packages":{"items":{"properties":{"description":{"type":"null"},"discount":{"properties":{"type":{"type":"string"},"value":{"type":"integer"}},"required":["type","value"],"type":["null","object"]},"id":{"format":"uuid","type":"string"},"items":{"items":{"properties":{"description":{"type":"null"},"id":{"format":"uuid","type":"string"},"name":{"type":"string"},"optional":{"type":"boolean"},"quantity":{"type":"integer"},"serviceId":{"type":"null"},"unitPrice":{"type":"integer"}},"required":["description","id","name","optional","quantity","serviceId","unitPrice"],"type":"object"},"type":"array"},"name":{"type":"string"},"recommended":{"type":"boolean"}},"required":["description","discount","id","items","name","recommended"],"type":"object"},"type":"array"},"scope":{"type":"null"},"summary":{"type":["null","string"]},"terms":{"type":["null","string"]}},"required":["items","packages","scope","summary","terms"],"type":"object"},"createdAt":{"format":"date-time","type":"string"},"createdBy":{"format":"uuid","type":"string"},"currency":{"type":"string"},"currentVersion":{"type":"integer"},"customProperties":{"additionalProperties":{},"type":"object"},"declineComment":{"type":"null"},"declineReason":{"type":"null"},"declinedAt":{"type":"null"},"depositPercent":{"type":["integer","null"]},"firstViewedAt":{"format":"date-time","type":["null","string"]},"hasUnpublishedChanges":{"type":"boolean"},"id":{"format":"uuid","type":"string"},"invoice":{"type":"null"},"invoiceId":{"type":"null"},"language":{"type":"null"},"lastViewedAt":{"format":"date-time","type":["null","string"]},"locked":{"type":"boolean"},"notifications":{"properties":{"accepted":{"type":"boolean"},"declined":{"type":"boolean"},"question":{"type":"boolean"},"viewed":{"type":"boolean"}},"required":["accepted","declined","question","viewed"],"type":"object"},"organizationId":{"format":"uuid","type":"string"},"owner":{"properties":{"image":{"type":"null"},"memberId":{"format":"uuid","type":"string"},"name":{"type":"string"},"userId":{"format":"uuid","type":"string"}},"required":["image","memberId","name","userId"],"type":"object"},"ownerId":{"format":"uuid","type":"string"},"paidAt":{"type":"null"},"payment":{"type":"null"},"paymentDueDate":{"type":"null"},"paymentDueDays":{"type":["integer","null"]},"paymentTerms":{"type":"string"},"primaryContactId":{"format":"uuid","type":["null","string"]},"publicId":{"type":"string"},"reference":{"type":"null"},"reminderSentAt":{"type":"null"},"sentAt":{"format":"date-time","type":"string"},"share":{"properties":{"channels":{"items":{"properties":{"available":{"type":"boolean"},"id":{"type":"string"}},"required":["available","id"],"type":"object"},"type":"array"},"recipients":{"items":{"properties":{"channel":{"type":"string"},"contactId":{"format":"uuid","type":"string"},"createdAt":{"format":"date-time","type":"string"},"firstName":{"type":"string"},"firstViewedAt":{"format":"date-time","type":"string"},"id":{"format":"uuid","type":"string"},"lastName":{"type":"null"},"lastViewedAt":{"format":"date-time","type":"string"},"mergedContactId":{"type":"null"},"token":{"type":"string"},"url":{"format":"uri","type":"string"},"viewCount":{"type":"integer"}},"required":["id","contactId","firstName","lastName","channel","token","viewCount","firstViewedAt","lastViewedAt","createdAt","mergedContactId","url"],"type":"object"},"type":"array"},"url":{"format":"uri","type":"string"}},"required":["channels","recipients","url"],"type":"object"},"signatureVerification":{"type":"null"},"status":{"type":"string"},"title":{"type":"string"},"totalAmount":{"type":"integer"},"updatedAt":{"format":"date-time","type":"string"},"updatedBy":{"format":"uuid","type":"string"},"validUntil":{"format":"date-time","type":"string"},"verifySignerEmail":{"type":"boolean"},"viewCount":{"type":"integer"}},"required":["acceptPayments","acceptance","acceptedAt","archived","catalogRequestId","clientSelection","company","companyId","content","createdAt","createdBy","currency","currentVersion","customProperties","declineComment","declineReason","declinedAt","depositPercent","firstViewedAt","hasUnpublishedChanges","id","invoice","invoiceId","language","lastViewedAt","locked","notifications","organizationId","owner","ownerId","paidAt","payment","paymentDueDate","paymentDueDays","paymentTerms","primaryContactId","publicId","reference","reminderSentAt","sentAt","share","signatureVerification","status","title","totalAmount","updatedAt","updatedBy","validUntil","verifySignerEmail","viewCount"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/deals/{id}/signature/resend":{"post":{"operationId":"POST /v1/deals/{id}/signature/resend","summary":"Sends the signer a new link to confirm their email address.","tags":["deals"],"x-feature":"deals","x-action":"update","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"email":{"format":"email","type":"string"},"sendCount":{"type":"integer"},"sentAt":{"format":"date-time","type":"string"},"verifiedAt":{"type":"null"},"verifiedIp":{"type":"null"},"verifiedUserAgent":{"type":"null"}},"required":["email","sentAt","sendCount","verifiedAt","verifiedIp","verifiedUserAgent"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/deals/board":{"get":{"operationId":"GET /v1/deals/board","summary":"Proposals grouped by status, for a board.","tags":["deals"],"x-feature":"deals","x-action":"read","parameters":[{"name":"q","in":"query","required":false,"schema":{"type":"string","minLength":1,"maxLength":200}},{"name":"ownerId","in":"query","required":false,"schema":{"type":"string"}},{"name":"companyId","in":"query","required":false,"schema":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"}},{"name":"contactId","in":"query","required":false,"schema":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"}},{"name":"dueFrom","in":"query","required":false,"schema":{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"}},{"name":"dueBefore","in":"query","required":false,"schema":{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"columns":{"items":{"properties":{"amount":{"type":"integer"},"count":{"type":"integer"},"deals":{"items":{"properties":{"acceptedAt":{"type":"null"},"archived":{"type":"boolean"},"companyId":{"format":"uuid","type":["null","string"]},"companyName":{"type":["null","string"]},"createdAt":{"format":"date-time","type":"string"},"currency":{"type":"string"},"hasUnpublishedChanges":{"type":"boolean"},"id":{"format":"uuid","type":"string"},"lastViewedAt":{"type":"null"},"ownerId":{"format":"uuid","type":"string"},"ownerImage":{"type":"null"},"ownerName":{"type":"string"},"paidAt":{"type":"null"},"reference":{"type":"null"},"sentAt":{"format":"date-time","type":["null","string"]},"status":{"type":"string"},"title":{"type":"string"},"totalAmount":{"type":"integer"},"updatedAt":{"format":"date-time","type":"string"},"validUntil":{"format":"date-time","type":"string"},"viewCount":{"type":"integer"}},"required":["acceptedAt","archived","companyId","companyName","createdAt","currency","hasUnpublishedChanges","id","lastViewedAt","ownerId","ownerImage","ownerName","paidAt","reference","sentAt","status","title","totalAmount","updatedAt","validUntil","viewCount"],"type":"object"},"type":"array"},"status":{"type":"string"}},"required":["amount","count","deals","status"],"type":"object"},"type":"array"}},"required":["columns"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/email-signatures":{"get":{"operationId":"GET /v1/email-signatures","summary":"Lists the saved email signatures.","tags":["emailSignatures"],"x-feature":"emailSignatures","x-action":"read","responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"items":{"properties":{"createdAt":{"format":"date-time","type":"string"},"createdBy":{"format":"uuid","type":"string"},"document":{"properties":{"address":{"type":"string"},"banner":{"properties":{"image":{"type":"string"},"url":{"type":"string"},"width":{"type":"integer"}},"required":["url","image","width"],"type":"object"},"booking":{"properties":{"label":{"type":"string"},"style":{"type":"string"},"url":{"format":"uri","type":"string"}},"required":["url","label","style"],"type":"object"},"colors":{"properties":{"below":{"type":"string"},"button":{"type":"string"},"line":{"type":"string"},"name":{"type":"string"},"text":{"type":"string"}},"required":["line","name","text","below","button"],"type":"object"},"company":{"type":"string"},"department":{"type":"string"},"disclaimer":{"type":"string"},"email":{"format":"email","type":"string"},"font":{"type":"string"},"fontSize":{"type":"integer"},"iconColor":{"type":"null"},"iconSize":{"type":"integer"},"iconStyle":{"type":"string"},"jobTitle":{"type":"string"},"logo":{"type":"string"},"logoWidth":{"type":"integer"},"maxWidth":{"type":"integer"},"mobile":{"type":"string"},"name":{"type":"string"},"phone":{"type":"string"},"photo":{"type":"string"},"photoShape":{"type":"string"},"photoSize":{"type":"integer"},"pronouns":{"type":"string"},"socials":{"items":{"properties":{"network":{"type":"string"},"url":{"type":"string"}},"required":["url","network"],"type":"object"},"type":"array"},"theme":{"type":"string"},"website":{"type":"string"}},"required":["font","logo","name","email","phone","photo","theme","banner","colors","mobile","address","booking","company","socials","website","fontSize","iconSize","jobTitle","maxWidth","pronouns","iconColor","iconStyle","logoWidth","photoSize","department","disclaimer","photoShape"],"type":"object"},"id":{"format":"uuid","type":"string"},"name":{"type":"string"},"updatedAt":{"format":"date-time","type":"string"},"updatedBy":{"format":"uuid","type":"string"}},"required":["id","name","document","createdBy","updatedBy","createdAt","updatedAt"],"type":"object"},"type":"array"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"post":{"operationId":"POST /v1/email-signatures","summary":"Saves an email signature.","tags":["emailSignatures"],"x-feature":"emailSignatures","x-action":"create","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"name":{"type":"string","minLength":1,"maxLength":120},"document":{"default":{"theme":"classic","name":"","jobTitle":"","department":"","pronouns":"","company":"","email":"","phone":"","mobile":"","website":"","address":"","photo":"","photoShape":"circle","photoSize":80,"logo":"","logoWidth":120,"socials":[],"iconStyle":"filled","iconColor":null,"iconSize":22,"booking":{"url":"","label":"","style":"button"},"banner":{"image":"","url":"","width":400},"disclaimer":"","colors":{"name":"#0f766e","text":"#1f2937","line":"#0f766e","button":"#0f766e","below":"#6b7280"},"maxWidth":600,"font":"arial","fontSize":13},"type":"object","properties":{"theme":{"default":"classic","type":"string","enum":["classic","stacked","minimal","split"]},"name":{"default":"","type":"string","maxLength":120},"jobTitle":{"default":"","type":"string","maxLength":120},"department":{"default":"","type":"string","maxLength":120},"pronouns":{"default":"","type":"string","maxLength":40},"company":{"default":"","type":"string","maxLength":120},"email":{"default":"","anyOf":[{"type":"string","const":""},{"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,}$"}]},"phone":{"default":"","type":"string","maxLength":40},"mobile":{"default":"","type":"string","maxLength":40},"website":{"default":"","type":"string","maxLength":2000},"address":{"default":"","type":"string","maxLength":240},"photo":{"default":"","type":"string","maxLength":2000},"photoShape":{"default":"circle","type":"string","enum":["circle","rounded","square"]},"photoSize":{"default":80,"type":"integer","minimum":40,"maximum":140},"logo":{"default":"","type":"string","maxLength":2000},"logoWidth":{"default":120,"type":"integer","minimum":40,"maximum":260},"socials":{"default":[],"maxItems":12,"type":"array","items":{"type":"object","properties":{"network":{"type":"string","enum":["facebook","instagram","linkedin","x","youtube","tiktok","whatsapp","threads","discord","pinterest","github","phone","web"]},"url":{"type":"string","minLength":1,"maxLength":2000}},"required":["network","url"]}},"iconStyle":{"default":"filled","type":"string","enum":["filled","plain"]},"iconColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"iconSize":{"default":22,"type":"integer","minimum":14,"maximum":36},"booking":{"default":{"url":"","label":"","style":"button"},"type":"object","properties":{"url":{"default":"","type":"string","maxLength":2000},"label":{"default":"","type":"string","maxLength":60},"style":{"default":"button","type":"string","enum":["button","link"]}}},"banner":{"default":{"image":"","url":"","width":400},"type":"object","properties":{"image":{"default":"","type":"string","maxLength":2000},"url":{"default":"","type":"string","maxLength":2000},"width":{"default":400,"type":"integer","minimum":120,"maximum":600}}},"disclaimer":{"default":"","type":"string","maxLength":2000},"colors":{"default":{"name":"#0f766e","text":"#1f2937","line":"#0f766e","button":"#0f766e","below":"#6b7280"},"type":"object","properties":{"name":{"default":"#0f766e","type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"text":{"default":"#1f2937","type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"line":{"default":"#0f766e","type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"button":{"default":"#0f766e","type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"below":{"default":"#6b7280","type":"string","pattern":"^#[0-9a-fA-F]{6}$"}}},"maxWidth":{"default":600,"type":"integer","minimum":280,"maximum":800},"font":{"default":"arial","type":"string","enum":["arial","helvetica","verdana","tahoma","trebuchet","georgia","times"]},"fontSize":{"default":13,"type":"integer","minimum":11,"maximum":16}}}},"required":["name"]}}}},"responses":{"201":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"createdAt":{"format":"date-time","type":"string"},"createdBy":{"format":"uuid","type":"string"},"document":{"properties":{"address":{"type":"string"},"banner":{"properties":{"image":{"type":"string"},"url":{"type":"string"},"width":{"type":"integer"}},"required":["url","image","width"],"type":"object"},"booking":{"properties":{"label":{"type":"string"},"style":{"type":"string"},"url":{"format":"uri","type":"string"}},"required":["url","label","style"],"type":"object"},"colors":{"properties":{"below":{"type":"string"},"button":{"type":"string"},"line":{"type":"string"},"name":{"type":"string"},"text":{"type":"string"}},"required":["line","name","text","below","button"],"type":"object"},"company":{"type":"string"},"department":{"type":"string"},"disclaimer":{"type":"string"},"email":{"format":"email","type":"string"},"font":{"type":"string"},"fontSize":{"type":"integer"},"iconColor":{"type":"null"},"iconSize":{"type":"integer"},"iconStyle":{"type":"string"},"jobTitle":{"type":"string"},"logo":{"type":"string"},"logoWidth":{"type":"integer"},"maxWidth":{"type":"integer"},"mobile":{"type":"string"},"name":{"type":"string"},"phone":{"type":"string"},"photo":{"type":"string"},"photoShape":{"type":"string"},"photoSize":{"type":"integer"},"pronouns":{"type":"string"},"socials":{"items":{"properties":{"network":{"type":"string"},"url":{"type":"string"}},"required":["url","network"],"type":"object"},"type":"array"},"theme":{"type":"string"},"website":{"type":"string"}},"required":["font","logo","name","email","phone","photo","theme","banner","colors","mobile","address","booking","company","socials","website","fontSize","iconSize","jobTitle","maxWidth","pronouns","iconColor","iconStyle","logoWidth","photoSize","department","disclaimer","photoShape"],"type":"object"},"id":{"format":"uuid","type":"string"},"name":{"type":"string"},"updatedAt":{"format":"date-time","type":"string"},"updatedBy":{"format":"uuid","type":"string"}},"required":["id","name","document","createdBy","updatedBy","createdAt","updatedAt"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/email-signatures/{id}":{"delete":{"operationId":"DELETE /v1/email-signatures/{id}","summary":"Deletes a saved email signature.","tags":["emailSignatures"],"x-feature":"emailSignatures","x-action":"delete","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"204":{"description":"Done, with no content."},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"get":{"operationId":"GET /v1/email-signatures/{id}","summary":"Returns a saved email signature.","tags":["emailSignatures"],"x-feature":"emailSignatures","x-action":"read","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"patch":{"operationId":"PATCH /v1/email-signatures/{id}","summary":"Changes a saved email signature.","tags":["emailSignatures"],"x-feature":"emailSignatures","x-action":"update","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"name":{"type":"string","minLength":1,"maxLength":120},"document":{"type":"object","properties":{"theme":{"default":"classic","type":"string","enum":["classic","stacked","minimal","split"]},"name":{"default":"","type":"string","maxLength":120},"jobTitle":{"default":"","type":"string","maxLength":120},"department":{"default":"","type":"string","maxLength":120},"pronouns":{"default":"","type":"string","maxLength":40},"company":{"default":"","type":"string","maxLength":120},"email":{"default":"","anyOf":[{"type":"string","const":""},{"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,}$"}]},"phone":{"default":"","type":"string","maxLength":40},"mobile":{"default":"","type":"string","maxLength":40},"website":{"default":"","type":"string","maxLength":2000},"address":{"default":"","type":"string","maxLength":240},"photo":{"default":"","type":"string","maxLength":2000},"photoShape":{"default":"circle","type":"string","enum":["circle","rounded","square"]},"photoSize":{"default":80,"type":"integer","minimum":40,"maximum":140},"logo":{"default":"","type":"string","maxLength":2000},"logoWidth":{"default":120,"type":"integer","minimum":40,"maximum":260},"socials":{"default":[],"maxItems":12,"type":"array","items":{"type":"object","properties":{"network":{"type":"string","enum":["facebook","instagram","linkedin","x","youtube","tiktok","whatsapp","threads","discord","pinterest","github","phone","web"]},"url":{"type":"string","minLength":1,"maxLength":2000}},"required":["network","url"]}},"iconStyle":{"default":"filled","type":"string","enum":["filled","plain"]},"iconColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"iconSize":{"default":22,"type":"integer","minimum":14,"maximum":36},"booking":{"default":{"url":"","label":"","style":"button"},"type":"object","properties":{"url":{"default":"","type":"string","maxLength":2000},"label":{"default":"","type":"string","maxLength":60},"style":{"default":"button","type":"string","enum":["button","link"]}}},"banner":{"default":{"image":"","url":"","width":400},"type":"object","properties":{"image":{"default":"","type":"string","maxLength":2000},"url":{"default":"","type":"string","maxLength":2000},"width":{"default":400,"type":"integer","minimum":120,"maximum":600}}},"disclaimer":{"default":"","type":"string","maxLength":2000},"colors":{"default":{"name":"#0f766e","text":"#1f2937","line":"#0f766e","button":"#0f766e","below":"#6b7280"},"type":"object","properties":{"name":{"default":"#0f766e","type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"text":{"default":"#1f2937","type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"line":{"default":"#0f766e","type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"button":{"default":"#0f766e","type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"below":{"default":"#6b7280","type":"string","pattern":"^#[0-9a-fA-F]{6}$"}}},"maxWidth":{"default":600,"type":"integer","minimum":280,"maximum":800},"font":{"default":"arial","type":"string","enum":["arial","helvetica","verdana","tahoma","trebuchet","georgia","times"]},"fontSize":{"default":13,"type":"integer","minimum":11,"maximum":16}}}}}}}},"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"createdAt":{"format":"date-time","type":"string"},"createdBy":{"format":"uuid","type":"string"},"document":{"properties":{"address":{"type":"string"},"banner":{"properties":{"image":{"type":"string"},"url":{"type":"string"},"width":{"type":"integer"}},"required":["url","image","width"],"type":"object"},"booking":{"properties":{"label":{"type":"string"},"style":{"type":"string"},"url":{"format":"uri","type":"string"}},"required":["url","label","style"],"type":"object"},"colors":{"properties":{"below":{"type":"string"},"button":{"type":"string"},"line":{"type":"string"},"name":{"type":"string"},"text":{"type":"string"}},"required":["line","name","text","below","button"],"type":"object"},"company":{"type":"string"},"department":{"type":"string"},"disclaimer":{"type":"string"},"email":{"format":"email","type":"string"},"font":{"type":"string"},"fontSize":{"type":"integer"},"iconColor":{"type":"null"},"iconSize":{"type":"integer"},"iconStyle":{"type":"string"},"jobTitle":{"type":"string"},"logo":{"type":"string"},"logoWidth":{"type":"integer"},"maxWidth":{"type":"integer"},"mobile":{"type":"string"},"name":{"type":"string"},"phone":{"type":"string"},"photo":{"type":"string"},"photoShape":{"type":"string"},"photoSize":{"type":"integer"},"pronouns":{"type":"string"},"socials":{"items":{"properties":{"network":{"type":"string"},"url":{"type":"string"}},"required":["url","network"],"type":"object"},"type":"array"},"theme":{"type":"string"},"website":{"type":"string"}},"required":["font","logo","name","email","phone","photo","theme","banner","colors","mobile","address","booking","company","socials","website","fontSize","iconSize","jobTitle","maxWidth","pronouns","iconColor","iconStyle","logoWidth","photoSize","department","disclaimer","photoShape"],"type":"object"},"id":{"format":"uuid","type":"string"},"name":{"type":"string"},"updatedAt":{"format":"date-time","type":"string"},"updatedBy":{"format":"uuid","type":"string"}},"required":["id","name","document","createdBy","updatedBy","createdAt","updatedAt"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/emails/automations":{"get":{"operationId":"GET /v1/emails/automations","summary":"Lists the email automations.","tags":["emails"],"x-feature":"emails","x-action":"read","responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"post":{"operationId":"POST /v1/emails/automations","summary":"Creates an email automation: what starts it and which template it sends.","tags":["emails"],"x-feature":"emails","x-action":"create","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"name":{"type":"string","minLength":1,"maxLength":120},"kind":{"default":"marketing","type":"string","enum":["marketing","transactional"]},"trigger":{"type":"object","properties":{"type":{"type":"string","enum":["list.joined","contact.created","form.submitted","deal.accepted","invoice.paid","appointment.created"]},"listId":{"anyOf":[{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},{"type":"null"}]},"formId":{"anyOf":[{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},{"type":"null"}]}},"required":["type"]},"delayMinutes":{"default":0,"type":"integer","minimum":0,"maximum":43200},"templateId":{"default":null,"anyOf":[{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},{"type":"null"}]},"domainId":{"anyOf":[{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},{"type":"null"}]},"fromName":{"anyOf":[{"type":"string","maxLength":100},{"type":"null"}]},"fromLocal":{"anyOf":[{"type":"string","pattern":"^[a-z0-9](?:[a-z0-9._+-]{0,62}[a-z0-9])?$"},{"type":"null"}]},"replyTo":{"anyOf":[{"type":"string","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,}$"},{"type":"null"}]}},"required":["name","trigger"]}}}},"responses":{"201":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"activatedAt":{"type":"null"},"active":{"type":"boolean"},"createdAt":{"format":"date-time","type":"string"},"createdBy":{"format":"uuid","type":"string"},"delayMinutes":{"type":"integer"},"domainId":{"type":"null"},"fromLocal":{"type":"null"},"fromName":{"type":"null"},"id":{"format":"uuid","type":"string"},"kind":{"type":"string"},"name":{"type":"string"},"organizationId":{"format":"uuid","type":"string"},"replyTo":{"type":"null"},"templateId":{"format":"uuid","type":"string"},"trigger":{"properties":{"formId":{"type":"null"},"listId":{"format":"uuid","type":"string"},"type":{"type":"string"}},"required":["type","formId","listId"],"type":"object"},"updatedAt":{"format":"date-time","type":"string"}},"required":["id","organizationId","name","active","kind","trigger","delayMinutes","templateId","domainId","fromName","fromLocal","replyTo","activatedAt","createdBy","createdAt","updatedAt"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/emails/automations/{id}":{"delete":{"operationId":"DELETE /v1/emails/automations/{id}","summary":"Deletes an email automation.","tags":["emails"],"x-feature":"emails","x-action":"delete","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"204":{"description":"Done, with no content."},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"patch":{"operationId":"PATCH /v1/emails/automations/{id}","summary":"Changes an email automation.","tags":["emails"],"x-feature":"emails","x-action":"update","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"name":{"type":"string","minLength":1,"maxLength":120},"kind":{"type":"string","enum":["marketing","transactional"]},"trigger":{"type":"object","properties":{"type":{"type":"string","enum":["list.joined","contact.created","form.submitted","deal.accepted","invoice.paid","appointment.created"]},"listId":{"anyOf":[{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},{"type":"null"}]},"formId":{"anyOf":[{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},{"type":"null"}]}},"required":["type"]},"delayMinutes":{"type":"integer","minimum":0,"maximum":43200},"templateId":{"anyOf":[{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},{"type":"null"}]},"domainId":{"anyOf":[{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},{"type":"null"}]},"fromName":{"anyOf":[{"type":"string","maxLength":100},{"type":"null"}]},"fromLocal":{"anyOf":[{"type":"string","pattern":"^[a-z0-9](?:[a-z0-9._+-]{0,62}[a-z0-9])?$"},{"type":"null"}]},"replyTo":{"anyOf":[{"type":"string","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,}$"},{"type":"null"}]}}}}}},"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/emails/automations/{id}/active":{"post":{"operationId":"POST /v1/emails/automations/{id}/active","summary":"Turns an email automation on or off.","tags":["emails"],"x-feature":"emails","x-action":"update","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"active":{"type":"boolean"}},"required":["active"]}}}},"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"activatedAt":{"format":"date-time","type":"string"},"active":{"type":"boolean"},"createdAt":{"format":"date-time","type":"string"},"createdBy":{"format":"uuid","type":"string"},"delayMinutes":{"type":"integer"},"domainId":{"type":"null"},"fromLocal":{"type":"null"},"fromName":{"type":"null"},"id":{"format":"uuid","type":"string"},"kind":{"type":"string"},"name":{"type":"string"},"organizationId":{"format":"uuid","type":"string"},"replyTo":{"type":"null"},"templateId":{"format":"uuid","type":"string"},"trigger":{"properties":{"formId":{"type":"null"},"listId":{"format":"uuid","type":"string"},"type":{"type":"string"}},"required":["type","formId","listId"],"type":"object"},"updatedAt":{"format":"date-time","type":"string"}},"required":["id","organizationId","name","active","kind","trigger","delayMinutes","templateId","domainId","fromName","fromLocal","replyTo","activatedAt","createdBy","createdAt","updatedAt"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/emails/campaigns":{"get":{"operationId":"GET /v1/emails/campaigns","summary":"Lists the email campaigns.","tags":["emails"],"x-feature":"emails","x-action":"read","responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"post":{"operationId":"POST /v1/emails/campaigns","summary":"Creates a campaign draft: template, audience and subject.","tags":["emails"],"x-feature":"emails","x-action":"create","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"name":{"type":"string","minLength":1,"maxLength":120},"templateId":{"anyOf":[{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},{"type":"null"}]},"subject":{"default":"","type":"string","maxLength":300},"preheader":{"default":"","type":"string","maxLength":300},"audience":{"type":"object","properties":{"listIds":{"default":[],"maxItems":50,"type":"array","items":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"}},"tagIds":{"default":[],"maxItems":50,"type":"array","items":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"}},"excludeListIds":{"default":[],"maxItems":50,"type":"array","items":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"}}}},"domainId":{"anyOf":[{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},{"type":"null"}]},"fromName":{"anyOf":[{"type":"string","maxLength":100},{"type":"null"}]},"fromLocal":{"anyOf":[{"type":"string","pattern":"^[a-z0-9](?:[a-z0-9._+-]{0,62}[a-z0-9])?$"},{"type":"null"}]},"replyTo":{"anyOf":[{"type":"string","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,}$"},{"type":"null"}]}},"required":["name"]}}}},"responses":{"201":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"audience":{"properties":{"excludeListIds":{"type":"array"},"listIds":{"items":{"format":"uuid","type":"string"},"type":"array"},"tagIds":{"type":"array"}},"required":["tagIds","listIds","excludeListIds"],"type":"object"},"createdAt":{"format":"date-time","type":"string"},"createdBy":{"format":"uuid","type":"string"},"domainId":{"type":"null"},"error":{"type":"null"},"finishedAt":{"type":"null"},"fromLocal":{"type":"null"},"fromName":{"type":"null"},"id":{"format":"uuid","type":"string"},"name":{"type":"string"},"organizationId":{"format":"uuid","type":"string"},"preheader":{"type":"string"},"recipients":{"type":"integer"},"replyTo":{"type":"null"},"scheduledAt":{"type":"null"},"startedAt":{"type":"null"},"stats":{"properties":{"bounced":{"type":"integer"},"clicked":{"type":"integer"},"complained":{"type":"integer"},"delivered":{"type":"integer"},"failed":{"type":"integer"},"opened":{"type":"integer"},"queued":{"type":"integer"},"sent":{"type":"integer"},"unsubscribed":{"type":"integer"}},"required":["queued","sent","delivered","opened","clicked","bounced","complained","unsubscribed","failed"],"type":"object"},"status":{"type":"string"},"subject":{"type":"string"},"templateId":{"format":"uuid","type":"string"},"updatedAt":{"format":"date-time","type":"string"}},"required":["id","organizationId","name","status","templateId","subject","preheader","domainId","fromName","fromLocal","replyTo","audience","scheduledAt","startedAt","finishedAt","recipients","error","createdBy","createdAt","updatedAt","stats"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/emails/campaigns/{id}":{"delete":{"operationId":"DELETE /v1/emails/campaigns/{id}","summary":"Deletes a campaign; one being sent must be canceled first.","tags":["emails"],"x-feature":"emails","x-action":"delete","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"204":{"description":"Done, with no content."},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"get":{"operationId":"GET /v1/emails/campaigns/{id}","summary":"Returns a campaign with its numbers.","tags":["emails"],"x-feature":"emails","x-action":"read","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"audience":{"properties":{"excludeListIds":{"type":"array"},"listIds":{"items":{"format":"uuid","type":"string"},"type":"array"},"tagIds":{"type":"array"}},"required":["tagIds","listIds","excludeListIds"],"type":"object"},"createdAt":{"format":"date-time","type":"string"},"createdBy":{"format":"uuid","type":"string"},"domainId":{"format":"uuid","type":"string"},"error":{"type":"null"},"finishedAt":{"format":"date-time","type":["null","string"]},"fromLocal":{"type":"string"},"fromName":{"type":"string"},"id":{"format":"uuid","type":"string"},"name":{"type":"string"},"organizationId":{"format":"uuid","type":"string"},"preheader":{"type":"string"},"recipients":{"type":"integer"},"replyTo":{"type":"null"},"scheduledAt":{"format":"date-time","type":["null","string"]},"startedAt":{"format":"date-time","type":["null","string"]},"stats":{"properties":{"bounced":{"type":"integer"},"clicked":{"type":"integer"},"complained":{"type":"integer"},"delivered":{"type":"integer"},"failed":{"type":"integer"},"opened":{"type":"integer"},"queued":{"type":"integer"},"sent":{"type":"integer"},"unsubscribed":{"type":"integer"}},"required":["queued","sent","delivered","opened","clicked","bounced","complained","unsubscribed","failed"],"type":"object"},"status":{"type":"string"},"subject":{"type":"string"},"templateId":{"format":"uuid","type":"string"},"updatedAt":{"format":"date-time","type":"string"}},"required":["id","organizationId","name","status","templateId","subject","preheader","domainId","fromName","fromLocal","replyTo","audience","scheduledAt","startedAt","finishedAt","recipients","error","createdBy","createdAt","updatedAt","stats"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"patch":{"operationId":"PATCH /v1/emails/campaigns/{id}","summary":"Changes a campaign draft.","tags":["emails"],"x-feature":"emails","x-action":"update","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"name":{"type":"string","minLength":1,"maxLength":120},"templateId":{"anyOf":[{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},{"type":"null"}]},"subject":{"type":"string","maxLength":300},"preheader":{"type":"string","maxLength":300},"audience":{"type":"object","properties":{"listIds":{"default":[],"maxItems":50,"type":"array","items":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"}},"tagIds":{"default":[],"maxItems":50,"type":"array","items":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"}},"excludeListIds":{"default":[],"maxItems":50,"type":"array","items":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"}}}},"domainId":{"anyOf":[{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},{"type":"null"}]},"fromName":{"anyOf":[{"type":"string","maxLength":100},{"type":"null"}]},"fromLocal":{"anyOf":[{"type":"string","pattern":"^[a-z0-9](?:[a-z0-9._+-]{0,62}[a-z0-9])?$"},{"type":"null"}]},"replyTo":{"anyOf":[{"type":"string","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,}$"},{"type":"null"}]}}}}}},"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/emails/campaigns/{id}/cancel":{"post":{"operationId":"POST /v1/emails/campaigns/{id}/cancel","summary":"Cancels a scheduled campaign, or stops one being sent.","tags":["emails"],"x-feature":"emails","x-action":"update","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/emails/campaigns/{id}/duplicate":{"post":{"operationId":"POST /v1/emails/campaigns/{id}/duplicate","summary":"A new draft with the same content and audience.","tags":["emails"],"x-feature":"emails","x-action":"create","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"name":{"type":"string","minLength":1,"maxLength":120}},"required":["name"]}}}},"responses":{"201":{"description":"Success.","content":{"application/json":{"schema":{}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/emails/campaigns/{id}/recipients":{"get":{"operationId":"GET /v1/emails/campaigns/{id}/recipients","summary":"A campaign’s recipients, with what happened to each email.","tags":["emails"],"x-feature":"emails","x-action":"read","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}},{"name":"page","in":"query","required":false,"schema":{"default":1,"type":"integer","minimum":1,"maximum":9007199254740991}},{"name":"status","in":"query","required":false,"schema":{"type":"string","maxLength":20}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/emails/campaigns/{id}/schedule":{"post":{"operationId":"POST /v1/emails/campaigns/{id}/schedule","summary":"Schedules the campaign for a time, or sends it now.","tags":["emails"],"x-feature":"emails","x-action":"update","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"at":{"anyOf":[{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"},{"type":"null"}]}}}}}},"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"audience":{"properties":{"excludeListIds":{"type":"array"},"listIds":{"items":{"format":"uuid","type":"string"},"type":"array"},"tagIds":{"type":"array"}},"required":["tagIds","listIds","excludeListIds"],"type":"object"},"createdAt":{"format":"date-time","type":"string"},"createdBy":{"format":"uuid","type":"string"},"domainId":{"format":"uuid","type":"string"},"error":{"type":"null"},"finishedAt":{"format":"date-time","type":"string"},"fromLocal":{"type":"string"},"fromName":{"type":"string"},"id":{"format":"uuid","type":"string"},"name":{"type":"string"},"organizationId":{"format":"uuid","type":"string"},"preheader":{"type":"string"},"recipients":{"type":"integer"},"replyTo":{"type":"null"},"scheduledAt":{"format":"date-time","type":"string"},"startedAt":{"format":"date-time","type":"string"},"stats":{"properties":{"bounced":{"type":"integer"},"clicked":{"type":"integer"},"complained":{"type":"integer"},"delivered":{"type":"integer"},"failed":{"type":"integer"},"opened":{"type":"integer"},"queued":{"type":"integer"},"sent":{"type":"integer"},"unsubscribed":{"type":"integer"}},"required":["queued","sent","delivered","opened","clicked","bounced","complained","unsubscribed","failed"],"type":"object"},"status":{"type":"string"},"subject":{"type":"string"},"templateId":{"format":"uuid","type":"string"},"updatedAt":{"format":"date-time","type":"string"}},"required":["id","organizationId","name","status","templateId","subject","preheader","domainId","fromName","fromLocal","replyTo","audience","scheduledAt","startedAt","finishedAt","recipients","error","createdBy","createdAt","updatedAt","stats"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/emails/campaigns/audience":{"post":{"operationId":"POST /v1/emails/campaigns/audience","summary":"How many contacts an audience reaches now (with consent, address not suppressed).","tags":["emails"],"x-feature":"emails","x-action":"read","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"listIds":{"default":[],"maxItems":50,"type":"array","items":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"}},"tagIds":{"default":[],"maxItems":50,"type":"array","items":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"}},"excludeListIds":{"default":[],"maxItems":50,"type":"array","items":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"}}}}}}},"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"recipients":{"type":"integer"}},"required":["recipients"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/emails/catalog":{"get":{"operationId":"GET /v1/emails/catalog","summary":"Searches the services, products and packages a catalog block can show.","tags":["emails"],"x-feature":"emails","x-action":"read","parameters":[{"name":"q","in":"query","required":false,"schema":{"type":"string","maxLength":200}},{"name":"kind","in":"query","required":false,"schema":{"type":"string","enum":["service","product","package"]}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"data":{"items":{"properties":{"currency":{"type":"string"},"description":{"type":"string"},"id":{"format":"uuid","type":"string"},"image":{"format":"uri","type":"string"},"itemKind":{"type":"string"},"kind":{"type":"string"},"name":{"type":"string"},"prices":{"properties":{"BRL":{"properties":{"original":{"type":"null"},"price":{"type":"integer"}},"required":["price","original"],"type":"object"}},"required":["BRL"],"type":"object"},"thumbnail":{"format":"uri","type":"string"},"url":{"format":"uri","type":"string"}},"required":["kind","id","itemKind","name","description","image","thumbnail","currency","prices","url"],"type":"object"},"type":"array"}},"required":["data"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/emails/catalog/cards":{"post":{"operationId":"POST /v1/emails/catalog/cards","summary":"The cards of some catalog items as emails show them.","tags":["emails"],"x-feature":"emails","x-action":"read","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"items":{"maxItems":50,"type":"array","items":{"type":"object","properties":{"kind":{"type":"string","enum":["service","package"]},"id":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"}},"required":["kind","id"]}}},"required":["items"]}}}},"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"data":{"items":{"properties":{"currency":{"type":"string"},"description":{"type":"string"},"id":{"format":"uuid","type":"string"},"image":{"type":"null"},"itemKind":{"type":"null"},"kind":{"type":"string"},"name":{"type":"string"},"prices":{"properties":{"BRL":{"properties":{"original":{"type":"integer"},"price":{"type":"integer"}},"required":["price","original"],"type":"object"}},"required":["BRL"],"type":"object"},"thumbnail":{"type":"null"},"url":{"type":"null"}},"required":["kind","id","itemKind","name","description","image","thumbnail","currency","prices","url"],"type":"object"},"type":"array"}},"required":["data"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/emails/images":{"post":{"operationId":"POST /v1/emails/images","summary":"Uploads an image for emails to the file library.","tags":["emails"],"x-feature":"emails","x-action":"create","requestBody":{"required":true,"content":{"multipart/form-data":{"schema":{"type":"object","required":["file"],"properties":{"file":{"type":"string","format":"binary"}}}}}},"responses":{"201":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"bytes":{"type":"integer"},"contentType":{"type":"string"},"createdAt":{"format":"date-time","type":"string"},"deletable":{"type":"boolean"},"group":{"type":"string"},"id":{"format":"uuid","type":"string"},"key":{"type":"string"},"name":{"type":"string"},"owner":{"type":"null"},"updatedAt":{"format":"date-time","type":"string"},"url":{"format":"uri","type":"string"},"usedIn":{"type":"array"}},"required":["id","key","name","group","contentType","bytes","url","deletable","owner","usedIn","createdAt","updatedAt"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/emails/preview":{"post":{"operationId":"POST /v1/emails/preview","summary":"Renders an email document as HTML and text, optionally with a contact’s values.","tags":["emails"],"x-feature":"emails","x-action":"read","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"document":{"type":"object","properties":{"version":{"default":1,"type":"number","const":1},"settings":{"default":{"backdropColor":"#f4f4f5","contentColor":"#ffffff","width":600,"fontFamily":"Arial","headingFontFamily":"Arial","fontSize":16,"lineHeight":1.5,"textColor":"#1f2937","headingColor":"#111827","linkColor":"#2563eb","primaryColor":"#2563eb","onPrimaryColor":"#ffffff","radius":0,"outerPadding":24},"type":"object","properties":{"backdropColor":{"default":"#f4f4f5","type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"contentColor":{"default":"#ffffff","type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"width":{"default":600,"type":"integer","minimum":320,"maximum":900},"fontFamily":{"default":"Arial","type":"string","maxLength":60},"headingFontFamily":{"default":"Arial","type":"string","maxLength":60},"fontSize":{"default":16,"type":"integer","minimum":0,"maximum":40},"lineHeight":{"default":1.5,"type":"number","minimum":0.8,"maximum":3},"textColor":{"default":"#1f2937","type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"headingColor":{"default":"#111827","type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"linkColor":{"default":"#2563eb","type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"primaryColor":{"default":"#2563eb","type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"onPrimaryColor":{"default":"#ffffff","type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"radius":{"default":0,"type":"integer","minimum":0,"maximum":40},"outerPadding":{"default":24,"type":"integer","minimum":0,"maximum":120}}},"header":{"default":{"show":true,"placement":"outside","color":null,"linkColor":null,"backgroundColor":null,"fontSize":12,"padding":{"top":12,"right":25,"bottom":12,"left":25},"presetId":null,"custom":null},"type":"object","properties":{"show":{"default":true,"type":"boolean"},"placement":{"default":"outside","type":"string","enum":["inside","outside"]},"color":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"linkColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"backgroundColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"fontSize":{"default":12,"type":"integer","minimum":0,"maximum":24},"padding":{"default":{"top":12,"right":25,"bottom":12,"left":25},"type":"object","properties":{"top":{"type":"integer","minimum":0,"maximum":200},"right":{"type":"integer","minimum":0,"maximum":200},"bottom":{"type":"integer","minimum":0,"maximum":200},"left":{"type":"integer","minimum":0,"maximum":200}},"required":["top","right","bottom","left"]},"presetId":{"default":null,"anyOf":[{"type":"string","maxLength":40},{"type":"null"}]},"custom":{"default":null,"anyOf":[{"type":"object","properties":{"text":{"default":"","type":"string","maxLength":300},"linkLabel":{"default":"","type":"string","maxLength":60}}},{"type":"null"}]}}},"footer":{"default":{"placement":"inside","color":null,"linkColor":null,"backgroundColor":null,"fontSize":12,"padding":{"top":12,"right":25,"bottom":12,"left":25},"align":"center","presetId":null,"custom":null},"type":"object","properties":{"placement":{"default":"inside","type":"string","enum":["inside","outside"]},"color":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"linkColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"backgroundColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"fontSize":{"default":12,"type":"integer","minimum":0,"maximum":24},"padding":{"default":{"top":12,"right":25,"bottom":12,"left":25},"type":"object","properties":{"top":{"type":"integer","minimum":0,"maximum":200},"right":{"type":"integer","minimum":0,"maximum":200},"bottom":{"type":"integer","minimum":0,"maximum":200},"left":{"type":"integer","minimum":0,"maximum":200}},"required":["top","right","bottom","left"]},"align":{"default":"center","type":"string","enum":["left","center","right"]},"presetId":{"default":null,"anyOf":[{"type":"string","maxLength":40},{"type":"null"}]},"custom":{"default":null,"anyOf":[{"type":"object","properties":{"html":{"default":"","type":"string","maxLength":50000},"unsubscribeLabel":{"type":"string","minLength":1,"maxLength":100},"showAddress":{"default":true,"type":"boolean"}},"required":["unsubscribeLabel"]},{"type":"null"}]}}},"rows":{"maxItems":100,"type":"array","items":{"type":"object","properties":{"id":{"type":"string","minLength":1,"maxLength":40},"columns":{"minItems":1,"maxItems":4,"type":"array","items":{"type":"object","properties":{"id":{"type":"string","minLength":1,"maxLength":40},"blocks":{"maxItems":60,"type":"array","items":{"oneOf":[{"type":"object","properties":{"type":{"type":"string","const":"heading"},"id":{"type":"string","minLength":1,"maxLength":40},"padding":{"default":{"top":10,"right":25,"bottom":10,"left":25},"type":"object","properties":{"top":{"type":"integer","minimum":0,"maximum":200},"right":{"type":"integer","minimum":0,"maximum":200},"bottom":{"type":"integer","minimum":0,"maximum":200},"left":{"type":"integer","minimum":0,"maximum":200}},"required":["top","right","bottom","left"]},"backgroundColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"hideOn":{"default":null,"anyOf":[{"type":"string","enum":["mobile","desktop"]},{"type":"null"}]},"fontFamily":{"default":null,"anyOf":[{"type":"string","maxLength":60,"pattern":"^[\\p{L}\\p{N} '-]+$"},{"type":"null"}]},"fontSize":{"default":null,"anyOf":[{"type":"integer","minimum":0,"maximum":96},{"type":"null"}]},"color":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"lineHeight":{"default":null,"anyOf":[{"type":"number","minimum":0.8,"maximum":3},{"type":"null"}]},"letterSpacing":{"default":0,"type":"number","minimum":-5,"maximum":20},"align":{"default":"left","type":"string","enum":["left","center","right"]},"html":{"type":"string","maxLength":50000},"level":{"default":1,"anyOf":[{"type":"number","const":1},{"type":"number","const":2},{"type":"number","const":3}]},"fontWeight":{"default":700,"type":"integer","minimum":100,"maximum":900}},"required":["type","id","html"]},{"type":"object","properties":{"type":{"type":"string","const":"text"},"id":{"type":"string","minLength":1,"maxLength":40},"padding":{"default":{"top":10,"right":25,"bottom":10,"left":25},"type":"object","properties":{"top":{"type":"integer","minimum":0,"maximum":200},"right":{"type":"integer","minimum":0,"maximum":200},"bottom":{"type":"integer","minimum":0,"maximum":200},"left":{"type":"integer","minimum":0,"maximum":200}},"required":["top","right","bottom","left"]},"backgroundColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"hideOn":{"default":null,"anyOf":[{"type":"string","enum":["mobile","desktop"]},{"type":"null"}]},"fontFamily":{"default":null,"anyOf":[{"type":"string","maxLength":60,"pattern":"^[\\p{L}\\p{N} '-]+$"},{"type":"null"}]},"fontSize":{"default":null,"anyOf":[{"type":"integer","minimum":0,"maximum":96},{"type":"null"}]},"color":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"lineHeight":{"default":null,"anyOf":[{"type":"number","minimum":0.8,"maximum":3},{"type":"null"}]},"letterSpacing":{"default":0,"type":"number","minimum":-5,"maximum":20},"align":{"default":"left","type":"string","enum":["left","center","right"]},"html":{"type":"string","maxLength":50000}},"required":["type","id","html"]},{"type":"object","properties":{"type":{"type":"string","const":"button"},"id":{"type":"string","minLength":1,"maxLength":40},"padding":{"default":{"top":10,"right":25,"bottom":10,"left":25},"type":"object","properties":{"top":{"type":"integer","minimum":0,"maximum":200},"right":{"type":"integer","minimum":0,"maximum":200},"bottom":{"type":"integer","minimum":0,"maximum":200},"left":{"type":"integer","minimum":0,"maximum":200}},"required":["top","right","bottom","left"]},"backgroundColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"hideOn":{"default":null,"anyOf":[{"type":"string","enum":["mobile","desktop"]},{"type":"null"}]},"label":{"type":"string","maxLength":200},"url":{"type":"string","maxLength":2000},"align":{"default":"center","type":"string","enum":["left","center","right"]},"buttonColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"textColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"fontFamily":{"default":null,"anyOf":[{"type":"string","maxLength":60,"pattern":"^[\\p{L}\\p{N} '-]+$"},{"type":"null"}]},"fontSize":{"default":16,"type":"integer","minimum":0,"maximum":48},"fontWeight":{"default":600,"type":"integer","minimum":100,"maximum":900},"radius":{"default":6,"type":"integer","minimum":0,"maximum":100},"innerPadding":{"default":{"vertical":12,"horizontal":24},"type":"object","properties":{"vertical":{"type":"integer","minimum":0,"maximum":60},"horizontal":{"type":"integer","minimum":0,"maximum":120}},"required":["vertical","horizontal"]},"borderColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"borderWidth":{"default":0,"type":"integer","minimum":0,"maximum":10},"fullWidth":{"default":false,"type":"boolean"}},"required":["type","id","label","url"]},{"type":"object","properties":{"type":{"type":"string","const":"image"},"id":{"type":"string","minLength":1,"maxLength":40},"padding":{"default":{"top":10,"right":25,"bottom":10,"left":25},"type":"object","properties":{"top":{"type":"integer","minimum":0,"maximum":200},"right":{"type":"integer","minimum":0,"maximum":200},"bottom":{"type":"integer","minimum":0,"maximum":200},"left":{"type":"integer","minimum":0,"maximum":200}},"required":["top","right","bottom","left"]},"backgroundColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"hideOn":{"default":null,"anyOf":[{"type":"string","enum":["mobile","desktop"]},{"type":"null"}]},"src":{"type":"string","maxLength":2000},"alt":{"default":"","type":"string","maxLength":300},"url":{"default":"","type":"string","maxLength":2000},"width":{"default":100,"type":"integer","minimum":5,"maximum":100},"align":{"default":"center","type":"string","enum":["left","center","right"]},"radius":{"default":0,"type":"integer","minimum":0,"maximum":200}},"required":["type","id","src"]},{"type":"object","properties":{"type":{"type":"string","const":"divider"},"id":{"type":"string","minLength":1,"maxLength":40},"padding":{"default":{"top":10,"right":25,"bottom":10,"left":25},"type":"object","properties":{"top":{"type":"integer","minimum":0,"maximum":200},"right":{"type":"integer","minimum":0,"maximum":200},"bottom":{"type":"integer","minimum":0,"maximum":200},"left":{"type":"integer","minimum":0,"maximum":200}},"required":["top","right","bottom","left"]},"backgroundColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"hideOn":{"default":null,"anyOf":[{"type":"string","enum":["mobile","desktop"]},{"type":"null"}]},"color":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"thickness":{"default":1,"type":"integer","minimum":0,"maximum":20},"style":{"default":"solid","type":"string","enum":["solid","dashed","dotted"]},"width":{"default":100,"type":"integer","minimum":5,"maximum":100},"align":{"default":"center","type":"string","enum":["left","center","right"]}},"required":["type","id"]},{"type":"object","properties":{"type":{"type":"string","const":"spacer"},"id":{"type":"string","minLength":1,"maxLength":40},"padding":{"default":{"top":10,"right":25,"bottom":10,"left":25},"type":"object","properties":{"top":{"type":"integer","minimum":0,"maximum":200},"right":{"type":"integer","minimum":0,"maximum":200},"bottom":{"type":"integer","minimum":0,"maximum":200},"left":{"type":"integer","minimum":0,"maximum":200}},"required":["top","right","bottom","left"]},"backgroundColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"hideOn":{"default":null,"anyOf":[{"type":"string","enum":["mobile","desktop"]},{"type":"null"}]},"height":{"default":24,"type":"integer","minimum":0,"maximum":400}},"required":["type","id"]},{"type":"object","properties":{"type":{"type":"string","const":"social"},"id":{"type":"string","minLength":1,"maxLength":40},"padding":{"default":{"top":10,"right":25,"bottom":10,"left":25},"type":"object","properties":{"top":{"type":"integer","minimum":0,"maximum":200},"right":{"type":"integer","minimum":0,"maximum":200},"bottom":{"type":"integer","minimum":0,"maximum":200},"left":{"type":"integer","minimum":0,"maximum":200}},"required":["top","right","bottom","left"]},"backgroundColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"hideOn":{"default":null,"anyOf":[{"type":"string","enum":["mobile","desktop"]},{"type":"null"}]},"links":{"maxItems":10,"type":"array","items":{"type":"object","properties":{"network":{"type":"string","enum":["facebook","instagram","linkedin","x","youtube","tiktok","whatsapp","threads","discord","pinterest","github","phone","web"]},"url":{"type":"string","maxLength":2000}},"required":["network","url"]}},"iconSize":{"default":28,"type":"integer","minimum":0,"maximum":64},"gap":{"default":8,"type":"integer","minimum":0,"maximum":40},"iconStyle":{"default":"filled","type":"string","enum":["filled","plain"]},"iconColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"iconRadius":{"default":4,"type":"integer","minimum":0,"maximum":32},"align":{"default":"center","type":"string","enum":["left","center","right"]}},"required":["type","id","links"]},{"type":"object","properties":{"type":{"type":"string","const":"html"},"id":{"type":"string","minLength":1,"maxLength":40},"padding":{"default":{"top":10,"right":25,"bottom":10,"left":25},"type":"object","properties":{"top":{"type":"integer","minimum":0,"maximum":200},"right":{"type":"integer","minimum":0,"maximum":200},"bottom":{"type":"integer","minimum":0,"maximum":200},"left":{"type":"integer","minimum":0,"maximum":200}},"required":["top","right","bottom","left"]},"backgroundColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"hideOn":{"default":null,"anyOf":[{"type":"string","enum":["mobile","desktop"]},{"type":"null"}]},"html":{"type":"string","maxLength":100000}},"required":["type","id","html"]},{"type":"object","properties":{"type":{"type":"string","const":"catalog"},"id":{"type":"string","minLength":1,"maxLength":40},"padding":{"default":{"top":10,"right":25,"bottom":10,"left":25},"type":"object","properties":{"top":{"type":"integer","minimum":0,"maximum":200},"right":{"type":"integer","minimum":0,"maximum":200},"bottom":{"type":"integer","minimum":0,"maximum":200},"left":{"type":"integer","minimum":0,"maximum":200}},"required":["top","right","bottom","left"]},"backgroundColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"hideOn":{"default":null,"anyOf":[{"type":"string","enum":["mobile","desktop"]},{"type":"null"}]},"items":{"maxItems":12,"type":"array","items":{"type":"object","properties":{"kind":{"type":"string","enum":["service","package"]},"id":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},"url":{"default":"","type":"string","maxLength":2000}},"required":["kind","id"]}},"layout":{"default":"grid","type":"string","enum":["grid","list"]},"columns":{"default":2,"anyOf":[{"type":"number","const":1},{"type":"number","const":2},{"type":"number","const":3}]},"gap":{"default":16,"type":"integer","minimum":0,"maximum":40},"currency":{"default":null,"anyOf":[{"type":"string","pattern":"^[A-Z]{3}$"},{"type":"null"}]},"textAlign":{"default":"left","type":"string","enum":["left","center","right"]},"fontFamily":{"default":null,"anyOf":[{"type":"string","maxLength":60,"pattern":"^[\\p{L}\\p{N} '-]+$"},{"type":"null"}]},"cardColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"cardBorderColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"cardBorderWidth":{"default":1,"type":"integer","minimum":0,"maximum":10},"cardRadius":{"default":8,"type":"integer","minimum":0,"maximum":40},"cardPadding":{"default":16,"type":"integer","minimum":0,"maximum":60},"showImage":{"default":true,"type":"boolean"},"imageRatio":{"default":"square","type":"string","enum":["square","landscape","portrait","original"]},"imageRadius":{"default":4,"type":"integer","minimum":0,"maximum":40},"nameFontFamily":{"default":null,"anyOf":[{"type":"string","maxLength":60,"pattern":"^[\\p{L}\\p{N} '-]+$"},{"type":"null"}]},"nameFontSize":{"default":18,"type":"integer","minimum":0,"maximum":48},"nameFontWeight":{"default":700,"type":"integer","minimum":100,"maximum":900},"nameColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"showDescription":{"default":true,"type":"boolean"},"descriptionLength":{"default":120,"type":"integer","minimum":20,"maximum":600},"descriptionFontSize":{"default":14,"type":"integer","minimum":0,"maximum":32},"descriptionColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"showPrice":{"default":true,"type":"boolean"},"showOriginalPrice":{"default":true,"type":"boolean"},"priceFontSize":{"default":18,"type":"integer","minimum":0,"maximum":48},"priceFontWeight":{"default":700,"type":"integer","minimum":100,"maximum":900},"priceColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"showButton":{"default":true,"type":"boolean"},"buttonLabel":{"default":"","type":"string","maxLength":80},"buttonUrl":{"default":"","type":"string","maxLength":2000},"linkTo":{"default":"item","type":"string","enum":["item","catalogPage"]},"catalogPageId":{"default":null,"anyOf":[{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},{"type":"null"}]},"buttonColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"buttonTextColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"buttonFontSize":{"default":14,"type":"integer","minimum":0,"maximum":32},"buttonRadius":{"default":6,"type":"integer","minimum":0,"maximum":40},"buttonFullWidth":{"default":true,"type":"boolean"}},"required":["type","id","items"]},{"type":"object","properties":{"type":{"type":"string","const":"card"},"id":{"type":"string","minLength":1,"maxLength":40},"padding":{"default":{"top":10,"right":25,"bottom":10,"left":25},"type":"object","properties":{"top":{"type":"integer","minimum":0,"maximum":200},"right":{"type":"integer","minimum":0,"maximum":200},"bottom":{"type":"integer","minimum":0,"maximum":200},"left":{"type":"integer","minimum":0,"maximum":200}},"required":["top","right","bottom","left"]},"backgroundColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"hideOn":{"default":null,"anyOf":[{"type":"string","enum":["mobile","desktop"]},{"type":"null"}]},"src":{"type":"string","maxLength":2000},"alt":{"default":"","type":"string","maxLength":300},"imagePosition":{"default":"left","type":"string","enum":["top","left","right"]},"imageWidth":{"default":40,"type":"integer","minimum":20,"maximum":70},"imageRatio":{"default":"landscape","type":"string","enum":["original","square","landscape","portrait"]},"imageRadius":{"default":8,"type":"integer","minimum":0,"maximum":200},"imageBleed":{"default":false,"type":"boolean"},"title":{"default":"","type":"string","maxLength":200},"html":{"default":"","type":"string","maxLength":20000},"url":{"default":"","type":"string","maxLength":2000},"titleFontSize":{"default":20,"type":"integer","minimum":10,"maximum":72},"titleColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"textColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"fontFamily":{"default":null,"anyOf":[{"type":"string","maxLength":60,"pattern":"^[\\p{L}\\p{N} '-]+$"},{"type":"null"}]},"textAlign":{"default":"left","type":"string","enum":["left","center","right"]},"verticalAlign":{"default":"middle","type":"string","enum":["top","middle"]},"cardColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"borderColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"borderWidth":{"default":1,"type":"integer","minimum":0,"maximum":10},"radius":{"default":12,"type":"integer","minimum":0,"maximum":60},"cardPadding":{"default":16,"type":"integer","minimum":0,"maximum":80},"gap":{"default":16,"type":"integer","minimum":0,"maximum":80}},"required":["type","id","src"]}]}},"backgroundColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"padding":{"default":{"top":0,"right":0,"bottom":0,"left":0},"type":"object","properties":{"top":{"type":"integer","minimum":0,"maximum":200},"right":{"type":"integer","minimum":0,"maximum":200},"bottom":{"type":"integer","minimum":0,"maximum":200},"left":{"type":"integer","minimum":0,"maximum":200}},"required":["top","right","bottom","left"]},"radius":{"default":0,"type":"integer","minimum":0,"maximum":100},"verticalAlign":{"default":"top","type":"string","enum":["top","middle","bottom"]}},"required":["id","blocks"]}},"widths":{"minItems":1,"maxItems":4,"type":"array","items":{"type":"number","minimum":10,"maximum":100}},"backgroundColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"backgroundImage":{"default":"","type":"string","maxLength":2000},"fullWidth":{"default":false,"type":"boolean"},"padding":{"default":{"top":10,"right":0,"bottom":10,"left":0},"type":"object","properties":{"top":{"type":"integer","minimum":0,"maximum":200},"right":{"type":"integer","minimum":0,"maximum":200},"bottom":{"type":"integer","minimum":0,"maximum":200},"left":{"type":"integer","minimum":0,"maximum":200}},"required":["top","right","bottom","left"]},"radius":{"default":0,"type":"integer","minimum":0,"maximum":100},"borderColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"borderWidth":{"default":0,"type":"integer","minimum":0,"maximum":10},"stackOnMobile":{"default":true,"type":"boolean"},"hideOn":{"default":null,"anyOf":[{"type":"string","enum":["mobile","desktop"]},{"type":"null"}]}},"required":["id","columns","widths"]}}},"required":["rows"]},"subject":{"default":"","type":"string","maxLength":300},"preheader":{"default":"","type":"string","maxLength":300},"kind":{"default":"marketing","type":"string","enum":["marketing","transactional"]},"contactId":{"anyOf":[{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},{"type":"null"}]}},"required":["document"]}}}},"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"html":{"type":"string"},"subject":{"type":"string"},"text":{"type":"string"}},"required":["html","subject","text"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/emails/saved-blocks":{"get":{"operationId":"GET /v1/emails/saved-blocks","summary":"Lists the blocks kept to reuse in templates.","tags":["emails"],"x-feature":"emails","x-action":"read","responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"data":{"items":{"properties":{"block":{"properties":{"align":{"type":"string"},"backgroundColor":{"type":"null"},"borderColor":{"type":"null"},"borderWidth":{"type":"integer"},"buttonColor":{"type":"null"},"fontFamily":{"type":"null"},"fontSize":{"type":"integer"},"fontWeight":{"type":"integer"},"fullWidth":{"type":"boolean"},"hideOn":{"type":"null"},"id":{"type":"string"},"innerPadding":{"properties":{"horizontal":{"type":"integer"},"vertical":{"type":"integer"}},"required":["vertical","horizontal"],"type":"object"},"label":{"type":"string"},"padding":{"properties":{"bottom":{"type":"integer"},"left":{"type":"integer"},"right":{"type":"integer"},"top":{"type":"integer"}},"required":["top","left","right","bottom"],"type":"object"},"radius":{"type":"integer"},"textColor":{"type":"null"},"type":{"type":"string"},"url":{"format":"uri","type":"string"}},"required":["id","url","type","align","label","hideOn","radius","padding","fontSize","fullWidth","textColor","fontFamily","fontWeight","borderColor","borderWidth","buttonColor","innerPadding","backgroundColor"],"type":["null","object"]},"createdAt":{"format":"date-time","type":"string"},"createdBy":{"format":"uuid","type":"string"},"icon":{"type":"string"},"id":{"format":"uuid","type":"string"},"kind":{"type":"string"},"name":{"type":"string"},"row":{"properties":{"backgroundColor":{"type":"null"},"backgroundImage":{"type":"string"},"borderColor":{"type":"null"},"borderWidth":{"type":"integer"},"columns":{"items":{"properties":{"backgroundColor":{"type":"null"},"blocks":{"items":{"properties":{"align":{"type":"string"},"backgroundColor":{"type":"null"},"borderColor":{"type":"null"},"borderWidth":{"type":"integer"},"buttonColor":{"type":"null"},"color":{"type":"null"},"fontFamily":{"type":"null"},"fontSize":{"type":["integer","null"]},"fontWeight":{"type":"integer"},"fullWidth":{"type":"boolean"},"hideOn":{"type":"null"},"html":{"type":"string"},"id":{"type":"string"},"innerPadding":{"properties":{"horizontal":{"type":"integer"},"vertical":{"type":"integer"}},"required":["vertical","horizontal"],"type":"object"},"label":{"type":"string"},"letterSpacing":{"type":"integer"},"lineHeight":{"type":"null"},"padding":{"properties":{"bottom":{"type":"integer"},"left":{"type":"integer"},"right":{"type":"integer"},"top":{"type":"integer"}},"required":["top","left","right","bottom"],"type":"object"},"radius":{"type":"integer"},"textColor":{"type":"null"},"type":{"type":"string"},"url":{"format":"uri","type":"string"}},"required":["id","type","align","hideOn","padding","fontSize","fontFamily","backgroundColor"],"type":"object"},"type":"array"},"id":{"type":"string"},"padding":{"properties":{"bottom":{"type":"integer"},"left":{"type":"integer"},"right":{"type":"integer"},"top":{"type":"integer"}},"required":["top","left","right","bottom"],"type":"object"},"radius":{"type":"integer"},"verticalAlign":{"type":"string"}},"required":["id","blocks","radius","padding","verticalAlign","backgroundColor"],"type":"object"},"type":"array"},"fullWidth":{"type":"boolean"},"hideOn":{"type":"null"},"id":{"type":"string"},"padding":{"properties":{"bottom":{"type":"integer"},"left":{"type":"integer"},"right":{"type":"integer"},"top":{"type":"integer"}},"required":["top","left","right","bottom"],"type":"object"},"radius":{"type":"integer"},"stackOnMobile":{"type":"boolean"},"widths":{"items":{"type":"integer"},"type":"array"}},"required":["id","hideOn","radius","widths","columns","padding","fullWidth","borderColor","borderWidth","stackOnMobile","backgroundColor","backgroundImage"],"type":["null","object"]},"updatedAt":{"format":"date-time","type":"string"}},"required":["id","name","icon","kind","createdBy","createdAt","updatedAt","block","row"],"type":"object"},"type":"array"},"limit":{"type":"integer"}},"required":["data","limit"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"post":{"operationId":"POST /v1/emails/saved-blocks","summary":"Keeps a block to reuse in templates.","tags":["emails"],"x-feature":"emails","x-action":"create","requestBody":{"required":true,"content":{"application/json":{"schema":{"oneOf":[{"type":"object","properties":{"kind":{"default":"block","type":"string","const":"block"},"name":{"type":"string","minLength":1,"maxLength":60},"icon":{"default":"blocks","type":"string","enum":["blocks","star","heart","megaphone","gift","tag","shopping-bag","calendar","image","mail","phone","map-pin","sparkles","zap","users","file-text"]},"block":{"oneOf":[{"type":"object","properties":{"type":{"type":"string","const":"heading"},"id":{"type":"string","minLength":1,"maxLength":40},"padding":{"default":{"top":10,"right":25,"bottom":10,"left":25},"type":"object","properties":{"top":{"type":"integer","minimum":0,"maximum":200},"right":{"type":"integer","minimum":0,"maximum":200},"bottom":{"type":"integer","minimum":0,"maximum":200},"left":{"type":"integer","minimum":0,"maximum":200}},"required":["top","right","bottom","left"]},"backgroundColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"hideOn":{"default":null,"anyOf":[{"type":"string","enum":["mobile","desktop"]},{"type":"null"}]},"fontFamily":{"default":null,"anyOf":[{"type":"string","maxLength":60,"pattern":"^[\\p{L}\\p{N} '-]+$"},{"type":"null"}]},"fontSize":{"default":null,"anyOf":[{"type":"integer","minimum":0,"maximum":96},{"type":"null"}]},"color":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"lineHeight":{"default":null,"anyOf":[{"type":"number","minimum":0.8,"maximum":3},{"type":"null"}]},"letterSpacing":{"default":0,"type":"number","minimum":-5,"maximum":20},"align":{"default":"left","type":"string","enum":["left","center","right"]},"html":{"type":"string","maxLength":50000},"level":{"default":1,"anyOf":[{"type":"number","const":1},{"type":"number","const":2},{"type":"number","const":3}]},"fontWeight":{"default":700,"type":"integer","minimum":100,"maximum":900}},"required":["type","id","html"]},{"type":"object","properties":{"type":{"type":"string","const":"text"},"id":{"type":"string","minLength":1,"maxLength":40},"padding":{"default":{"top":10,"right":25,"bottom":10,"left":25},"type":"object","properties":{"top":{"type":"integer","minimum":0,"maximum":200},"right":{"type":"integer","minimum":0,"maximum":200},"bottom":{"type":"integer","minimum":0,"maximum":200},"left":{"type":"integer","minimum":0,"maximum":200}},"required":["top","right","bottom","left"]},"backgroundColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"hideOn":{"default":null,"anyOf":[{"type":"string","enum":["mobile","desktop"]},{"type":"null"}]},"fontFamily":{"default":null,"anyOf":[{"type":"string","maxLength":60,"pattern":"^[\\p{L}\\p{N} '-]+$"},{"type":"null"}]},"fontSize":{"default":null,"anyOf":[{"type":"integer","minimum":0,"maximum":96},{"type":"null"}]},"color":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"lineHeight":{"default":null,"anyOf":[{"type":"number","minimum":0.8,"maximum":3},{"type":"null"}]},"letterSpacing":{"default":0,"type":"number","minimum":-5,"maximum":20},"align":{"default":"left","type":"string","enum":["left","center","right"]},"html":{"type":"string","maxLength":50000}},"required":["type","id","html"]},{"type":"object","properties":{"type":{"type":"string","const":"button"},"id":{"type":"string","minLength":1,"maxLength":40},"padding":{"default":{"top":10,"right":25,"bottom":10,"left":25},"type":"object","properties":{"top":{"type":"integer","minimum":0,"maximum":200},"right":{"type":"integer","minimum":0,"maximum":200},"bottom":{"type":"integer","minimum":0,"maximum":200},"left":{"type":"integer","minimum":0,"maximum":200}},"required":["top","right","bottom","left"]},"backgroundColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"hideOn":{"default":null,"anyOf":[{"type":"string","enum":["mobile","desktop"]},{"type":"null"}]},"label":{"type":"string","maxLength":200},"url":{"type":"string","maxLength":2000},"align":{"default":"center","type":"string","enum":["left","center","right"]},"buttonColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"textColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"fontFamily":{"default":null,"anyOf":[{"type":"string","maxLength":60,"pattern":"^[\\p{L}\\p{N} '-]+$"},{"type":"null"}]},"fontSize":{"default":16,"type":"integer","minimum":0,"maximum":48},"fontWeight":{"default":600,"type":"integer","minimum":100,"maximum":900},"radius":{"default":6,"type":"integer","minimum":0,"maximum":100},"innerPadding":{"default":{"vertical":12,"horizontal":24},"type":"object","properties":{"vertical":{"type":"integer","minimum":0,"maximum":60},"horizontal":{"type":"integer","minimum":0,"maximum":120}},"required":["vertical","horizontal"]},"borderColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"borderWidth":{"default":0,"type":"integer","minimum":0,"maximum":10},"fullWidth":{"default":false,"type":"boolean"}},"required":["type","id","label","url"]},{"type":"object","properties":{"type":{"type":"string","const":"image"},"id":{"type":"string","minLength":1,"maxLength":40},"padding":{"default":{"top":10,"right":25,"bottom":10,"left":25},"type":"object","properties":{"top":{"type":"integer","minimum":0,"maximum":200},"right":{"type":"integer","minimum":0,"maximum":200},"bottom":{"type":"integer","minimum":0,"maximum":200},"left":{"type":"integer","minimum":0,"maximum":200}},"required":["top","right","bottom","left"]},"backgroundColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"hideOn":{"default":null,"anyOf":[{"type":"string","enum":["mobile","desktop"]},{"type":"null"}]},"src":{"type":"string","maxLength":2000},"alt":{"default":"","type":"string","maxLength":300},"url":{"default":"","type":"string","maxLength":2000},"width":{"default":100,"type":"integer","minimum":5,"maximum":100},"align":{"default":"center","type":"string","enum":["left","center","right"]},"radius":{"default":0,"type":"integer","minimum":0,"maximum":200}},"required":["type","id","src"]},{"type":"object","properties":{"type":{"type":"string","const":"divider"},"id":{"type":"string","minLength":1,"maxLength":40},"padding":{"default":{"top":10,"right":25,"bottom":10,"left":25},"type":"object","properties":{"top":{"type":"integer","minimum":0,"maximum":200},"right":{"type":"integer","minimum":0,"maximum":200},"bottom":{"type":"integer","minimum":0,"maximum":200},"left":{"type":"integer","minimum":0,"maximum":200}},"required":["top","right","bottom","left"]},"backgroundColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"hideOn":{"default":null,"anyOf":[{"type":"string","enum":["mobile","desktop"]},{"type":"null"}]},"color":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"thickness":{"default":1,"type":"integer","minimum":0,"maximum":20},"style":{"default":"solid","type":"string","enum":["solid","dashed","dotted"]},"width":{"default":100,"type":"integer","minimum":5,"maximum":100},"align":{"default":"center","type":"string","enum":["left","center","right"]}},"required":["type","id"]},{"type":"object","properties":{"type":{"type":"string","const":"spacer"},"id":{"type":"string","minLength":1,"maxLength":40},"padding":{"default":{"top":10,"right":25,"bottom":10,"left":25},"type":"object","properties":{"top":{"type":"integer","minimum":0,"maximum":200},"right":{"type":"integer","minimum":0,"maximum":200},"bottom":{"type":"integer","minimum":0,"maximum":200},"left":{"type":"integer","minimum":0,"maximum":200}},"required":["top","right","bottom","left"]},"backgroundColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"hideOn":{"default":null,"anyOf":[{"type":"string","enum":["mobile","desktop"]},{"type":"null"}]},"height":{"default":24,"type":"integer","minimum":0,"maximum":400}},"required":["type","id"]},{"type":"object","properties":{"type":{"type":"string","const":"social"},"id":{"type":"string","minLength":1,"maxLength":40},"padding":{"default":{"top":10,"right":25,"bottom":10,"left":25},"type":"object","properties":{"top":{"type":"integer","minimum":0,"maximum":200},"right":{"type":"integer","minimum":0,"maximum":200},"bottom":{"type":"integer","minimum":0,"maximum":200},"left":{"type":"integer","minimum":0,"maximum":200}},"required":["top","right","bottom","left"]},"backgroundColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"hideOn":{"default":null,"anyOf":[{"type":"string","enum":["mobile","desktop"]},{"type":"null"}]},"links":{"maxItems":10,"type":"array","items":{"type":"object","properties":{"network":{"type":"string","enum":["facebook","instagram","linkedin","x","youtube","tiktok","whatsapp","threads","discord","pinterest","github","phone","web"]},"url":{"type":"string","maxLength":2000}},"required":["network","url"]}},"iconSize":{"default":28,"type":"integer","minimum":0,"maximum":64},"gap":{"default":8,"type":"integer","minimum":0,"maximum":40},"iconStyle":{"default":"filled","type":"string","enum":["filled","plain"]},"iconColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"iconRadius":{"default":4,"type":"integer","minimum":0,"maximum":32},"align":{"default":"center","type":"string","enum":["left","center","right"]}},"required":["type","id","links"]},{"type":"object","properties":{"type":{"type":"string","const":"html"},"id":{"type":"string","minLength":1,"maxLength":40},"padding":{"default":{"top":10,"right":25,"bottom":10,"left":25},"type":"object","properties":{"top":{"type":"integer","minimum":0,"maximum":200},"right":{"type":"integer","minimum":0,"maximum":200},"bottom":{"type":"integer","minimum":0,"maximum":200},"left":{"type":"integer","minimum":0,"maximum":200}},"required":["top","right","bottom","left"]},"backgroundColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"hideOn":{"default":null,"anyOf":[{"type":"string","enum":["mobile","desktop"]},{"type":"null"}]},"html":{"type":"string","maxLength":100000}},"required":["type","id","html"]},{"type":"object","properties":{"type":{"type":"string","const":"catalog"},"id":{"type":"string","minLength":1,"maxLength":40},"padding":{"default":{"top":10,"right":25,"bottom":10,"left":25},"type":"object","properties":{"top":{"type":"integer","minimum":0,"maximum":200},"right":{"type":"integer","minimum":0,"maximum":200},"bottom":{"type":"integer","minimum":0,"maximum":200},"left":{"type":"integer","minimum":0,"maximum":200}},"required":["top","right","bottom","left"]},"backgroundColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"hideOn":{"default":null,"anyOf":[{"type":"string","enum":["mobile","desktop"]},{"type":"null"}]},"items":{"maxItems":12,"type":"array","items":{"type":"object","properties":{"kind":{"type":"string","enum":["service","package"]},"id":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},"url":{"default":"","type":"string","maxLength":2000}},"required":["kind","id"]}},"layout":{"default":"grid","type":"string","enum":["grid","list"]},"columns":{"default":2,"anyOf":[{"type":"number","const":1},{"type":"number","const":2},{"type":"number","const":3}]},"gap":{"default":16,"type":"integer","minimum":0,"maximum":40},"currency":{"default":null,"anyOf":[{"type":"string","pattern":"^[A-Z]{3}$"},{"type":"null"}]},"textAlign":{"default":"left","type":"string","enum":["left","center","right"]},"fontFamily":{"default":null,"anyOf":[{"type":"string","maxLength":60,"pattern":"^[\\p{L}\\p{N} '-]+$"},{"type":"null"}]},"cardColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"cardBorderColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"cardBorderWidth":{"default":1,"type":"integer","minimum":0,"maximum":10},"cardRadius":{"default":8,"type":"integer","minimum":0,"maximum":40},"cardPadding":{"default":16,"type":"integer","minimum":0,"maximum":60},"showImage":{"default":true,"type":"boolean"},"imageRatio":{"default":"square","type":"string","enum":["square","landscape","portrait","original"]},"imageRadius":{"default":4,"type":"integer","minimum":0,"maximum":40},"nameFontFamily":{"default":null,"anyOf":[{"type":"string","maxLength":60,"pattern":"^[\\p{L}\\p{N} '-]+$"},{"type":"null"}]},"nameFontSize":{"default":18,"type":"integer","minimum":0,"maximum":48},"nameFontWeight":{"default":700,"type":"integer","minimum":100,"maximum":900},"nameColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"showDescription":{"default":true,"type":"boolean"},"descriptionLength":{"default":120,"type":"integer","minimum":20,"maximum":600},"descriptionFontSize":{"default":14,"type":"integer","minimum":0,"maximum":32},"descriptionColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"showPrice":{"default":true,"type":"boolean"},"showOriginalPrice":{"default":true,"type":"boolean"},"priceFontSize":{"default":18,"type":"integer","minimum":0,"maximum":48},"priceFontWeight":{"default":700,"type":"integer","minimum":100,"maximum":900},"priceColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"showButton":{"default":true,"type":"boolean"},"buttonLabel":{"default":"","type":"string","maxLength":80},"buttonUrl":{"default":"","type":"string","maxLength":2000},"linkTo":{"default":"item","type":"string","enum":["item","catalogPage"]},"catalogPageId":{"default":null,"anyOf":[{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},{"type":"null"}]},"buttonColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"buttonTextColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"buttonFontSize":{"default":14,"type":"integer","minimum":0,"maximum":32},"buttonRadius":{"default":6,"type":"integer","minimum":0,"maximum":40},"buttonFullWidth":{"default":true,"type":"boolean"}},"required":["type","id","items"]},{"type":"object","properties":{"type":{"type":"string","const":"card"},"id":{"type":"string","minLength":1,"maxLength":40},"padding":{"default":{"top":10,"right":25,"bottom":10,"left":25},"type":"object","properties":{"top":{"type":"integer","minimum":0,"maximum":200},"right":{"type":"integer","minimum":0,"maximum":200},"bottom":{"type":"integer","minimum":0,"maximum":200},"left":{"type":"integer","minimum":0,"maximum":200}},"required":["top","right","bottom","left"]},"backgroundColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"hideOn":{"default":null,"anyOf":[{"type":"string","enum":["mobile","desktop"]},{"type":"null"}]},"src":{"type":"string","maxLength":2000},"alt":{"default":"","type":"string","maxLength":300},"imagePosition":{"default":"left","type":"string","enum":["top","left","right"]},"imageWidth":{"default":40,"type":"integer","minimum":20,"maximum":70},"imageRatio":{"default":"landscape","type":"string","enum":["original","square","landscape","portrait"]},"imageRadius":{"default":8,"type":"integer","minimum":0,"maximum":200},"imageBleed":{"default":false,"type":"boolean"},"title":{"default":"","type":"string","maxLength":200},"html":{"default":"","type":"string","maxLength":20000},"url":{"default":"","type":"string","maxLength":2000},"titleFontSize":{"default":20,"type":"integer","minimum":10,"maximum":72},"titleColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"textColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"fontFamily":{"default":null,"anyOf":[{"type":"string","maxLength":60,"pattern":"^[\\p{L}\\p{N} '-]+$"},{"type":"null"}]},"textAlign":{"default":"left","type":"string","enum":["left","center","right"]},"verticalAlign":{"default":"middle","type":"string","enum":["top","middle"]},"cardColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"borderColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"borderWidth":{"default":1,"type":"integer","minimum":0,"maximum":10},"radius":{"default":12,"type":"integer","minimum":0,"maximum":60},"cardPadding":{"default":16,"type":"integer","minimum":0,"maximum":80},"gap":{"default":16,"type":"integer","minimum":0,"maximum":80}},"required":["type","id","src"]}]}},"required":["name","block"]},{"type":"object","properties":{"kind":{"type":"string","const":"row"},"name":{"type":"string","minLength":1,"maxLength":60},"icon":{"default":"blocks","type":"string","enum":["blocks","star","heart","megaphone","gift","tag","shopping-bag","calendar","image","mail","phone","map-pin","sparkles","zap","users","file-text"]},"row":{"type":"object","properties":{"id":{"type":"string","minLength":1,"maxLength":40},"columns":{"minItems":1,"maxItems":4,"type":"array","items":{"type":"object","properties":{"id":{"type":"string","minLength":1,"maxLength":40},"blocks":{"maxItems":60,"type":"array","items":{"oneOf":[{"type":"object","properties":{"type":{"type":"string","const":"heading"},"id":{"type":"string","minLength":1,"maxLength":40},"padding":{"default":{"top":10,"right":25,"bottom":10,"left":25},"type":"object","properties":{"top":{"type":"integer","minimum":0,"maximum":200},"right":{"type":"integer","minimum":0,"maximum":200},"bottom":{"type":"integer","minimum":0,"maximum":200},"left":{"type":"integer","minimum":0,"maximum":200}},"required":["top","right","bottom","left"]},"backgroundColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"hideOn":{"default":null,"anyOf":[{"type":"string","enum":["mobile","desktop"]},{"type":"null"}]},"fontFamily":{"default":null,"anyOf":[{"type":"string","maxLength":60,"pattern":"^[\\p{L}\\p{N} '-]+$"},{"type":"null"}]},"fontSize":{"default":null,"anyOf":[{"type":"integer","minimum":0,"maximum":96},{"type":"null"}]},"color":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"lineHeight":{"default":null,"anyOf":[{"type":"number","minimum":0.8,"maximum":3},{"type":"null"}]},"letterSpacing":{"default":0,"type":"number","minimum":-5,"maximum":20},"align":{"default":"left","type":"string","enum":["left","center","right"]},"html":{"type":"string","maxLength":50000},"level":{"default":1,"anyOf":[{"type":"number","const":1},{"type":"number","const":2},{"type":"number","const":3}]},"fontWeight":{"default":700,"type":"integer","minimum":100,"maximum":900}},"required":["type","id","html"]},{"type":"object","properties":{"type":{"type":"string","const":"text"},"id":{"type":"string","minLength":1,"maxLength":40},"padding":{"default":{"top":10,"right":25,"bottom":10,"left":25},"type":"object","properties":{"top":{"type":"integer","minimum":0,"maximum":200},"right":{"type":"integer","minimum":0,"maximum":200},"bottom":{"type":"integer","minimum":0,"maximum":200},"left":{"type":"integer","minimum":0,"maximum":200}},"required":["top","right","bottom","left"]},"backgroundColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"hideOn":{"default":null,"anyOf":[{"type":"string","enum":["mobile","desktop"]},{"type":"null"}]},"fontFamily":{"default":null,"anyOf":[{"type":"string","maxLength":60,"pattern":"^[\\p{L}\\p{N} '-]+$"},{"type":"null"}]},"fontSize":{"default":null,"anyOf":[{"type":"integer","minimum":0,"maximum":96},{"type":"null"}]},"color":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"lineHeight":{"default":null,"anyOf":[{"type":"number","minimum":0.8,"maximum":3},{"type":"null"}]},"letterSpacing":{"default":0,"type":"number","minimum":-5,"maximum":20},"align":{"default":"left","type":"string","enum":["left","center","right"]},"html":{"type":"string","maxLength":50000}},"required":["type","id","html"]},{"type":"object","properties":{"type":{"type":"string","const":"button"},"id":{"type":"string","minLength":1,"maxLength":40},"padding":{"default":{"top":10,"right":25,"bottom":10,"left":25},"type":"object","properties":{"top":{"type":"integer","minimum":0,"maximum":200},"right":{"type":"integer","minimum":0,"maximum":200},"bottom":{"type":"integer","minimum":0,"maximum":200},"left":{"type":"integer","minimum":0,"maximum":200}},"required":["top","right","bottom","left"]},"backgroundColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"hideOn":{"default":null,"anyOf":[{"type":"string","enum":["mobile","desktop"]},{"type":"null"}]},"label":{"type":"string","maxLength":200},"url":{"type":"string","maxLength":2000},"align":{"default":"center","type":"string","enum":["left","center","right"]},"buttonColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"textColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"fontFamily":{"default":null,"anyOf":[{"type":"string","maxLength":60,"pattern":"^[\\p{L}\\p{N} '-]+$"},{"type":"null"}]},"fontSize":{"default":16,"type":"integer","minimum":0,"maximum":48},"fontWeight":{"default":600,"type":"integer","minimum":100,"maximum":900},"radius":{"default":6,"type":"integer","minimum":0,"maximum":100},"innerPadding":{"default":{"vertical":12,"horizontal":24},"type":"object","properties":{"vertical":{"type":"integer","minimum":0,"maximum":60},"horizontal":{"type":"integer","minimum":0,"maximum":120}},"required":["vertical","horizontal"]},"borderColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"borderWidth":{"default":0,"type":"integer","minimum":0,"maximum":10},"fullWidth":{"default":false,"type":"boolean"}},"required":["type","id","label","url"]},{"type":"object","properties":{"type":{"type":"string","const":"image"},"id":{"type":"string","minLength":1,"maxLength":40},"padding":{"default":{"top":10,"right":25,"bottom":10,"left":25},"type":"object","properties":{"top":{"type":"integer","minimum":0,"maximum":200},"right":{"type":"integer","minimum":0,"maximum":200},"bottom":{"type":"integer","minimum":0,"maximum":200},"left":{"type":"integer","minimum":0,"maximum":200}},"required":["top","right","bottom","left"]},"backgroundColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"hideOn":{"default":null,"anyOf":[{"type":"string","enum":["mobile","desktop"]},{"type":"null"}]},"src":{"type":"string","maxLength":2000},"alt":{"default":"","type":"string","maxLength":300},"url":{"default":"","type":"string","maxLength":2000},"width":{"default":100,"type":"integer","minimum":5,"maximum":100},"align":{"default":"center","type":"string","enum":["left","center","right"]},"radius":{"default":0,"type":"integer","minimum":0,"maximum":200}},"required":["type","id","src"]},{"type":"object","properties":{"type":{"type":"string","const":"divider"},"id":{"type":"string","minLength":1,"maxLength":40},"padding":{"default":{"top":10,"right":25,"bottom":10,"left":25},"type":"object","properties":{"top":{"type":"integer","minimum":0,"maximum":200},"right":{"type":"integer","minimum":0,"maximum":200},"bottom":{"type":"integer","minimum":0,"maximum":200},"left":{"type":"integer","minimum":0,"maximum":200}},"required":["top","right","bottom","left"]},"backgroundColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"hideOn":{"default":null,"anyOf":[{"type":"string","enum":["mobile","desktop"]},{"type":"null"}]},"color":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"thickness":{"default":1,"type":"integer","minimum":0,"maximum":20},"style":{"default":"solid","type":"string","enum":["solid","dashed","dotted"]},"width":{"default":100,"type":"integer","minimum":5,"maximum":100},"align":{"default":"center","type":"string","enum":["left","center","right"]}},"required":["type","id"]},{"type":"object","properties":{"type":{"type":"string","const":"spacer"},"id":{"type":"string","minLength":1,"maxLength":40},"padding":{"default":{"top":10,"right":25,"bottom":10,"left":25},"type":"object","properties":{"top":{"type":"integer","minimum":0,"maximum":200},"right":{"type":"integer","minimum":0,"maximum":200},"bottom":{"type":"integer","minimum":0,"maximum":200},"left":{"type":"integer","minimum":0,"maximum":200}},"required":["top","right","bottom","left"]},"backgroundColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"hideOn":{"default":null,"anyOf":[{"type":"string","enum":["mobile","desktop"]},{"type":"null"}]},"height":{"default":24,"type":"integer","minimum":0,"maximum":400}},"required":["type","id"]},{"type":"object","properties":{"type":{"type":"string","const":"social"},"id":{"type":"string","minLength":1,"maxLength":40},"padding":{"default":{"top":10,"right":25,"bottom":10,"left":25},"type":"object","properties":{"top":{"type":"integer","minimum":0,"maximum":200},"right":{"type":"integer","minimum":0,"maximum":200},"bottom":{"type":"integer","minimum":0,"maximum":200},"left":{"type":"integer","minimum":0,"maximum":200}},"required":["top","right","bottom","left"]},"backgroundColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"hideOn":{"default":null,"anyOf":[{"type":"string","enum":["mobile","desktop"]},{"type":"null"}]},"links":{"maxItems":10,"type":"array","items":{"type":"object","properties":{"network":{"type":"string","enum":["facebook","instagram","linkedin","x","youtube","tiktok","whatsapp","threads","discord","pinterest","github","phone","web"]},"url":{"type":"string","maxLength":2000}},"required":["network","url"]}},"iconSize":{"default":28,"type":"integer","minimum":0,"maximum":64},"gap":{"default":8,"type":"integer","minimum":0,"maximum":40},"iconStyle":{"default":"filled","type":"string","enum":["filled","plain"]},"iconColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"iconRadius":{"default":4,"type":"integer","minimum":0,"maximum":32},"align":{"default":"center","type":"string","enum":["left","center","right"]}},"required":["type","id","links"]},{"type":"object","properties":{"type":{"type":"string","const":"html"},"id":{"type":"string","minLength":1,"maxLength":40},"padding":{"default":{"top":10,"right":25,"bottom":10,"left":25},"type":"object","properties":{"top":{"type":"integer","minimum":0,"maximum":200},"right":{"type":"integer","minimum":0,"maximum":200},"bottom":{"type":"integer","minimum":0,"maximum":200},"left":{"type":"integer","minimum":0,"maximum":200}},"required":["top","right","bottom","left"]},"backgroundColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"hideOn":{"default":null,"anyOf":[{"type":"string","enum":["mobile","desktop"]},{"type":"null"}]},"html":{"type":"string","maxLength":100000}},"required":["type","id","html"]},{"type":"object","properties":{"type":{"type":"string","const":"catalog"},"id":{"type":"string","minLength":1,"maxLength":40},"padding":{"default":{"top":10,"right":25,"bottom":10,"left":25},"type":"object","properties":{"top":{"type":"integer","minimum":0,"maximum":200},"right":{"type":"integer","minimum":0,"maximum":200},"bottom":{"type":"integer","minimum":0,"maximum":200},"left":{"type":"integer","minimum":0,"maximum":200}},"required":["top","right","bottom","left"]},"backgroundColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"hideOn":{"default":null,"anyOf":[{"type":"string","enum":["mobile","desktop"]},{"type":"null"}]},"items":{"maxItems":12,"type":"array","items":{"type":"object","properties":{"kind":{"type":"string","enum":["service","package"]},"id":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},"url":{"default":"","type":"string","maxLength":2000}},"required":["kind","id"]}},"layout":{"default":"grid","type":"string","enum":["grid","list"]},"columns":{"default":2,"anyOf":[{"type":"number","const":1},{"type":"number","const":2},{"type":"number","const":3}]},"gap":{"default":16,"type":"integer","minimum":0,"maximum":40},"currency":{"default":null,"anyOf":[{"type":"string","pattern":"^[A-Z]{3}$"},{"type":"null"}]},"textAlign":{"default":"left","type":"string","enum":["left","center","right"]},"fontFamily":{"default":null,"anyOf":[{"type":"string","maxLength":60,"pattern":"^[\\p{L}\\p{N} '-]+$"},{"type":"null"}]},"cardColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"cardBorderColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"cardBorderWidth":{"default":1,"type":"integer","minimum":0,"maximum":10},"cardRadius":{"default":8,"type":"integer","minimum":0,"maximum":40},"cardPadding":{"default":16,"type":"integer","minimum":0,"maximum":60},"showImage":{"default":true,"type":"boolean"},"imageRatio":{"default":"square","type":"string","enum":["square","landscape","portrait","original"]},"imageRadius":{"default":4,"type":"integer","minimum":0,"maximum":40},"nameFontFamily":{"default":null,"anyOf":[{"type":"string","maxLength":60,"pattern":"^[\\p{L}\\p{N} '-]+$"},{"type":"null"}]},"nameFontSize":{"default":18,"type":"integer","minimum":0,"maximum":48},"nameFontWeight":{"default":700,"type":"integer","minimum":100,"maximum":900},"nameColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"showDescription":{"default":true,"type":"boolean"},"descriptionLength":{"default":120,"type":"integer","minimum":20,"maximum":600},"descriptionFontSize":{"default":14,"type":"integer","minimum":0,"maximum":32},"descriptionColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"showPrice":{"default":true,"type":"boolean"},"showOriginalPrice":{"default":true,"type":"boolean"},"priceFontSize":{"default":18,"type":"integer","minimum":0,"maximum":48},"priceFontWeight":{"default":700,"type":"integer","minimum":100,"maximum":900},"priceColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"showButton":{"default":true,"type":"boolean"},"buttonLabel":{"default":"","type":"string","maxLength":80},"buttonUrl":{"default":"","type":"string","maxLength":2000},"linkTo":{"default":"item","type":"string","enum":["item","catalogPage"]},"catalogPageId":{"default":null,"anyOf":[{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},{"type":"null"}]},"buttonColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"buttonTextColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"buttonFontSize":{"default":14,"type":"integer","minimum":0,"maximum":32},"buttonRadius":{"default":6,"type":"integer","minimum":0,"maximum":40},"buttonFullWidth":{"default":true,"type":"boolean"}},"required":["type","id","items"]},{"type":"object","properties":{"type":{"type":"string","const":"card"},"id":{"type":"string","minLength":1,"maxLength":40},"padding":{"default":{"top":10,"right":25,"bottom":10,"left":25},"type":"object","properties":{"top":{"type":"integer","minimum":0,"maximum":200},"right":{"type":"integer","minimum":0,"maximum":200},"bottom":{"type":"integer","minimum":0,"maximum":200},"left":{"type":"integer","minimum":0,"maximum":200}},"required":["top","right","bottom","left"]},"backgroundColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"hideOn":{"default":null,"anyOf":[{"type":"string","enum":["mobile","desktop"]},{"type":"null"}]},"src":{"type":"string","maxLength":2000},"alt":{"default":"","type":"string","maxLength":300},"imagePosition":{"default":"left","type":"string","enum":["top","left","right"]},"imageWidth":{"default":40,"type":"integer","minimum":20,"maximum":70},"imageRatio":{"default":"landscape","type":"string","enum":["original","square","landscape","portrait"]},"imageRadius":{"default":8,"type":"integer","minimum":0,"maximum":200},"imageBleed":{"default":false,"type":"boolean"},"title":{"default":"","type":"string","maxLength":200},"html":{"default":"","type":"string","maxLength":20000},"url":{"default":"","type":"string","maxLength":2000},"titleFontSize":{"default":20,"type":"integer","minimum":10,"maximum":72},"titleColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"textColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"fontFamily":{"default":null,"anyOf":[{"type":"string","maxLength":60,"pattern":"^[\\p{L}\\p{N} '-]+$"},{"type":"null"}]},"textAlign":{"default":"left","type":"string","enum":["left","center","right"]},"verticalAlign":{"default":"middle","type":"string","enum":["top","middle"]},"cardColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"borderColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"borderWidth":{"default":1,"type":"integer","minimum":0,"maximum":10},"radius":{"default":12,"type":"integer","minimum":0,"maximum":60},"cardPadding":{"default":16,"type":"integer","minimum":0,"maximum":80},"gap":{"default":16,"type":"integer","minimum":0,"maximum":80}},"required":["type","id","src"]}]}},"backgroundColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"padding":{"default":{"top":0,"right":0,"bottom":0,"left":0},"type":"object","properties":{"top":{"type":"integer","minimum":0,"maximum":200},"right":{"type":"integer","minimum":0,"maximum":200},"bottom":{"type":"integer","minimum":0,"maximum":200},"left":{"type":"integer","minimum":0,"maximum":200}},"required":["top","right","bottom","left"]},"radius":{"default":0,"type":"integer","minimum":0,"maximum":100},"verticalAlign":{"default":"top","type":"string","enum":["top","middle","bottom"]}},"required":["id","blocks"]}},"widths":{"minItems":1,"maxItems":4,"type":"array","items":{"type":"number","minimum":10,"maximum":100}},"backgroundColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"backgroundImage":{"default":"","type":"string","maxLength":2000},"fullWidth":{"default":false,"type":"boolean"},"padding":{"default":{"top":10,"right":0,"bottom":10,"left":0},"type":"object","properties":{"top":{"type":"integer","minimum":0,"maximum":200},"right":{"type":"integer","minimum":0,"maximum":200},"bottom":{"type":"integer","minimum":0,"maximum":200},"left":{"type":"integer","minimum":0,"maximum":200}},"required":["top","right","bottom","left"]},"radius":{"default":0,"type":"integer","minimum":0,"maximum":100},"borderColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"borderWidth":{"default":0,"type":"integer","minimum":0,"maximum":10},"stackOnMobile":{"default":true,"type":"boolean"},"hideOn":{"default":null,"anyOf":[{"type":"string","enum":["mobile","desktop"]},{"type":"null"}]}},"required":["id","columns","widths"]}},"required":["kind","name","row"]}]}}}},"responses":{"201":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"block":{"properties":{"align":{"type":"string"},"backgroundColor":{"type":"null"},"borderColor":{"type":"null"},"borderWidth":{"type":"integer"},"buttonColor":{"type":"null"},"fontFamily":{"type":"null"},"fontSize":{"type":"integer"},"fontWeight":{"type":"integer"},"fullWidth":{"type":"boolean"},"hideOn":{"type":"null"},"id":{"type":"string"},"innerPadding":{"properties":{"horizontal":{"type":"integer"},"vertical":{"type":"integer"}},"required":["vertical","horizontal"],"type":"object"},"label":{"type":"string"},"padding":{"properties":{"bottom":{"type":"integer"},"left":{"type":"integer"},"right":{"type":"integer"},"top":{"type":"integer"}},"required":["top","left","right","bottom"],"type":"object"},"radius":{"type":"integer"},"textColor":{"type":"null"},"type":{"type":"string"},"url":{"format":"uri","type":"string"}},"required":["id","url","type","align","label","hideOn","radius","padding","fontSize","fullWidth","textColor","fontFamily","fontWeight","borderColor","borderWidth","buttonColor","innerPadding","backgroundColor"],"type":["null","object"]},"createdAt":{"format":"date-time","type":"string"},"createdBy":{"format":"uuid","type":"string"},"icon":{"type":"string"},"id":{"format":"uuid","type":"string"},"kind":{"type":"string"},"name":{"type":"string"},"row":{"properties":{"backgroundColor":{"type":"null"},"backgroundImage":{"type":"string"},"borderColor":{"type":"null"},"borderWidth":{"type":"integer"},"columns":{"items":{"properties":{"backgroundColor":{"type":"null"},"blocks":{"items":{"properties":{"align":{"type":"string"},"backgroundColor":{"type":"null"},"borderColor":{"type":"null"},"borderWidth":{"type":"integer"},"buttonColor":{"type":"null"},"color":{"type":"null"},"fontFamily":{"type":"null"},"fontSize":{"type":["integer","null"]},"fontWeight":{"type":"integer"},"fullWidth":{"type":"boolean"},"hideOn":{"type":"null"},"html":{"type":"string"},"id":{"type":"string"},"innerPadding":{"properties":{"horizontal":{"type":"integer"},"vertical":{"type":"integer"}},"required":["vertical","horizontal"],"type":"object"},"label":{"type":"string"},"letterSpacing":{"type":"integer"},"lineHeight":{"type":"null"},"padding":{"properties":{"bottom":{"type":"integer"},"left":{"type":"integer"},"right":{"type":"integer"},"top":{"type":"integer"}},"required":["top","left","right","bottom"],"type":"object"},"radius":{"type":"integer"},"textColor":{"type":"null"},"type":{"type":"string"},"url":{"format":"uri","type":"string"}},"required":["id","type","align","hideOn","padding","fontSize","fontFamily","backgroundColor"],"type":"object"},"type":"array"},"id":{"type":"string"},"padding":{"properties":{"bottom":{"type":"integer"},"left":{"type":"integer"},"right":{"type":"integer"},"top":{"type":"integer"}},"required":["top","left","right","bottom"],"type":"object"},"radius":{"type":"integer"},"verticalAlign":{"type":"string"}},"required":["id","blocks","radius","padding","verticalAlign","backgroundColor"],"type":"object"},"type":"array"},"fullWidth":{"type":"boolean"},"hideOn":{"type":"null"},"id":{"type":"string"},"padding":{"properties":{"bottom":{"type":"integer"},"left":{"type":"integer"},"right":{"type":"integer"},"top":{"type":"integer"}},"required":["top","left","right","bottom"],"type":"object"},"radius":{"type":"integer"},"stackOnMobile":{"type":"boolean"},"widths":{"items":{"type":"integer"},"type":"array"}},"required":["id","hideOn","radius","widths","columns","padding","fullWidth","borderColor","borderWidth","stackOnMobile","backgroundColor","backgroundImage"],"type":["null","object"]},"updatedAt":{"format":"date-time","type":"string"}},"required":["id","name","icon","kind","createdBy","createdAt","updatedAt","block","row"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/emails/saved-blocks/{id}":{"delete":{"operationId":"DELETE /v1/emails/saved-blocks/{id}","summary":"Deletes a saved block; templates that used it keep their copy.","tags":["emails"],"x-feature":"emails","x-action":"delete","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"204":{"description":"Done, with no content."},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"patch":{"operationId":"PATCH /v1/emails/saved-blocks/{id}","summary":"Renames a saved block or changes its icon.","tags":["emails"],"x-feature":"emails","x-action":"update","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"name":{"type":"string","minLength":1,"maxLength":60},"icon":{"type":"string","enum":["blocks","star","heart","megaphone","gift","tag","shopping-bag","calendar","image","mail","phone","map-pin","sparkles","zap","users","file-text"]}}}}}},"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"block":{"properties":{"align":{"type":"string"},"backgroundColor":{"type":"null"},"borderColor":{"type":"null"},"borderWidth":{"type":"integer"},"buttonColor":{"type":"null"},"fontFamily":{"type":"null"},"fontSize":{"type":"integer"},"fontWeight":{"type":"integer"},"fullWidth":{"type":"boolean"},"hideOn":{"type":"null"},"id":{"type":"string"},"innerPadding":{"properties":{"horizontal":{"type":"integer"},"vertical":{"type":"integer"}},"required":["vertical","horizontal"],"type":"object"},"label":{"type":"string"},"padding":{"properties":{"bottom":{"type":"integer"},"left":{"type":"integer"},"right":{"type":"integer"},"top":{"type":"integer"}},"required":["top","left","right","bottom"],"type":"object"},"radius":{"type":"integer"},"textColor":{"type":"null"},"type":{"type":"string"},"url":{"format":"uri","type":"string"}},"required":["id","url","type","align","label","hideOn","radius","padding","fontSize","fullWidth","textColor","fontFamily","fontWeight","borderColor","borderWidth","buttonColor","innerPadding","backgroundColor"],"type":"object"},"createdAt":{"format":"date-time","type":"string"},"createdBy":{"format":"uuid","type":"string"},"icon":{"type":"string"},"id":{"format":"uuid","type":"string"},"kind":{"type":"string"},"name":{"type":"string"},"row":{"type":"null"},"updatedAt":{"format":"date-time","type":"string"}},"required":["id","name","icon","kind","createdBy","createdAt","updatedAt","block","row"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/emails/send":{"post":{"operationId":"POST /v1/emails/send","summary":"Sends a template to one contact or address (transactional unless said otherwise).","tags":["emails"],"x-feature":"emails","x-action":"create","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"templateId":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},"contactId":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},"to":{"type":"string","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,}$"},"kind":{"default":"transactional","type":"string","enum":["transactional","marketing"]},"data":{"type":"object","propertyNames":{"type":"string","pattern":"^[a-zA-Z][\\w-]{0,49}$"},"additionalProperties":{"anyOf":[{"type":"string","maxLength":2000},{"type":"number"},{"type":"boolean"},{"type":"null"}]}},"subject":{"type":"string","maxLength":300},"domainId":{"anyOf":[{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},{"type":"null"}]},"fromName":{"anyOf":[{"type":"string","maxLength":100},{"type":"null"}]},"fromLocal":{"anyOf":[{"type":"string","pattern":"^[a-z0-9](?:[a-z0-9._+-]{0,62}[a-z0-9])?$"},{"type":"null"}]},"replyTo":{"anyOf":[{"type":"string","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,}$"},{"type":"null"}]},"sendAt":{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"}},"required":["templateId"]}}}},"responses":{"201":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"automationId":{"type":"null"},"bouncedAt":{"type":"null"},"campaignId":{"type":"null"},"clickedAt":{"type":"null"},"clicks":{"type":"integer"},"complainedAt":{"type":"null"},"contactId":{"format":"uuid","type":"string"},"createdAt":{"format":"date-time","type":"string"},"deliveredAt":{"type":"null"},"email":{"format":"email","type":"string"},"error":{"type":["null","string"]},"id":{"format":"uuid","type":"string"},"kind":{"type":"string"},"openedAt":{"type":"null"},"opens":{"type":"integer"},"sendAfter":{"format":"date-time","type":"string"},"sentAt":{"format":"date-time","type":["null","string"]},"source":{"type":"string"},"status":{"type":"string"},"subject":{"type":["null","string"]},"templateId":{"format":"uuid","type":"string"},"unsubscribedAt":{"type":"null"}},"required":["automationId","bouncedAt","campaignId","clickedAt","clicks","complainedAt","contactId","createdAt","deliveredAt","email","error","id","kind","openedAt","opens","sendAfter","sentAt","source","status","subject","templateId","unsubscribedAt"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/emails/sends":{"get":{"operationId":"GET /v1/emails/sends","summary":"Lists the emails sent, with their status, opens and clicks.","tags":["emails"],"x-feature":"emails","x-action":"read","parameters":[{"name":"page","in":"query","required":false,"schema":{"default":1,"type":"integer","minimum":1,"maximum":9007199254740991}},{"name":"contactId","in":"query","required":false,"schema":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"}},{"name":"source","in":"query","required":false,"schema":{"type":"string","enum":["campaign","automation","api","manual","test"]}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/emails/sends/{id}":{"get":{"operationId":"GET /v1/emails/sends/{id}","summary":"Returns one email sent, with what happened to it.","tags":["emails"],"x-feature":"emails","x-action":"read","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/emails/templates":{"get":{"operationId":"GET /v1/emails/templates","summary":"Lists the email templates.","tags":["emails"],"x-feature":"emails","x-action":"read","responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"post":{"operationId":"POST /v1/emails/templates","summary":"Creates an email template.","tags":["emails"],"x-feature":"emails","x-action":"create","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"name":{"type":"string","minLength":1,"maxLength":120},"subject":{"default":"","type":"string","maxLength":300},"preheader":{"default":"","type":"string","maxLength":300},"document":{"type":"object","properties":{"version":{"default":1,"type":"number","const":1},"settings":{"default":{"backdropColor":"#f4f4f5","contentColor":"#ffffff","width":600,"fontFamily":"Arial","headingFontFamily":"Arial","fontSize":16,"lineHeight":1.5,"textColor":"#1f2937","headingColor":"#111827","linkColor":"#2563eb","primaryColor":"#2563eb","onPrimaryColor":"#ffffff","radius":0,"outerPadding":24},"type":"object","properties":{"backdropColor":{"default":"#f4f4f5","type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"contentColor":{"default":"#ffffff","type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"width":{"default":600,"type":"integer","minimum":320,"maximum":900},"fontFamily":{"default":"Arial","type":"string","maxLength":60},"headingFontFamily":{"default":"Arial","type":"string","maxLength":60},"fontSize":{"default":16,"type":"integer","minimum":0,"maximum":40},"lineHeight":{"default":1.5,"type":"number","minimum":0.8,"maximum":3},"textColor":{"default":"#1f2937","type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"headingColor":{"default":"#111827","type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"linkColor":{"default":"#2563eb","type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"primaryColor":{"default":"#2563eb","type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"onPrimaryColor":{"default":"#ffffff","type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"radius":{"default":0,"type":"integer","minimum":0,"maximum":40},"outerPadding":{"default":24,"type":"integer","minimum":0,"maximum":120}}},"header":{"default":{"show":true,"placement":"outside","color":null,"linkColor":null,"backgroundColor":null,"fontSize":12,"padding":{"top":12,"right":25,"bottom":12,"left":25},"presetId":null,"custom":null},"type":"object","properties":{"show":{"default":true,"type":"boolean"},"placement":{"default":"outside","type":"string","enum":["inside","outside"]},"color":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"linkColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"backgroundColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"fontSize":{"default":12,"type":"integer","minimum":0,"maximum":24},"padding":{"default":{"top":12,"right":25,"bottom":12,"left":25},"type":"object","properties":{"top":{"type":"integer","minimum":0,"maximum":200},"right":{"type":"integer","minimum":0,"maximum":200},"bottom":{"type":"integer","minimum":0,"maximum":200},"left":{"type":"integer","minimum":0,"maximum":200}},"required":["top","right","bottom","left"]},"presetId":{"default":null,"anyOf":[{"type":"string","maxLength":40},{"type":"null"}]},"custom":{"default":null,"anyOf":[{"type":"object","properties":{"text":{"default":"","type":"string","maxLength":300},"linkLabel":{"default":"","type":"string","maxLength":60}}},{"type":"null"}]}}},"footer":{"default":{"placement":"inside","color":null,"linkColor":null,"backgroundColor":null,"fontSize":12,"padding":{"top":12,"right":25,"bottom":12,"left":25},"align":"center","presetId":null,"custom":null},"type":"object","properties":{"placement":{"default":"inside","type":"string","enum":["inside","outside"]},"color":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"linkColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"backgroundColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"fontSize":{"default":12,"type":"integer","minimum":0,"maximum":24},"padding":{"default":{"top":12,"right":25,"bottom":12,"left":25},"type":"object","properties":{"top":{"type":"integer","minimum":0,"maximum":200},"right":{"type":"integer","minimum":0,"maximum":200},"bottom":{"type":"integer","minimum":0,"maximum":200},"left":{"type":"integer","minimum":0,"maximum":200}},"required":["top","right","bottom","left"]},"align":{"default":"center","type":"string","enum":["left","center","right"]},"presetId":{"default":null,"anyOf":[{"type":"string","maxLength":40},{"type":"null"}]},"custom":{"default":null,"anyOf":[{"type":"object","properties":{"html":{"default":"","type":"string","maxLength":50000},"unsubscribeLabel":{"type":"string","minLength":1,"maxLength":100},"showAddress":{"default":true,"type":"boolean"}},"required":["unsubscribeLabel"]},{"type":"null"}]}}},"rows":{"maxItems":100,"type":"array","items":{"type":"object","properties":{"id":{"type":"string","minLength":1,"maxLength":40},"columns":{"minItems":1,"maxItems":4,"type":"array","items":{"type":"object","properties":{"id":{"type":"string","minLength":1,"maxLength":40},"blocks":{"maxItems":60,"type":"array","items":{"oneOf":[{"type":"object","properties":{"type":{"type":"string","const":"heading"},"id":{"type":"string","minLength":1,"maxLength":40},"padding":{"default":{"top":10,"right":25,"bottom":10,"left":25},"type":"object","properties":{"top":{"type":"integer","minimum":0,"maximum":200},"right":{"type":"integer","minimum":0,"maximum":200},"bottom":{"type":"integer","minimum":0,"maximum":200},"left":{"type":"integer","minimum":0,"maximum":200}},"required":["top","right","bottom","left"]},"backgroundColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"hideOn":{"default":null,"anyOf":[{"type":"string","enum":["mobile","desktop"]},{"type":"null"}]},"fontFamily":{"default":null,"anyOf":[{"type":"string","maxLength":60,"pattern":"^[\\p{L}\\p{N} '-]+$"},{"type":"null"}]},"fontSize":{"default":null,"anyOf":[{"type":"integer","minimum":0,"maximum":96},{"type":"null"}]},"color":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"lineHeight":{"default":null,"anyOf":[{"type":"number","minimum":0.8,"maximum":3},{"type":"null"}]},"letterSpacing":{"default":0,"type":"number","minimum":-5,"maximum":20},"align":{"default":"left","type":"string","enum":["left","center","right"]},"html":{"type":"string","maxLength":50000},"level":{"default":1,"anyOf":[{"type":"number","const":1},{"type":"number","const":2},{"type":"number","const":3}]},"fontWeight":{"default":700,"type":"integer","minimum":100,"maximum":900}},"required":["type","id","html"]},{"type":"object","properties":{"type":{"type":"string","const":"text"},"id":{"type":"string","minLength":1,"maxLength":40},"padding":{"default":{"top":10,"right":25,"bottom":10,"left":25},"type":"object","properties":{"top":{"type":"integer","minimum":0,"maximum":200},"right":{"type":"integer","minimum":0,"maximum":200},"bottom":{"type":"integer","minimum":0,"maximum":200},"left":{"type":"integer","minimum":0,"maximum":200}},"required":["top","right","bottom","left"]},"backgroundColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"hideOn":{"default":null,"anyOf":[{"type":"string","enum":["mobile","desktop"]},{"type":"null"}]},"fontFamily":{"default":null,"anyOf":[{"type":"string","maxLength":60,"pattern":"^[\\p{L}\\p{N} '-]+$"},{"type":"null"}]},"fontSize":{"default":null,"anyOf":[{"type":"integer","minimum":0,"maximum":96},{"type":"null"}]},"color":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"lineHeight":{"default":null,"anyOf":[{"type":"number","minimum":0.8,"maximum":3},{"type":"null"}]},"letterSpacing":{"default":0,"type":"number","minimum":-5,"maximum":20},"align":{"default":"left","type":"string","enum":["left","center","right"]},"html":{"type":"string","maxLength":50000}},"required":["type","id","html"]},{"type":"object","properties":{"type":{"type":"string","const":"button"},"id":{"type":"string","minLength":1,"maxLength":40},"padding":{"default":{"top":10,"right":25,"bottom":10,"left":25},"type":"object","properties":{"top":{"type":"integer","minimum":0,"maximum":200},"right":{"type":"integer","minimum":0,"maximum":200},"bottom":{"type":"integer","minimum":0,"maximum":200},"left":{"type":"integer","minimum":0,"maximum":200}},"required":["top","right","bottom","left"]},"backgroundColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"hideOn":{"default":null,"anyOf":[{"type":"string","enum":["mobile","desktop"]},{"type":"null"}]},"label":{"type":"string","maxLength":200},"url":{"type":"string","maxLength":2000},"align":{"default":"center","type":"string","enum":["left","center","right"]},"buttonColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"textColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"fontFamily":{"default":null,"anyOf":[{"type":"string","maxLength":60,"pattern":"^[\\p{L}\\p{N} '-]+$"},{"type":"null"}]},"fontSize":{"default":16,"type":"integer","minimum":0,"maximum":48},"fontWeight":{"default":600,"type":"integer","minimum":100,"maximum":900},"radius":{"default":6,"type":"integer","minimum":0,"maximum":100},"innerPadding":{"default":{"vertical":12,"horizontal":24},"type":"object","properties":{"vertical":{"type":"integer","minimum":0,"maximum":60},"horizontal":{"type":"integer","minimum":0,"maximum":120}},"required":["vertical","horizontal"]},"borderColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"borderWidth":{"default":0,"type":"integer","minimum":0,"maximum":10},"fullWidth":{"default":false,"type":"boolean"}},"required":["type","id","label","url"]},{"type":"object","properties":{"type":{"type":"string","const":"image"},"id":{"type":"string","minLength":1,"maxLength":40},"padding":{"default":{"top":10,"right":25,"bottom":10,"left":25},"type":"object","properties":{"top":{"type":"integer","minimum":0,"maximum":200},"right":{"type":"integer","minimum":0,"maximum":200},"bottom":{"type":"integer","minimum":0,"maximum":200},"left":{"type":"integer","minimum":0,"maximum":200}},"required":["top","right","bottom","left"]},"backgroundColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"hideOn":{"default":null,"anyOf":[{"type":"string","enum":["mobile","desktop"]},{"type":"null"}]},"src":{"type":"string","maxLength":2000},"alt":{"default":"","type":"string","maxLength":300},"url":{"default":"","type":"string","maxLength":2000},"width":{"default":100,"type":"integer","minimum":5,"maximum":100},"align":{"default":"center","type":"string","enum":["left","center","right"]},"radius":{"default":0,"type":"integer","minimum":0,"maximum":200}},"required":["type","id","src"]},{"type":"object","properties":{"type":{"type":"string","const":"divider"},"id":{"type":"string","minLength":1,"maxLength":40},"padding":{"default":{"top":10,"right":25,"bottom":10,"left":25},"type":"object","properties":{"top":{"type":"integer","minimum":0,"maximum":200},"right":{"type":"integer","minimum":0,"maximum":200},"bottom":{"type":"integer","minimum":0,"maximum":200},"left":{"type":"integer","minimum":0,"maximum":200}},"required":["top","right","bottom","left"]},"backgroundColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"hideOn":{"default":null,"anyOf":[{"type":"string","enum":["mobile","desktop"]},{"type":"null"}]},"color":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"thickness":{"default":1,"type":"integer","minimum":0,"maximum":20},"style":{"default":"solid","type":"string","enum":["solid","dashed","dotted"]},"width":{"default":100,"type":"integer","minimum":5,"maximum":100},"align":{"default":"center","type":"string","enum":["left","center","right"]}},"required":["type","id"]},{"type":"object","properties":{"type":{"type":"string","const":"spacer"},"id":{"type":"string","minLength":1,"maxLength":40},"padding":{"default":{"top":10,"right":25,"bottom":10,"left":25},"type":"object","properties":{"top":{"type":"integer","minimum":0,"maximum":200},"right":{"type":"integer","minimum":0,"maximum":200},"bottom":{"type":"integer","minimum":0,"maximum":200},"left":{"type":"integer","minimum":0,"maximum":200}},"required":["top","right","bottom","left"]},"backgroundColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"hideOn":{"default":null,"anyOf":[{"type":"string","enum":["mobile","desktop"]},{"type":"null"}]},"height":{"default":24,"type":"integer","minimum":0,"maximum":400}},"required":["type","id"]},{"type":"object","properties":{"type":{"type":"string","const":"social"},"id":{"type":"string","minLength":1,"maxLength":40},"padding":{"default":{"top":10,"right":25,"bottom":10,"left":25},"type":"object","properties":{"top":{"type":"integer","minimum":0,"maximum":200},"right":{"type":"integer","minimum":0,"maximum":200},"bottom":{"type":"integer","minimum":0,"maximum":200},"left":{"type":"integer","minimum":0,"maximum":200}},"required":["top","right","bottom","left"]},"backgroundColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"hideOn":{"default":null,"anyOf":[{"type":"string","enum":["mobile","desktop"]},{"type":"null"}]},"links":{"maxItems":10,"type":"array","items":{"type":"object","properties":{"network":{"type":"string","enum":["facebook","instagram","linkedin","x","youtube","tiktok","whatsapp","threads","discord","pinterest","github","phone","web"]},"url":{"type":"string","maxLength":2000}},"required":["network","url"]}},"iconSize":{"default":28,"type":"integer","minimum":0,"maximum":64},"gap":{"default":8,"type":"integer","minimum":0,"maximum":40},"iconStyle":{"default":"filled","type":"string","enum":["filled","plain"]},"iconColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"iconRadius":{"default":4,"type":"integer","minimum":0,"maximum":32},"align":{"default":"center","type":"string","enum":["left","center","right"]}},"required":["type","id","links"]},{"type":"object","properties":{"type":{"type":"string","const":"html"},"id":{"type":"string","minLength":1,"maxLength":40},"padding":{"default":{"top":10,"right":25,"bottom":10,"left":25},"type":"object","properties":{"top":{"type":"integer","minimum":0,"maximum":200},"right":{"type":"integer","minimum":0,"maximum":200},"bottom":{"type":"integer","minimum":0,"maximum":200},"left":{"type":"integer","minimum":0,"maximum":200}},"required":["top","right","bottom","left"]},"backgroundColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"hideOn":{"default":null,"anyOf":[{"type":"string","enum":["mobile","desktop"]},{"type":"null"}]},"html":{"type":"string","maxLength":100000}},"required":["type","id","html"]},{"type":"object","properties":{"type":{"type":"string","const":"catalog"},"id":{"type":"string","minLength":1,"maxLength":40},"padding":{"default":{"top":10,"right":25,"bottom":10,"left":25},"type":"object","properties":{"top":{"type":"integer","minimum":0,"maximum":200},"right":{"type":"integer","minimum":0,"maximum":200},"bottom":{"type":"integer","minimum":0,"maximum":200},"left":{"type":"integer","minimum":0,"maximum":200}},"required":["top","right","bottom","left"]},"backgroundColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"hideOn":{"default":null,"anyOf":[{"type":"string","enum":["mobile","desktop"]},{"type":"null"}]},"items":{"maxItems":12,"type":"array","items":{"type":"object","properties":{"kind":{"type":"string","enum":["service","package"]},"id":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},"url":{"default":"","type":"string","maxLength":2000}},"required":["kind","id"]}},"layout":{"default":"grid","type":"string","enum":["grid","list"]},"columns":{"default":2,"anyOf":[{"type":"number","const":1},{"type":"number","const":2},{"type":"number","const":3}]},"gap":{"default":16,"type":"integer","minimum":0,"maximum":40},"currency":{"default":null,"anyOf":[{"type":"string","pattern":"^[A-Z]{3}$"},{"type":"null"}]},"textAlign":{"default":"left","type":"string","enum":["left","center","right"]},"fontFamily":{"default":null,"anyOf":[{"type":"string","maxLength":60,"pattern":"^[\\p{L}\\p{N} '-]+$"},{"type":"null"}]},"cardColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"cardBorderColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"cardBorderWidth":{"default":1,"type":"integer","minimum":0,"maximum":10},"cardRadius":{"default":8,"type":"integer","minimum":0,"maximum":40},"cardPadding":{"default":16,"type":"integer","minimum":0,"maximum":60},"showImage":{"default":true,"type":"boolean"},"imageRatio":{"default":"square","type":"string","enum":["square","landscape","portrait","original"]},"imageRadius":{"default":4,"type":"integer","minimum":0,"maximum":40},"nameFontFamily":{"default":null,"anyOf":[{"type":"string","maxLength":60,"pattern":"^[\\p{L}\\p{N} '-]+$"},{"type":"null"}]},"nameFontSize":{"default":18,"type":"integer","minimum":0,"maximum":48},"nameFontWeight":{"default":700,"type":"integer","minimum":100,"maximum":900},"nameColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"showDescription":{"default":true,"type":"boolean"},"descriptionLength":{"default":120,"type":"integer","minimum":20,"maximum":600},"descriptionFontSize":{"default":14,"type":"integer","minimum":0,"maximum":32},"descriptionColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"showPrice":{"default":true,"type":"boolean"},"showOriginalPrice":{"default":true,"type":"boolean"},"priceFontSize":{"default":18,"type":"integer","minimum":0,"maximum":48},"priceFontWeight":{"default":700,"type":"integer","minimum":100,"maximum":900},"priceColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"showButton":{"default":true,"type":"boolean"},"buttonLabel":{"default":"","type":"string","maxLength":80},"buttonUrl":{"default":"","type":"string","maxLength":2000},"linkTo":{"default":"item","type":"string","enum":["item","catalogPage"]},"catalogPageId":{"default":null,"anyOf":[{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},{"type":"null"}]},"buttonColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"buttonTextColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"buttonFontSize":{"default":14,"type":"integer","minimum":0,"maximum":32},"buttonRadius":{"default":6,"type":"integer","minimum":0,"maximum":40},"buttonFullWidth":{"default":true,"type":"boolean"}},"required":["type","id","items"]},{"type":"object","properties":{"type":{"type":"string","const":"card"},"id":{"type":"string","minLength":1,"maxLength":40},"padding":{"default":{"top":10,"right":25,"bottom":10,"left":25},"type":"object","properties":{"top":{"type":"integer","minimum":0,"maximum":200},"right":{"type":"integer","minimum":0,"maximum":200},"bottom":{"type":"integer","minimum":0,"maximum":200},"left":{"type":"integer","minimum":0,"maximum":200}},"required":["top","right","bottom","left"]},"backgroundColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"hideOn":{"default":null,"anyOf":[{"type":"string","enum":["mobile","desktop"]},{"type":"null"}]},"src":{"type":"string","maxLength":2000},"alt":{"default":"","type":"string","maxLength":300},"imagePosition":{"default":"left","type":"string","enum":["top","left","right"]},"imageWidth":{"default":40,"type":"integer","minimum":20,"maximum":70},"imageRatio":{"default":"landscape","type":"string","enum":["original","square","landscape","portrait"]},"imageRadius":{"default":8,"type":"integer","minimum":0,"maximum":200},"imageBleed":{"default":false,"type":"boolean"},"title":{"default":"","type":"string","maxLength":200},"html":{"default":"","type":"string","maxLength":20000},"url":{"default":"","type":"string","maxLength":2000},"titleFontSize":{"default":20,"type":"integer","minimum":10,"maximum":72},"titleColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"textColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"fontFamily":{"default":null,"anyOf":[{"type":"string","maxLength":60,"pattern":"^[\\p{L}\\p{N} '-]+$"},{"type":"null"}]},"textAlign":{"default":"left","type":"string","enum":["left","center","right"]},"verticalAlign":{"default":"middle","type":"string","enum":["top","middle"]},"cardColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"borderColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"borderWidth":{"default":1,"type":"integer","minimum":0,"maximum":10},"radius":{"default":12,"type":"integer","minimum":0,"maximum":60},"cardPadding":{"default":16,"type":"integer","minimum":0,"maximum":80},"gap":{"default":16,"type":"integer","minimum":0,"maximum":80}},"required":["type","id","src"]}]}},"backgroundColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"padding":{"default":{"top":0,"right":0,"bottom":0,"left":0},"type":"object","properties":{"top":{"type":"integer","minimum":0,"maximum":200},"right":{"type":"integer","minimum":0,"maximum":200},"bottom":{"type":"integer","minimum":0,"maximum":200},"left":{"type":"integer","minimum":0,"maximum":200}},"required":["top","right","bottom","left"]},"radius":{"default":0,"type":"integer","minimum":0,"maximum":100},"verticalAlign":{"default":"top","type":"string","enum":["top","middle","bottom"]}},"required":["id","blocks"]}},"widths":{"minItems":1,"maxItems":4,"type":"array","items":{"type":"number","minimum":10,"maximum":100}},"backgroundColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"backgroundImage":{"default":"","type":"string","maxLength":2000},"fullWidth":{"default":false,"type":"boolean"},"padding":{"default":{"top":10,"right":0,"bottom":10,"left":0},"type":"object","properties":{"top":{"type":"integer","minimum":0,"maximum":200},"right":{"type":"integer","minimum":0,"maximum":200},"bottom":{"type":"integer","minimum":0,"maximum":200},"left":{"type":"integer","minimum":0,"maximum":200}},"required":["top","right","bottom","left"]},"radius":{"default":0,"type":"integer","minimum":0,"maximum":100},"borderColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"borderWidth":{"default":0,"type":"integer","minimum":0,"maximum":10},"stackOnMobile":{"default":true,"type":"boolean"},"hideOn":{"default":null,"anyOf":[{"type":"string","enum":["mobile","desktop"]},{"type":"null"}]}},"required":["id","columns","widths"]}}},"required":["rows"]}},"required":["name"]}}}},"responses":{"201":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"createdAt":{"format":"date-time","type":"string"},"createdBy":{"format":"uuid","type":"string"},"document":{"properties":{"footer":{"properties":{"align":{"type":"string"},"backgroundColor":{"type":"null"},"color":{"type":["null","string"]},"custom":{"properties":{"html":{"type":"string"},"showAddress":{"type":"boolean"},"unsubscribeLabel":{"type":"string"}},"required":["html","showAddress","unsubscribeLabel"],"type":["null","object"]},"fontSize":{"type":"integer"},"linkColor":{"type":"null"},"padding":{"properties":{"bottom":{"type":"integer"},"left":{"type":"integer"},"right":{"type":"integer"},"top":{"type":"integer"}},"required":["bottom","left","right","top"],"type":"object"},"placement":{"type":"string"},"presetId":{"type":"null"}},"required":["align","backgroundColor","color","custom","fontSize","linkColor","padding","placement","presetId"],"type":"object"},"header":{"properties":{"backgroundColor":{"type":"null"},"color":{"type":"null"},"custom":{"type":"null"},"fontSize":{"type":"integer"},"linkColor":{"type":"null"},"padding":{"properties":{"bottom":{"type":"integer"},"left":{"type":"integer"},"right":{"type":"integer"},"top":{"type":"integer"}},"required":["bottom","left","right","top"],"type":"object"},"placement":{"type":"string"},"presetId":{"type":"null"},"show":{"type":"boolean"}},"required":["backgroundColor","color","custom","fontSize","linkColor","padding","placement","presetId","show"],"type":"object"},"rows":{"items":{"properties":{"backgroundColor":{"type":"null"},"backgroundImage":{"type":"string"},"borderColor":{"type":"null"},"borderWidth":{"type":"integer"},"columns":{"items":{"properties":{"backgroundColor":{"type":"null"},"blocks":{"items":{"properties":{"align":{"type":"string"},"alt":{"type":"string"},"backgroundColor":{"type":"null"},"borderColor":{"type":"null"},"borderWidth":{"type":"integer"},"buttonColor":{"type":"null"},"color":{"type":"null"},"fontFamily":{"type":"null"},"fontSize":{"type":["integer","null"]},"fontWeight":{"type":"integer"},"fullWidth":{"type":"boolean"},"hideOn":{"type":"null"},"html":{"type":"string"},"id":{"type":"string"},"innerPadding":{"properties":{"horizontal":{"type":"integer"},"vertical":{"type":"integer"}},"required":["vertical","horizontal"],"type":"object"},"label":{"type":"string"},"letterSpacing":{"type":"integer"},"level":{"type":"integer"},"lineHeight":{"type":"null"},"padding":{"properties":{"bottom":{"type":"integer"},"left":{"type":"integer"},"right":{"type":"integer"},"top":{"type":"integer"}},"required":["bottom","left","right","top"],"type":"object"},"radius":{"type":"integer"},"src":{"format":"uri","type":"string"},"textColor":{"type":"null"},"type":{"type":"string"},"url":{"type":"string"},"width":{"type":"integer"}},"required":["align","backgroundColor","hideOn","id","padding","type"],"type":"object"},"type":"array"},"id":{"type":"string"},"padding":{"properties":{"bottom":{"type":"integer"},"left":{"type":"integer"},"right":{"type":"integer"},"top":{"type":"integer"}},"required":["bottom","left","right","top"],"type":"object"},"radius":{"type":"integer"},"verticalAlign":{"type":"string"}},"required":["backgroundColor","blocks","id","padding","radius","verticalAlign"],"type":"object"},"type":"array"},"fullWidth":{"type":"boolean"},"hideOn":{"type":"null"},"id":{"type":"string"},"padding":{"properties":{"bottom":{"type":"integer"},"left":{"type":"integer"},"right":{"type":"integer"},"top":{"type":"integer"}},"required":["bottom","left","right","top"],"type":"object"},"radius":{"type":"integer"},"stackOnMobile":{"type":"boolean"},"widths":{"items":{"type":"integer"},"type":"array"}},"required":["backgroundColor","backgroundImage","borderColor","borderWidth","columns","fullWidth","hideOn","id","padding","radius","stackOnMobile","widths"],"type":"object"},"type":"array"},"settings":{"properties":{"backdropColor":{"type":"string"},"contentColor":{"type":"string"},"fontFamily":{"type":"string"},"fontSize":{"type":"integer"},"headingColor":{"type":"string"},"headingFontFamily":{"type":"string"},"lineHeight":{"type":"number"},"linkColor":{"type":"string"},"onPrimaryColor":{"type":"string"},"outerPadding":{"type":"integer"},"primaryColor":{"type":"string"},"radius":{"type":"integer"},"textColor":{"type":"string"},"width":{"type":"integer"}},"required":["backdropColor","contentColor","fontFamily","fontSize","headingColor","headingFontFamily","lineHeight","linkColor","onPrimaryColor","outerPadding","primaryColor","radius","textColor","width"],"type":"object"},"version":{"type":"integer"}},"required":["footer","header","rows","settings","version"],"type":"object"},"id":{"format":"uuid","type":"string"},"name":{"type":"string"},"organizationId":{"format":"uuid","type":"string"},"preheader":{"type":"string"},"subject":{"type":"string"},"updatedAt":{"format":"date-time","type":"string"}},"required":["createdAt","createdBy","document","id","name","organizationId","preheader","subject","updatedAt"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/emails/templates/{id}":{"delete":{"operationId":"DELETE /v1/emails/templates/{id}","summary":"Deletes an email template.","tags":["emails"],"x-feature":"emails","x-action":"delete","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"204":{"description":"Done, with no content."},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"get":{"operationId":"GET /v1/emails/templates/{id}","summary":"Returns an email template with its document.","tags":["emails"],"x-feature":"emails","x-action":"read","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"createdAt":{"format":"date-time","type":"string"},"createdBy":{"format":"uuid","type":"string"},"document":{"properties":{"rows":{"items":{"properties":{"columns":{"items":{"properties":{"blocks":{"items":{"properties":{"html":{"type":"string"},"id":{"type":"string"},"type":{"type":"string"},"unsubscribeLabel":{"type":"string"}},"required":["id","html","type","unsubscribeLabel"],"type":"object"},"type":"array"},"id":{"type":"string"}},"required":["id","blocks"],"type":"object"},"type":"array"},"id":{"type":"string"},"widths":{"items":{"type":"integer"},"type":"array"}},"required":["id","widths","columns"],"type":"object"},"type":"array"}},"required":["rows"],"type":"object"},"id":{"format":"uuid","type":"string"},"name":{"type":"string"},"organizationId":{"format":"uuid","type":"string"},"preheader":{"type":"string"},"subject":{"type":"string"},"updatedAt":{"format":"date-time","type":"string"}},"required":["id","organizationId","name","subject","preheader","document","createdBy","createdAt","updatedAt"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"patch":{"operationId":"PATCH /v1/emails/templates/{id}","summary":"Changes an email template.","tags":["emails"],"x-feature":"emails","x-action":"update","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"name":{"type":"string","minLength":1,"maxLength":120},"subject":{"type":"string","maxLength":300},"preheader":{"type":"string","maxLength":300},"document":{"type":"object","properties":{"version":{"default":1,"type":"number","const":1},"settings":{"default":{"backdropColor":"#f4f4f5","contentColor":"#ffffff","width":600,"fontFamily":"Arial","headingFontFamily":"Arial","fontSize":16,"lineHeight":1.5,"textColor":"#1f2937","headingColor":"#111827","linkColor":"#2563eb","primaryColor":"#2563eb","onPrimaryColor":"#ffffff","radius":0,"outerPadding":24},"type":"object","properties":{"backdropColor":{"default":"#f4f4f5","type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"contentColor":{"default":"#ffffff","type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"width":{"default":600,"type":"integer","minimum":320,"maximum":900},"fontFamily":{"default":"Arial","type":"string","maxLength":60},"headingFontFamily":{"default":"Arial","type":"string","maxLength":60},"fontSize":{"default":16,"type":"integer","minimum":0,"maximum":40},"lineHeight":{"default":1.5,"type":"number","minimum":0.8,"maximum":3},"textColor":{"default":"#1f2937","type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"headingColor":{"default":"#111827","type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"linkColor":{"default":"#2563eb","type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"primaryColor":{"default":"#2563eb","type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"onPrimaryColor":{"default":"#ffffff","type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"radius":{"default":0,"type":"integer","minimum":0,"maximum":40},"outerPadding":{"default":24,"type":"integer","minimum":0,"maximum":120}}},"header":{"default":{"show":true,"placement":"outside","color":null,"linkColor":null,"backgroundColor":null,"fontSize":12,"padding":{"top":12,"right":25,"bottom":12,"left":25},"presetId":null,"custom":null},"type":"object","properties":{"show":{"default":true,"type":"boolean"},"placement":{"default":"outside","type":"string","enum":["inside","outside"]},"color":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"linkColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"backgroundColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"fontSize":{"default":12,"type":"integer","minimum":0,"maximum":24},"padding":{"default":{"top":12,"right":25,"bottom":12,"left":25},"type":"object","properties":{"top":{"type":"integer","minimum":0,"maximum":200},"right":{"type":"integer","minimum":0,"maximum":200},"bottom":{"type":"integer","minimum":0,"maximum":200},"left":{"type":"integer","minimum":0,"maximum":200}},"required":["top","right","bottom","left"]},"presetId":{"default":null,"anyOf":[{"type":"string","maxLength":40},{"type":"null"}]},"custom":{"default":null,"anyOf":[{"type":"object","properties":{"text":{"default":"","type":"string","maxLength":300},"linkLabel":{"default":"","type":"string","maxLength":60}}},{"type":"null"}]}}},"footer":{"default":{"placement":"inside","color":null,"linkColor":null,"backgroundColor":null,"fontSize":12,"padding":{"top":12,"right":25,"bottom":12,"left":25},"align":"center","presetId":null,"custom":null},"type":"object","properties":{"placement":{"default":"inside","type":"string","enum":["inside","outside"]},"color":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"linkColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"backgroundColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"fontSize":{"default":12,"type":"integer","minimum":0,"maximum":24},"padding":{"default":{"top":12,"right":25,"bottom":12,"left":25},"type":"object","properties":{"top":{"type":"integer","minimum":0,"maximum":200},"right":{"type":"integer","minimum":0,"maximum":200},"bottom":{"type":"integer","minimum":0,"maximum":200},"left":{"type":"integer","minimum":0,"maximum":200}},"required":["top","right","bottom","left"]},"align":{"default":"center","type":"string","enum":["left","center","right"]},"presetId":{"default":null,"anyOf":[{"type":"string","maxLength":40},{"type":"null"}]},"custom":{"default":null,"anyOf":[{"type":"object","properties":{"html":{"default":"","type":"string","maxLength":50000},"unsubscribeLabel":{"type":"string","minLength":1,"maxLength":100},"showAddress":{"default":true,"type":"boolean"}},"required":["unsubscribeLabel"]},{"type":"null"}]}}},"rows":{"maxItems":100,"type":"array","items":{"type":"object","properties":{"id":{"type":"string","minLength":1,"maxLength":40},"columns":{"minItems":1,"maxItems":4,"type":"array","items":{"type":"object","properties":{"id":{"type":"string","minLength":1,"maxLength":40},"blocks":{"maxItems":60,"type":"array","items":{"oneOf":[{"type":"object","properties":{"type":{"type":"string","const":"heading"},"id":{"type":"string","minLength":1,"maxLength":40},"padding":{"default":{"top":10,"right":25,"bottom":10,"left":25},"type":"object","properties":{"top":{"type":"integer","minimum":0,"maximum":200},"right":{"type":"integer","minimum":0,"maximum":200},"bottom":{"type":"integer","minimum":0,"maximum":200},"left":{"type":"integer","minimum":0,"maximum":200}},"required":["top","right","bottom","left"]},"backgroundColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"hideOn":{"default":null,"anyOf":[{"type":"string","enum":["mobile","desktop"]},{"type":"null"}]},"fontFamily":{"default":null,"anyOf":[{"type":"string","maxLength":60,"pattern":"^[\\p{L}\\p{N} '-]+$"},{"type":"null"}]},"fontSize":{"default":null,"anyOf":[{"type":"integer","minimum":0,"maximum":96},{"type":"null"}]},"color":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"lineHeight":{"default":null,"anyOf":[{"type":"number","minimum":0.8,"maximum":3},{"type":"null"}]},"letterSpacing":{"default":0,"type":"number","minimum":-5,"maximum":20},"align":{"default":"left","type":"string","enum":["left","center","right"]},"html":{"type":"string","maxLength":50000},"level":{"default":1,"anyOf":[{"type":"number","const":1},{"type":"number","const":2},{"type":"number","const":3}]},"fontWeight":{"default":700,"type":"integer","minimum":100,"maximum":900}},"required":["type","id","html"]},{"type":"object","properties":{"type":{"type":"string","const":"text"},"id":{"type":"string","minLength":1,"maxLength":40},"padding":{"default":{"top":10,"right":25,"bottom":10,"left":25},"type":"object","properties":{"top":{"type":"integer","minimum":0,"maximum":200},"right":{"type":"integer","minimum":0,"maximum":200},"bottom":{"type":"integer","minimum":0,"maximum":200},"left":{"type":"integer","minimum":0,"maximum":200}},"required":["top","right","bottom","left"]},"backgroundColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"hideOn":{"default":null,"anyOf":[{"type":"string","enum":["mobile","desktop"]},{"type":"null"}]},"fontFamily":{"default":null,"anyOf":[{"type":"string","maxLength":60,"pattern":"^[\\p{L}\\p{N} '-]+$"},{"type":"null"}]},"fontSize":{"default":null,"anyOf":[{"type":"integer","minimum":0,"maximum":96},{"type":"null"}]},"color":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"lineHeight":{"default":null,"anyOf":[{"type":"number","minimum":0.8,"maximum":3},{"type":"null"}]},"letterSpacing":{"default":0,"type":"number","minimum":-5,"maximum":20},"align":{"default":"left","type":"string","enum":["left","center","right"]},"html":{"type":"string","maxLength":50000}},"required":["type","id","html"]},{"type":"object","properties":{"type":{"type":"string","const":"button"},"id":{"type":"string","minLength":1,"maxLength":40},"padding":{"default":{"top":10,"right":25,"bottom":10,"left":25},"type":"object","properties":{"top":{"type":"integer","minimum":0,"maximum":200},"right":{"type":"integer","minimum":0,"maximum":200},"bottom":{"type":"integer","minimum":0,"maximum":200},"left":{"type":"integer","minimum":0,"maximum":200}},"required":["top","right","bottom","left"]},"backgroundColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"hideOn":{"default":null,"anyOf":[{"type":"string","enum":["mobile","desktop"]},{"type":"null"}]},"label":{"type":"string","maxLength":200},"url":{"type":"string","maxLength":2000},"align":{"default":"center","type":"string","enum":["left","center","right"]},"buttonColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"textColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"fontFamily":{"default":null,"anyOf":[{"type":"string","maxLength":60,"pattern":"^[\\p{L}\\p{N} '-]+$"},{"type":"null"}]},"fontSize":{"default":16,"type":"integer","minimum":0,"maximum":48},"fontWeight":{"default":600,"type":"integer","minimum":100,"maximum":900},"radius":{"default":6,"type":"integer","minimum":0,"maximum":100},"innerPadding":{"default":{"vertical":12,"horizontal":24},"type":"object","properties":{"vertical":{"type":"integer","minimum":0,"maximum":60},"horizontal":{"type":"integer","minimum":0,"maximum":120}},"required":["vertical","horizontal"]},"borderColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"borderWidth":{"default":0,"type":"integer","minimum":0,"maximum":10},"fullWidth":{"default":false,"type":"boolean"}},"required":["type","id","label","url"]},{"type":"object","properties":{"type":{"type":"string","const":"image"},"id":{"type":"string","minLength":1,"maxLength":40},"padding":{"default":{"top":10,"right":25,"bottom":10,"left":25},"type":"object","properties":{"top":{"type":"integer","minimum":0,"maximum":200},"right":{"type":"integer","minimum":0,"maximum":200},"bottom":{"type":"integer","minimum":0,"maximum":200},"left":{"type":"integer","minimum":0,"maximum":200}},"required":["top","right","bottom","left"]},"backgroundColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"hideOn":{"default":null,"anyOf":[{"type":"string","enum":["mobile","desktop"]},{"type":"null"}]},"src":{"type":"string","maxLength":2000},"alt":{"default":"","type":"string","maxLength":300},"url":{"default":"","type":"string","maxLength":2000},"width":{"default":100,"type":"integer","minimum":5,"maximum":100},"align":{"default":"center","type":"string","enum":["left","center","right"]},"radius":{"default":0,"type":"integer","minimum":0,"maximum":200}},"required":["type","id","src"]},{"type":"object","properties":{"type":{"type":"string","const":"divider"},"id":{"type":"string","minLength":1,"maxLength":40},"padding":{"default":{"top":10,"right":25,"bottom":10,"left":25},"type":"object","properties":{"top":{"type":"integer","minimum":0,"maximum":200},"right":{"type":"integer","minimum":0,"maximum":200},"bottom":{"type":"integer","minimum":0,"maximum":200},"left":{"type":"integer","minimum":0,"maximum":200}},"required":["top","right","bottom","left"]},"backgroundColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"hideOn":{"default":null,"anyOf":[{"type":"string","enum":["mobile","desktop"]},{"type":"null"}]},"color":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"thickness":{"default":1,"type":"integer","minimum":0,"maximum":20},"style":{"default":"solid","type":"string","enum":["solid","dashed","dotted"]},"width":{"default":100,"type":"integer","minimum":5,"maximum":100},"align":{"default":"center","type":"string","enum":["left","center","right"]}},"required":["type","id"]},{"type":"object","properties":{"type":{"type":"string","const":"spacer"},"id":{"type":"string","minLength":1,"maxLength":40},"padding":{"default":{"top":10,"right":25,"bottom":10,"left":25},"type":"object","properties":{"top":{"type":"integer","minimum":0,"maximum":200},"right":{"type":"integer","minimum":0,"maximum":200},"bottom":{"type":"integer","minimum":0,"maximum":200},"left":{"type":"integer","minimum":0,"maximum":200}},"required":["top","right","bottom","left"]},"backgroundColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"hideOn":{"default":null,"anyOf":[{"type":"string","enum":["mobile","desktop"]},{"type":"null"}]},"height":{"default":24,"type":"integer","minimum":0,"maximum":400}},"required":["type","id"]},{"type":"object","properties":{"type":{"type":"string","const":"social"},"id":{"type":"string","minLength":1,"maxLength":40},"padding":{"default":{"top":10,"right":25,"bottom":10,"left":25},"type":"object","properties":{"top":{"type":"integer","minimum":0,"maximum":200},"right":{"type":"integer","minimum":0,"maximum":200},"bottom":{"type":"integer","minimum":0,"maximum":200},"left":{"type":"integer","minimum":0,"maximum":200}},"required":["top","right","bottom","left"]},"backgroundColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"hideOn":{"default":null,"anyOf":[{"type":"string","enum":["mobile","desktop"]},{"type":"null"}]},"links":{"maxItems":10,"type":"array","items":{"type":"object","properties":{"network":{"type":"string","enum":["facebook","instagram","linkedin","x","youtube","tiktok","whatsapp","threads","discord","pinterest","github","phone","web"]},"url":{"type":"string","maxLength":2000}},"required":["network","url"]}},"iconSize":{"default":28,"type":"integer","minimum":0,"maximum":64},"gap":{"default":8,"type":"integer","minimum":0,"maximum":40},"iconStyle":{"default":"filled","type":"string","enum":["filled","plain"]},"iconColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"iconRadius":{"default":4,"type":"integer","minimum":0,"maximum":32},"align":{"default":"center","type":"string","enum":["left","center","right"]}},"required":["type","id","links"]},{"type":"object","properties":{"type":{"type":"string","const":"html"},"id":{"type":"string","minLength":1,"maxLength":40},"padding":{"default":{"top":10,"right":25,"bottom":10,"left":25},"type":"object","properties":{"top":{"type":"integer","minimum":0,"maximum":200},"right":{"type":"integer","minimum":0,"maximum":200},"bottom":{"type":"integer","minimum":0,"maximum":200},"left":{"type":"integer","minimum":0,"maximum":200}},"required":["top","right","bottom","left"]},"backgroundColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"hideOn":{"default":null,"anyOf":[{"type":"string","enum":["mobile","desktop"]},{"type":"null"}]},"html":{"type":"string","maxLength":100000}},"required":["type","id","html"]},{"type":"object","properties":{"type":{"type":"string","const":"catalog"},"id":{"type":"string","minLength":1,"maxLength":40},"padding":{"default":{"top":10,"right":25,"bottom":10,"left":25},"type":"object","properties":{"top":{"type":"integer","minimum":0,"maximum":200},"right":{"type":"integer","minimum":0,"maximum":200},"bottom":{"type":"integer","minimum":0,"maximum":200},"left":{"type":"integer","minimum":0,"maximum":200}},"required":["top","right","bottom","left"]},"backgroundColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"hideOn":{"default":null,"anyOf":[{"type":"string","enum":["mobile","desktop"]},{"type":"null"}]},"items":{"maxItems":12,"type":"array","items":{"type":"object","properties":{"kind":{"type":"string","enum":["service","package"]},"id":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},"url":{"default":"","type":"string","maxLength":2000}},"required":["kind","id"]}},"layout":{"default":"grid","type":"string","enum":["grid","list"]},"columns":{"default":2,"anyOf":[{"type":"number","const":1},{"type":"number","const":2},{"type":"number","const":3}]},"gap":{"default":16,"type":"integer","minimum":0,"maximum":40},"currency":{"default":null,"anyOf":[{"type":"string","pattern":"^[A-Z]{3}$"},{"type":"null"}]},"textAlign":{"default":"left","type":"string","enum":["left","center","right"]},"fontFamily":{"default":null,"anyOf":[{"type":"string","maxLength":60,"pattern":"^[\\p{L}\\p{N} '-]+$"},{"type":"null"}]},"cardColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"cardBorderColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"cardBorderWidth":{"default":1,"type":"integer","minimum":0,"maximum":10},"cardRadius":{"default":8,"type":"integer","minimum":0,"maximum":40},"cardPadding":{"default":16,"type":"integer","minimum":0,"maximum":60},"showImage":{"default":true,"type":"boolean"},"imageRatio":{"default":"square","type":"string","enum":["square","landscape","portrait","original"]},"imageRadius":{"default":4,"type":"integer","minimum":0,"maximum":40},"nameFontFamily":{"default":null,"anyOf":[{"type":"string","maxLength":60,"pattern":"^[\\p{L}\\p{N} '-]+$"},{"type":"null"}]},"nameFontSize":{"default":18,"type":"integer","minimum":0,"maximum":48},"nameFontWeight":{"default":700,"type":"integer","minimum":100,"maximum":900},"nameColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"showDescription":{"default":true,"type":"boolean"},"descriptionLength":{"default":120,"type":"integer","minimum":20,"maximum":600},"descriptionFontSize":{"default":14,"type":"integer","minimum":0,"maximum":32},"descriptionColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"showPrice":{"default":true,"type":"boolean"},"showOriginalPrice":{"default":true,"type":"boolean"},"priceFontSize":{"default":18,"type":"integer","minimum":0,"maximum":48},"priceFontWeight":{"default":700,"type":"integer","minimum":100,"maximum":900},"priceColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"showButton":{"default":true,"type":"boolean"},"buttonLabel":{"default":"","type":"string","maxLength":80},"buttonUrl":{"default":"","type":"string","maxLength":2000},"linkTo":{"default":"item","type":"string","enum":["item","catalogPage"]},"catalogPageId":{"default":null,"anyOf":[{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},{"type":"null"}]},"buttonColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"buttonTextColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"buttonFontSize":{"default":14,"type":"integer","minimum":0,"maximum":32},"buttonRadius":{"default":6,"type":"integer","minimum":0,"maximum":40},"buttonFullWidth":{"default":true,"type":"boolean"}},"required":["type","id","items"]},{"type":"object","properties":{"type":{"type":"string","const":"card"},"id":{"type":"string","minLength":1,"maxLength":40},"padding":{"default":{"top":10,"right":25,"bottom":10,"left":25},"type":"object","properties":{"top":{"type":"integer","minimum":0,"maximum":200},"right":{"type":"integer","minimum":0,"maximum":200},"bottom":{"type":"integer","minimum":0,"maximum":200},"left":{"type":"integer","minimum":0,"maximum":200}},"required":["top","right","bottom","left"]},"backgroundColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"hideOn":{"default":null,"anyOf":[{"type":"string","enum":["mobile","desktop"]},{"type":"null"}]},"src":{"type":"string","maxLength":2000},"alt":{"default":"","type":"string","maxLength":300},"imagePosition":{"default":"left","type":"string","enum":["top","left","right"]},"imageWidth":{"default":40,"type":"integer","minimum":20,"maximum":70},"imageRatio":{"default":"landscape","type":"string","enum":["original","square","landscape","portrait"]},"imageRadius":{"default":8,"type":"integer","minimum":0,"maximum":200},"imageBleed":{"default":false,"type":"boolean"},"title":{"default":"","type":"string","maxLength":200},"html":{"default":"","type":"string","maxLength":20000},"url":{"default":"","type":"string","maxLength":2000},"titleFontSize":{"default":20,"type":"integer","minimum":10,"maximum":72},"titleColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"textColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"fontFamily":{"default":null,"anyOf":[{"type":"string","maxLength":60,"pattern":"^[\\p{L}\\p{N} '-]+$"},{"type":"null"}]},"textAlign":{"default":"left","type":"string","enum":["left","center","right"]},"verticalAlign":{"default":"middle","type":"string","enum":["top","middle"]},"cardColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"borderColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"borderWidth":{"default":1,"type":"integer","minimum":0,"maximum":10},"radius":{"default":12,"type":"integer","minimum":0,"maximum":60},"cardPadding":{"default":16,"type":"integer","minimum":0,"maximum":80},"gap":{"default":16,"type":"integer","minimum":0,"maximum":80}},"required":["type","id","src"]}]}},"backgroundColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"padding":{"default":{"top":0,"right":0,"bottom":0,"left":0},"type":"object","properties":{"top":{"type":"integer","minimum":0,"maximum":200},"right":{"type":"integer","minimum":0,"maximum":200},"bottom":{"type":"integer","minimum":0,"maximum":200},"left":{"type":"integer","minimum":0,"maximum":200}},"required":["top","right","bottom","left"]},"radius":{"default":0,"type":"integer","minimum":0,"maximum":100},"verticalAlign":{"default":"top","type":"string","enum":["top","middle","bottom"]}},"required":["id","blocks"]}},"widths":{"minItems":1,"maxItems":4,"type":"array","items":{"type":"number","minimum":10,"maximum":100}},"backgroundColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"backgroundImage":{"default":"","type":"string","maxLength":2000},"fullWidth":{"default":false,"type":"boolean"},"padding":{"default":{"top":10,"right":0,"bottom":10,"left":0},"type":"object","properties":{"top":{"type":"integer","minimum":0,"maximum":200},"right":{"type":"integer","minimum":0,"maximum":200},"bottom":{"type":"integer","minimum":0,"maximum":200},"left":{"type":"integer","minimum":0,"maximum":200}},"required":["top","right","bottom","left"]},"radius":{"default":0,"type":"integer","minimum":0,"maximum":100},"borderColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"borderWidth":{"default":0,"type":"integer","minimum":0,"maximum":10},"stackOnMobile":{"default":true,"type":"boolean"},"hideOn":{"default":null,"anyOf":[{"type":"string","enum":["mobile","desktop"]},{"type":"null"}]}},"required":["id","columns","widths"]}}},"required":["rows"]}}}}}},"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/emails/templates/{id}/duplicate":{"post":{"operationId":"POST /v1/emails/templates/{id}/duplicate","summary":"Copies an email template.","tags":["emails"],"x-feature":"emails","x-action":"create","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"name":{"type":"string","minLength":1,"maxLength":120}},"required":["name"]}}}},"responses":{"201":{"description":"Success.","content":{"application/json":{"schema":{}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/emails/test":{"post":{"operationId":"POST /v1/emails/test","summary":"Sends a test of a template or campaign to members’ addresses.","tags":["emails"],"x-feature":"emails","x-action":"create","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"templateId":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},"campaignId":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},"emails":{"minItems":1,"maxItems":5,"type":"array","items":{"type":"string","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,}$"}},"contactId":{"anyOf":[{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},{"type":"null"}]},"kind":{"default":"marketing","type":"string","enum":["marketing","transactional"]}},"required":["emails"]}}}},"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"data":{"items":{"properties":{"email":{"format":"email","type":"string"},"error":{"type":"null"},"id":{"format":"uuid","type":"string"},"status":{"type":"string"}},"required":["id","email","status","error"],"type":"object"},"type":"array"}},"required":["data"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/emails/theme":{"get":{"operationId":"GET /v1/emails/theme","summary":"The organization’s theme, for emails that follow it.","tags":["emails"],"x-feature":"emails","x-action":"read","responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/emails/variables":{"get":{"operationId":"GET /v1/emails/variables","summary":"The `{{...}}` variables an email can show: contact, company and organization.","tags":["emails"],"x-feature":"emails","x-action":"read","responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/files":{"get":{"operationId":"GET /v1/files","summary":"Lists the organization’s files, by kind, with their size.","tags":["files"],"x-feature":"files","x-action":"read","parameters":[{"name":"page","in":"query","required":false,"schema":{"default":1,"type":"integer","minimum":1,"maximum":9007199254740991}},{"name":"pageSize","in":"query","required":false,"schema":{"default":48,"type":"integer","minimum":1,"maximum":100}},{"name":"group","in":"query","required":false,"schema":{"type":"string","enum":["library","branding","shareImages","catalog","sharedFiles","approvals","messages","socialPosts","other"]}},{"name":"type","in":"query","required":false,"schema":{"type":"string","enum":["image","pdf","document","other"]}},{"name":"q","in":"query","required":false,"schema":{"type":"string","maxLength":200}},{"name":"sort","in":"query","required":false,"schema":{"default":"newest","type":"string","enum":["newest","oldest","largest","smallest","name"]}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"data":{"items":{"properties":{"bytes":{"type":"integer"},"contentType":{"type":"string"},"createdAt":{"format":"date-time","type":"string"},"deletable":{"type":"boolean"},"group":{"type":"string"},"id":{"format":"uuid","type":["null","string"]},"key":{"type":"string"},"name":{"type":"string"},"owner":{"properties":{"kind":{"type":"string"},"purpose":{"type":"string"}},"required":["kind","purpose"],"type":["null","object"]},"updatedAt":{"format":"date-time","type":"string"},"url":{"format":"uri","type":"string"},"usedIn":{"items":{"properties":{"id":{"format":"uuid","type":"string"},"kind":{"type":"string"},"name":{"type":"string"}},"required":["kind","id","name"],"type":"object"},"type":"array"}},"required":["id","key","name","group","contentType","bytes","url","deletable","owner","usedIn","createdAt","updatedAt"],"type":"object"},"type":"array"},"page":{"type":"integer"},"pageSize":{"type":"integer"},"total":{"type":"integer"}},"required":["page","pageSize","total","data"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"post":{"operationId":"POST /v1/files","summary":"Uploads a file to the library.","tags":["files"],"x-feature":"files","x-action":"create","requestBody":{"required":true,"content":{"multipart/form-data":{"schema":{"type":"object","required":["file"],"properties":{"file":{"type":"string","format":"binary"}}}}}},"responses":{"201":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"bytes":{"type":"integer"},"contentType":{"type":"string"},"createdAt":{"format":"date-time","type":"string"},"deletable":{"type":"boolean"},"group":{"type":"string"},"id":{"format":"uuid","type":"string"},"key":{"type":"string"},"name":{"type":"string"},"owner":{"type":"null"},"updatedAt":{"format":"date-time","type":"string"},"url":{"format":"uri","type":"string"},"usedIn":{"type":"array"}},"required":["id","key","name","group","contentType","bytes","url","deletable","owner","usedIn","createdAt","updatedAt"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/files/{id}":{"get":{"operationId":"GET /v1/files/{id}","summary":"Returns a file with where it is used.","tags":["files"],"x-feature":"files","x-action":"read","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"bytes":{"type":"integer"},"contentType":{"type":"string"},"createdAt":{"format":"date-time","type":"string"},"deletable":{"type":"boolean"},"group":{"type":"string"},"id":{"format":"uuid","type":"string"},"key":{"type":"string"},"name":{"type":"string"},"owner":{"type":"null"},"updatedAt":{"format":"date-time","type":"string"},"url":{"format":"uri","type":"string"},"usedIn":{"items":{"properties":{"id":{"format":"uuid","type":"string"},"kind":{"type":"string"},"name":{"type":"string"}},"required":["kind","id","name"],"type":"object"},"type":"array"}},"required":["id","key","name","group","contentType","bytes","url","deletable","owner","usedIn","createdAt","updatedAt"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"patch":{"operationId":"PATCH /v1/files/{id}","summary":"Renames a library file.","tags":["files"],"x-feature":"files","x-action":"update","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"name":{"type":"string","minLength":1,"maxLength":200}},"required":["name"]}}}},"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"bytes":{"type":"integer"},"contentType":{"type":"string"},"createdAt":{"format":"date-time","type":"string"},"deletable":{"type":"boolean"},"group":{"type":"string"},"id":{"format":"uuid","type":"string"},"key":{"type":"string"},"name":{"type":"string"},"owner":{"type":"null"},"updatedAt":{"format":"date-time","type":"string"},"url":{"format":"uri","type":"string"},"usedIn":{"type":"array"}},"required":["id","key","name","group","contentType","bytes","url","deletable","owner","usedIn","createdAt","updatedAt"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/files/delete":{"post":{"operationId":"POST /v1/files/delete","summary":"Deletes one or more library files.","tags":["files"],"x-feature":"files","x-action":"delete","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"ids":{"minItems":1,"maxItems":100,"type":"array","items":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"}}},"required":["ids"]}}}},"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"deleted":{"type":"integer"},"freedBytes":{"type":"integer"}},"required":["deleted","freedBytes"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/files/summary":{"get":{"operationId":"GET /v1/files/summary","summary":"Storage used against the plan, by kind of file.","tags":["files"],"x-feature":"files","x-action":"read","responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"groups":{"properties":{"approvals":{"properties":{"bytes":{"type":"integer"},"files":{"type":"integer"}},"required":["files","bytes"],"type":"object"},"branding":{"properties":{"bytes":{"type":"integer"},"files":{"type":"integer"}},"required":["files","bytes"],"type":"object"},"catalog":{"properties":{"bytes":{"type":"integer"},"files":{"type":"integer"}},"required":["files","bytes"],"type":"object"},"library":{"properties":{"bytes":{"type":"integer"},"files":{"type":"integer"}},"required":["files","bytes"],"type":"object"},"messages":{"properties":{"bytes":{"type":"integer"},"files":{"type":"integer"}},"required":["files","bytes"],"type":"object"},"other":{"properties":{"bytes":{"type":"integer"},"files":{"type":"integer"}},"required":["files","bytes"],"type":"object"},"shareImages":{"properties":{"bytes":{"type":"integer"},"files":{"type":"integer"}},"required":["files","bytes"],"type":"object"},"sharedFiles":{"properties":{"bytes":{"type":"integer"},"files":{"type":"integer"}},"required":["files","bytes"],"type":"object"},"socialPosts":{"properties":{"bytes":{"type":"integer"},"files":{"type":"integer"}},"required":["files","bytes"],"type":"object"}},"required":["library","branding","shareImages","catalog","sharedFiles","approvals","messages","socialPosts","other"],"type":"object"},"limit":{"type":"integer"},"maxUploadBytes":{"type":"integer"},"used":{"type":"integer"}},"required":["used","limit","groups","maxUploadBytes"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/form-defaults":{"get":{"operationId":"GET /v1/form-defaults","summary":"What new forms start with.","tags":["forms"],"x-feature":"forms","x-action":"read","responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"put":{"operationId":"PUT /v1/form-defaults","summary":"Changes what new forms start with.","tags":["forms"],"x-feature":"forms","x-action":"update","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"fields":{"anyOf":[{"maxItems":50,"type":"array","items":{"type":"object","properties":{"key":{"type":"string","pattern":"^[a-z][a-z0-9_]{0,39}$"},"type":{"type":"string","enum":["text","textarea","email","phone","number","date","url","select","radio","checkboxes","checkbox","hidden"]},"label":{"type":"string","minLength":1,"maxLength":200},"placeholder":{"anyOf":[{"type":"string","maxLength":200},{"type":"null"}]},"help":{"anyOf":[{"type":"string","maxLength":500},{"type":"null"}]},"required":{"default":false,"type":"boolean"},"options":{"default":[],"maxItems":100,"type":"array","items":{"type":"string","minLength":1,"maxLength":200}},"min":{"type":["number","null"]},"max":{"type":["number","null"]},"defaultValue":{"anyOf":[{"type":"string","maxLength":500},{"type":"null"}]},"width":{"default":"full","type":"string","enum":["full","half"]},"mapTo":{"anyOf":[{"anyOf":[{"type":"string","enum":["firstName","lastName","fullName","email","phone","jobTitle","department","birthday","address","city","state","postalCode","country","marketingOptIn"]},{"type":"string","pattern":"^custom:[a-zA-Z0-9_]{1,64}$"}]},{"type":"null"}]}},"required":["key","type","label"]}},{"type":"null"}]},"submitLabel":{"anyOf":[{"type":"string","maxLength":60},{"type":"null"}]},"successMessage":{"anyOf":[{"type":"string","maxLength":1000},{"type":"null"}]},"redirectUrl":{"anyOf":[{"anyOf":[{"type":"string","maxLength":2000,"format":"uri"},{"type":"null"}]},{"type":"string","const":""}]},"requireCaptcha":{"type":"boolean"},"contactMode":{"type":"string","enum":["off","create_or_update","create_only"]}},"required":["fields","requireCaptcha","contactMode"]}}}},"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"contactMode":{"type":"string"},"fields":{"items":{"properties":{"defaultValue":{"type":"null"},"help":{"type":"null"},"key":{"type":"string"},"label":{"type":"string"},"mapTo":{"type":"string"},"max":{"type":"null"},"min":{"type":"null"},"options":{"type":"array"},"placeholder":{"type":"null"},"required":{"type":"boolean"},"type":{"type":"string"},"width":{"type":"string"}},"required":["key","max","min","help","type","label","mapTo","width","options","required","placeholder","defaultValue"],"type":"object"},"type":"array"},"redirectUrl":{"type":"null"},"requireCaptcha":{"type":"boolean"},"submitLabel":{"type":"string"},"successMessage":{"type":"string"}},"required":["fields","submitLabel","successMessage","redirectUrl","requireCaptcha","contactMode"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/forms":{"get":{"operationId":"GET /v1/forms","summary":"Lists the forms.","tags":["forms"],"x-feature":"forms","x-action":"read","responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"items":{"properties":{"actions":{"properties":{"listIds":{"items":{"format":"uuid","type":"string"},"type":"array"},"tagIds":{"items":{"format":"uuid","type":"string"},"type":"array"},"webhook":{"properties":{"enabled":{"type":"boolean"},"url":{"type":"string"}},"required":["url","enabled"],"type":"object"}},"required":["tagIds","listIds","webhook"],"type":"object"},"active":{"type":"boolean"},"contactMode":{"type":"string"},"contactOwnerId":{"format":"uuid","type":"string"},"createdAt":{"format":"date-time","type":"string"},"createdBy":{"format":"uuid","type":"string"},"description":{"type":"null"},"embedScriptUrl":{"format":"uri","type":"string"},"fields":{"items":{"properties":{"defaultValue":{"type":"null"},"help":{"type":"null"},"key":{"type":"string"},"label":{"type":"string"},"mapTo":{"type":"string"},"max":{"type":"null"},"min":{"type":"null"},"options":{"type":"array"},"placeholder":{"type":"null"},"required":{"type":"boolean"},"type":{"type":"string"},"width":{"type":"string"}},"required":["key","max","min","help","type","label","mapTo","width","options","required","placeholder","defaultValue"],"type":"object"},"type":"array"},"id":{"format":"uuid","type":"string"},"lastSubmissionAt":{"format":"date-time","type":"string"},"name":{"type":"string"},"notifyMemberIds":{"type":"array"},"publicId":{"type":"string"},"redirectUrl":{"type":"null"},"requireCaptcha":{"type":"boolean"},"submissionCount":{"type":"integer"},"submitLabel":{"type":"null"},"successMessage":{"type":"null"},"templateId":{"type":"null"},"theme":{"properties":{},"required":[],"type":"object"},"title":{"type":"null"},"updatedAt":{"format":"date-time","type":"string"},"updatedBy":{"format":"uuid","type":"string"},"url":{"format":"uri","type":"string"},"webhookSecret":{"type":"string"}},"required":["id","publicId","name","title","description","fields","submitLabel","successMessage","redirectUrl","requireCaptcha","contactMode","contactOwnerId","actions","webhookSecret","notifyMemberIds","templateId","theme","active","createdBy","updatedBy","createdAt","updatedAt","url","embedScriptUrl","submissionCount","lastSubmissionAt"],"type":"object"},"type":"array"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"post":{"operationId":"POST /v1/forms","summary":"Creates a form.","tags":["forms"],"x-feature":"forms","x-action":"create","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"name":{"type":"string","minLength":1,"maxLength":120},"title":{"anyOf":[{"type":"string","maxLength":200},{"type":"null"}]},"description":{"anyOf":[{"type":"string","maxLength":2000},{"type":"null"}]},"fields":{"maxItems":50,"type":"array","items":{"type":"object","properties":{"key":{"type":"string","pattern":"^[a-z][a-z0-9_]{0,39}$"},"type":{"type":"string","enum":["text","textarea","email","phone","number","date","url","select","radio","checkboxes","checkbox","hidden"]},"label":{"type":"string","minLength":1,"maxLength":200},"placeholder":{"anyOf":[{"type":"string","maxLength":200},{"type":"null"}]},"help":{"anyOf":[{"type":"string","maxLength":500},{"type":"null"}]},"required":{"default":false,"type":"boolean"},"options":{"default":[],"maxItems":100,"type":"array","items":{"type":"string","minLength":1,"maxLength":200}},"min":{"type":["number","null"]},"max":{"type":["number","null"]},"defaultValue":{"anyOf":[{"type":"string","maxLength":500},{"type":"null"}]},"width":{"default":"full","type":"string","enum":["full","half"]},"mapTo":{"anyOf":[{"anyOf":[{"type":"string","enum":["firstName","lastName","fullName","email","phone","jobTitle","department","birthday","address","city","state","postalCode","country","marketingOptIn"]},{"type":"string","pattern":"^custom:[a-zA-Z0-9_]{1,64}$"}]},{"type":"null"}]}},"required":["key","type","label"]}},"submitLabel":{"anyOf":[{"type":"string","maxLength":60},{"type":"null"}]},"successMessage":{"anyOf":[{"type":"string","maxLength":1000},{"type":"null"}]},"redirectUrl":{"anyOf":[{"anyOf":[{"type":"string","maxLength":2000,"format":"uri"},{"type":"null"}]},{"type":"string","const":""}]},"requireCaptcha":{"type":"boolean"},"contactMode":{"type":"string","enum":["off","create_or_update","create_only"]},"contactOwnerId":{"anyOf":[{"type":"string","minLength":1},{"type":"null"}]},"actions":{"default":{},"type":"object","properties":{"listIds":{"default":[],"maxItems":20,"type":"array","items":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"}},"tagIds":{"default":[],"maxItems":50,"type":"array","items":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"}},"webhook":{"default":{},"type":"object","properties":{"enabled":{"default":false,"type":"boolean"},"url":{"default":"","anyOf":[{"type":"string","maxLength":2000,"format":"uri"},{"type":"string","const":""}]}}}}},"notifyMemberIds":{"default":[],"maxItems":50,"type":"array","items":{"type":"string","minLength":1}},"templateId":{"anyOf":[{"type":"string","enum":["classic","modern","minimal","bold"]},{"type":"null"}]},"theme":{"default":{},"type":"object","properties":{"primaryColor":{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"accentColor":{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"backgroundColor":{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"textColor":{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"headingFont":{"type":"string","pattern":"^[A-Za-z0-9 ]{1,60}$"},"bodyFont":{"type":"string","pattern":"^[A-Za-z0-9 ]{1,60}$"},"coverImageUrl":{"type":"string","maxLength":2000,"format":"uri"},"cornerRadius":{"type":"string","enum":["none","small","medium","large"]}},"additionalProperties":false},"active":{"default":true,"type":"boolean"}},"required":["name"]}}}},"responses":{"201":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"actions":{"properties":{"listIds":{"items":{"format":"uuid","type":"string"},"type":"array"},"tagIds":{"items":{"format":"uuid","type":"string"},"type":"array"},"webhook":{"properties":{"enabled":{"type":"boolean"},"url":{"type":"string"}},"required":["enabled","url"],"type":"object"}},"required":["listIds","tagIds","webhook"],"type":"object"},"active":{"type":"boolean"},"contactMode":{"type":"string"},"contactOwnerId":{"format":"uuid","type":"string"},"createdAt":{"format":"date-time","type":"string"},"createdBy":{"format":"uuid","type":"string"},"description":{"type":"null"},"embedScriptUrl":{"format":"uri","type":"string"},"fields":{"items":{"properties":{"defaultValue":{"type":["null","string"]},"help":{"type":"null"},"key":{"type":"string"},"label":{"type":"string"},"mapTo":{"type":["null","string"]},"max":{"type":["integer","null"]},"min":{"type":["integer","null"]},"options":{"items":{"type":"string"},"type":"array"},"placeholder":{"type":"null"},"required":{"type":"boolean"},"type":{"type":"string"},"width":{"type":"string"}},"required":["defaultValue","help","key","label","mapTo","max","min","options","placeholder","required","type","width"],"type":"object"},"type":"array"},"id":{"format":"uuid","type":"string"},"lastSubmissionAt":{"type":"null"},"name":{"type":"string"},"notifyMemberIds":{"items":{"format":"uuid","type":"string"},"type":"array"},"publicId":{"type":"string"},"redirectUrl":{"format":"uri","type":["null","string"]},"requireCaptcha":{"type":"boolean"},"submissionCount":{"type":"integer"},"submitLabel":{"type":["null","string"]},"successMessage":{"type":["null","string"]},"templateId":{"type":"null"},"theme":{"properties":{},"required":[],"type":"object"},"title":{"type":["null","string"]},"updatedAt":{"format":"date-time","type":"string"},"updatedBy":{"format":"uuid","type":"string"},"url":{"format":"uri","type":"string"},"webhookSecret":{"type":"string"}},"required":["actions","active","contactMode","contactOwnerId","createdAt","createdBy","description","embedScriptUrl","fields","id","lastSubmissionAt","name","notifyMemberIds","publicId","redirectUrl","requireCaptcha","submissionCount","submitLabel","successMessage","templateId","theme","title","updatedAt","updatedBy","url","webhookSecret"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/forms/{id}":{"delete":{"operationId":"DELETE /v1/forms/{id}","summary":"Deletes a form and its submissions.","tags":["forms"],"x-feature":"forms","x-action":"delete","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"204":{"description":"Done, with no content."},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"get":{"operationId":"GET /v1/forms/{id}","summary":"Returns a form with its questions and settings.","tags":["forms"],"x-feature":"forms","x-action":"read","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"actions":{"properties":{"listIds":{"items":{"format":"uuid","type":"string"},"type":"array"},"tagIds":{"items":{"format":"uuid","type":"string"},"type":"array"},"webhook":{"properties":{"enabled":{"type":"boolean"},"url":{"type":"string"}},"required":["enabled","url"],"type":"object"}},"required":["listIds","tagIds","webhook"],"type":"object"},"active":{"type":"boolean"},"contactMode":{"type":"string"},"contactOwnerId":{"format":"uuid","type":"string"},"createdAt":{"format":"date-time","type":"string"},"createdBy":{"format":"uuid","type":"string"},"description":{"type":"null"},"embedScriptUrl":{"format":"uri","type":"string"},"fields":{"items":{"properties":{"defaultValue":{"type":["null","string"]},"help":{"type":"null"},"key":{"type":"string"},"label":{"type":"string"},"mapTo":{"type":["null","string"]},"max":{"type":["integer","null"]},"min":{"type":["integer","null"]},"options":{"items":{"type":"string"},"type":"array"},"placeholder":{"type":"null"},"required":{"type":"boolean"},"type":{"type":"string"},"width":{"type":"string"}},"required":["defaultValue","help","key","label","mapTo","max","min","options","placeholder","required","type","width"],"type":"object"},"type":"array"},"id":{"format":"uuid","type":"string"},"lastSubmissionAt":{"format":"date-time","type":"string"},"name":{"type":"string"},"notifyMemberIds":{"items":{"format":"uuid","type":"string"},"type":"array"},"publicId":{"type":"string"},"redirectUrl":{"format":"uri","type":["null","string"]},"requireCaptcha":{"type":"boolean"},"submissionCount":{"type":"integer"},"submitLabel":{"type":"null"},"successMessage":{"type":"null"},"templateId":{"type":"null"},"theme":{"properties":{},"required":[],"type":"object"},"title":{"type":["null","string"]},"updatedAt":{"format":"date-time","type":"string"},"updatedBy":{"format":"uuid","type":"string"},"url":{"format":"uri","type":"string"},"webhookSecret":{"type":"string"}},"required":["actions","active","contactMode","contactOwnerId","createdAt","createdBy","description","embedScriptUrl","fields","id","lastSubmissionAt","name","notifyMemberIds","publicId","redirectUrl","requireCaptcha","submissionCount","submitLabel","successMessage","templateId","theme","title","updatedAt","updatedBy","url","webhookSecret"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"patch":{"operationId":"PATCH /v1/forms/{id}","summary":"Changes a form: questions, look, what happens after answering.","tags":["forms"],"x-feature":"forms","x-action":"update","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"name":{"type":"string","minLength":1,"maxLength":120},"title":{"anyOf":[{"type":"string","maxLength":200},{"type":"null"}]},"description":{"anyOf":[{"type":"string","maxLength":2000},{"type":"null"}]},"fields":{"maxItems":50,"type":"array","items":{"type":"object","properties":{"key":{"type":"string","pattern":"^[a-z][a-z0-9_]{0,39}$"},"type":{"type":"string","enum":["text","textarea","email","phone","number","date","url","select","radio","checkboxes","checkbox","hidden"]},"label":{"type":"string","minLength":1,"maxLength":200},"placeholder":{"anyOf":[{"type":"string","maxLength":200},{"type":"null"}]},"help":{"anyOf":[{"type":"string","maxLength":500},{"type":"null"}]},"required":{"default":false,"type":"boolean"},"options":{"default":[],"maxItems":100,"type":"array","items":{"type":"string","minLength":1,"maxLength":200}},"min":{"type":["number","null"]},"max":{"type":["number","null"]},"defaultValue":{"anyOf":[{"type":"string","maxLength":500},{"type":"null"}]},"width":{"default":"full","type":"string","enum":["full","half"]},"mapTo":{"anyOf":[{"anyOf":[{"type":"string","enum":["firstName","lastName","fullName","email","phone","jobTitle","department","birthday","address","city","state","postalCode","country","marketingOptIn"]},{"type":"string","pattern":"^custom:[a-zA-Z0-9_]{1,64}$"}]},{"type":"null"}]}},"required":["key","type","label"]}},"submitLabel":{"anyOf":[{"type":"string","maxLength":60},{"type":"null"}]},"successMessage":{"anyOf":[{"type":"string","maxLength":1000},{"type":"null"}]},"redirectUrl":{"anyOf":[{"anyOf":[{"type":"string","maxLength":2000,"format":"uri"},{"type":"null"}]},{"type":"string","const":""}]},"requireCaptcha":{"type":"boolean"},"contactMode":{"type":"string","enum":["off","create_or_update","create_only"]},"contactOwnerId":{"anyOf":[{"type":"string","minLength":1},{"type":"null"}]},"actions":{"type":"object","properties":{"listIds":{"default":[],"maxItems":20,"type":"array","items":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"}},"tagIds":{"default":[],"maxItems":50,"type":"array","items":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"}},"webhook":{"default":{},"type":"object","properties":{"enabled":{"default":false,"type":"boolean"},"url":{"default":"","anyOf":[{"type":"string","maxLength":2000,"format":"uri"},{"type":"string","const":""}]}}}}},"notifyMemberIds":{"maxItems":50,"type":"array","items":{"type":"string","minLength":1}},"templateId":{"anyOf":[{"type":"string","enum":["classic","modern","minimal","bold"]},{"type":"null"}]},"theme":{"type":"object","properties":{"primaryColor":{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"accentColor":{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"backgroundColor":{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"textColor":{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"headingFont":{"type":"string","pattern":"^[A-Za-z0-9 ]{1,60}$"},"bodyFont":{"type":"string","pattern":"^[A-Za-z0-9 ]{1,60}$"},"coverImageUrl":{"type":"string","maxLength":2000,"format":"uri"},"cornerRadius":{"type":"string","enum":["none","small","medium","large"]}},"additionalProperties":false},"active":{"type":"boolean"}}}}}},"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"actions":{"properties":{"listIds":{"items":{"format":"uuid","type":"string"},"type":"array"},"tagIds":{"items":{"format":"uuid","type":"string"},"type":"array"},"webhook":{"properties":{"enabled":{"type":"boolean"},"url":{"type":"string"}},"required":["enabled","url"],"type":"object"}},"required":["listIds","tagIds","webhook"],"type":"object"},"active":{"type":"boolean"},"contactMode":{"type":"string"},"contactOwnerId":{"format":"uuid","type":"string"},"createdAt":{"format":"date-time","type":"string"},"createdBy":{"format":"uuid","type":"string"},"description":{"type":"null"},"embedScriptUrl":{"format":"uri","type":"string"},"fields":{"items":{"properties":{"defaultValue":{"type":["null","string"]},"help":{"type":"null"},"key":{"type":"string"},"label":{"type":"string"},"mapTo":{"type":["null","string"]},"max":{"type":["integer","null"]},"min":{"type":["integer","null"]},"options":{"items":{"type":"string"},"type":"array"},"placeholder":{"type":"null"},"required":{"type":"boolean"},"type":{"type":"string"},"width":{"type":"string"}},"required":["defaultValue","help","key","label","mapTo","max","min","options","placeholder","required","type","width"],"type":"object"},"type":"array"},"id":{"format":"uuid","type":"string"},"lastSubmissionAt":{"format":"date-time","type":["null","string"]},"name":{"type":"string"},"notifyMemberIds":{"items":{"format":"uuid","type":"string"},"type":"array"},"publicId":{"type":"string"},"redirectUrl":{"format":"uri","type":["null","string"]},"requireCaptcha":{"type":"boolean"},"submissionCount":{"type":"integer"},"submitLabel":{"type":"null"},"successMessage":{"type":"null"},"templateId":{"type":"null"},"theme":{"properties":{},"required":[],"type":"object"},"title":{"type":["null","string"]},"updatedAt":{"format":"date-time","type":"string"},"updatedBy":{"format":"uuid","type":"string"},"url":{"format":"uri","type":"string"},"webhookSecret":{"type":"string"}},"required":["actions","active","contactMode","contactOwnerId","createdAt","createdBy","description","embedScriptUrl","fields","id","lastSubmissionAt","name","notifyMemberIds","publicId","redirectUrl","requireCaptcha","submissionCount","submitLabel","successMessage","templateId","theme","title","updatedAt","updatedBy","url","webhookSecret"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/forms/{id}/submissions":{"get":{"operationId":"GET /v1/forms/{id}/submissions","summary":"Lists a form’s submissions.","tags":["forms"],"x-feature":"forms","x-action":"read","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}},{"name":"page","in":"query","required":false,"schema":{"default":1,"type":"integer","minimum":1,"maximum":9007199254740991}},{"name":"pageSize","in":"query","required":false,"schema":{"default":25,"type":"integer","minimum":1,"maximum":100}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"data":{"items":{"properties":{"answers":{"items":{"properties":{"key":{"type":"string"},"label":{"type":"string"},"type":{"type":"string"},"value":{"items":{"type":"string"},"type":["array","boolean","integer","null","string"]}},"required":["key","type","label","value"],"type":"object"},"type":"array"},"contact":{"properties":{"id":{"format":"uuid","type":"string"},"name":{"type":"string"}},"required":["id","name"],"type":["null","object"]},"contactId":{"format":"uuid","type":["null","string"]},"createdAt":{"format":"date-time","type":"string"},"formId":{"format":"uuid","type":"string"},"id":{"format":"uuid","type":"string"},"pageUrl":{"format":"uri","type":["null","string"]},"source":{"type":"string"},"webhookError":{"type":"null"},"webhookStatus":{"type":["integer","null"]}},"required":["id","formId","contactId","answers","source","pageUrl","webhookStatus","webhookError","createdAt","contact"],"type":"object"},"type":"array"},"page":{"type":"integer"},"pageSize":{"type":"integer"},"total":{"type":"integer"}},"required":["data","page","pageSize","total"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"post":{"operationId":"POST /v1/forms/{id}/submissions","summary":"Submits the form from the organization’s own systems, as a visitor would (Pro).","tags":["forms"],"x-feature":"forms","x-action":"create","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"answers":{"type":"object","propertyNames":{"type":"string"},"additionalProperties":{}}},"required":["answers"]}}}},"responses":{"201":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"contactId":{"format":"uuid","type":"string"},"id":{"format":"uuid","type":"string"}},"required":["id","contactId"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/forms/{id}/submissions/{submissionId}":{"delete":{"operationId":"DELETE /v1/forms/{id}/submissions/{submissionId}","summary":"Deletes one submission.","tags":["forms"],"x-feature":"forms","x-action":"delete","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}},{"name":"submissionId","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"204":{"description":"Done, with no content."},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"get":{"operationId":"GET /v1/forms/{id}/submissions/{submissionId}","summary":"Returns one submission with its answers.","tags":["forms"],"x-feature":"forms","x-action":"read","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}},{"name":"submissionId","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/forms/{id}/submissions/export":{"get":{"operationId":"GET /v1/forms/{id}/submissions/export","summary":"Downloads a form’s submissions as a CSV file.","tags":["forms"],"x-feature":"forms","x-action":"read","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/forms/{id}/webhook/test":{"post":{"operationId":"POST /v1/forms/{id}/webhook/test","summary":"Sends a made-up submission to the form’s webhook and says how it went.","tags":["forms"],"x-feature":"forms","x-action":"update","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"default":{},"type":"object","properties":{"url":{"type":"string","maxLength":2000,"format":"uri"}}}}}},"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"error":{"type":"null"},"status":{"type":"integer"}},"required":["status","error"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/forms/look":{"get":{"operationId":"GET /v1/forms/look","summary":"The look a form’s preview starts from; saves nothing.","tags":["forms"],"x-feature":"forms","x-action":"read","parameters":[{"name":"templateId","in":"query","required":false,"schema":{"type":"string","enum":["classic","modern","minimal","bold"]}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"organization":{"properties":{"language":{"type":"string"},"name":{"type":"string"}},"required":["name","language"],"type":"object"},"templateId":{"type":"string"},"theme":{"properties":{"accentColor":{"type":"string"},"backgroundColor":{"type":"string"},"bodyFont":{"type":"string"},"cornerRadius":{"type":"string"},"headingFont":{"type":"string"},"primaryColor":{"type":"string"},"textColor":{"type":"string"}},"required":["primaryColor","accentColor","backgroundColor","textColor","headingFont","bodyFont","cornerRadius"],"type":"object"}},"required":["organization","templateId","theme"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/invoice-defaults":{"get":{"operationId":"GET /v1/invoice-defaults","summary":"What new invoices start with: due date, texts, reminders.","tags":["invoices"],"x-feature":"invoices","x-action":"read","responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"acceptPayments":{"type":"boolean"},"digits":{"type":"integer"},"dueDays":{"type":"integer"},"issuer":{"type":"null"},"next":{"type":"integer"},"nextNumber":{"type":"string"},"notes":{"type":["null","string"]},"prefix":{"type":"string"},"reminders":{"properties":{"after":{"items":{"type":"integer"},"type":"array"},"before":{"items":{"type":"integer"},"type":"array"}},"required":["after","before"],"type":"object"},"taxPercent":{"type":["integer","null"]}},"required":["acceptPayments","digits","dueDays","issuer","next","nextNumber","notes","prefix","reminders","taxPercent"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"put":{"operationId":"PUT /v1/invoice-defaults","summary":"Changes what new invoices start with.","tags":["invoices"],"x-feature":"invoices","x-action":"update","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"prefix":{"type":"string","maxLength":20},"digits":{"type":"integer","minimum":1,"maximum":8},"next":{"type":"integer","minimum":1,"maximum":999999999},"dueDays":{"type":"integer","minimum":0,"maximum":365},"notes":{"anyOf":[{"type":"string","maxLength":10000},{"type":"null"}]},"taxPercent":{"anyOf":[{"type":"number","minimum":0,"maximum":100,"multipleOf":0.01},{"type":"null"}]},"reminders":{"type":"object","properties":{"before":{"maxItems":5,"type":"array","items":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991}},"after":{"maxItems":5,"type":"array","items":{"type":"integer","minimum":1,"maximum":120}}},"required":["before","after"]},"issuer":{"anyOf":[{"type":"object","properties":{"name":{"type":"string","minLength":1,"maxLength":200},"address":{"anyOf":[{"type":"string","maxLength":1000},{"type":"null"}]}},"required":["name"]},{"type":"null"}]},"acceptPayments":{"default":false,"type":"boolean"}},"required":["prefix","digits","next","dueDays","notes","taxPercent","reminders"]}}}},"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"acceptPayments":{"type":"boolean"},"digits":{"type":"integer"},"dueDays":{"type":"integer"},"issuer":{"properties":{"address":{"type":"string"},"name":{"type":"string"}},"required":["name","address"],"type":["null","object"]},"next":{"type":"integer"},"nextNumber":{"type":"string"},"notes":{"type":["null","string"]},"prefix":{"type":"string"},"reminders":{"properties":{"after":{"items":{"type":"integer"},"type":"array"},"before":{"items":{"type":"integer"},"type":"array"}},"required":["after","before"],"type":"object"},"taxPercent":{"type":["integer","null"]}},"required":["acceptPayments","digits","dueDays","issuer","next","nextNumber","notes","prefix","reminders","taxPercent"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/invoices":{"get":{"operationId":"GET /v1/invoices","summary":"Lists and searches invoices, by status, client or date.","tags":["invoices"],"x-feature":"invoices","x-action":"read","parameters":[{"name":"page","in":"query","required":false,"schema":{"default":1,"type":"integer","minimum":1,"maximum":9007199254740991}},{"name":"pageSize","in":"query","required":false,"schema":{"default":25,"type":"integer","minimum":1,"maximum":100}},{"name":"q","in":"query","required":false,"schema":{"type":"string","minLength":1,"maxLength":200}},{"name":"archived","in":"query","required":false,"schema":{"type":"string"}},{"name":"status","in":"query","required":false,"schema":{"type":"string","enum":["draft","open","overdue","paid","void"]}},{"name":"contactId","in":"query","required":false,"schema":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"}},{"name":"companyId","in":"query","required":false,"schema":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"}},{"name":"dealId","in":"query","required":false,"schema":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"}},{"name":"ownerId","in":"query","required":false,"schema":{"type":"string","minLength":1}},{"name":"dueFrom","in":"query","required":false,"schema":{"type":"string","format":"date","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))$"}},{"name":"dueBefore","in":"query","required":false,"schema":{"type":"string","format":"date","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))$"}},{"name":"sort","in":"query","required":false,"schema":{"default":"issueDate","type":"string","enum":["issueDate","dueDate","total","number","createdAt"]}},{"name":"order","in":"query","required":false,"schema":{"default":"desc","type":"string","enum":["asc","desc"]}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"data":{"items":{"properties":{"acceptPayments":{"type":"boolean"},"company":{"type":"null"},"companyId":{"type":"null"},"contact":{"properties":{"id":{"format":"uuid","type":"string"},"name":{"type":"string"}},"required":["id","name"],"type":["null","object"]},"contactId":{"format":"uuid","type":["null","string"]},"createdAt":{"format":"date-time","type":"string"},"createdBy":{"format":"uuid","type":["null","string"]},"currency":{"type":"string"},"deal":{"type":"null"},"dealId":{"type":"null"},"discount":{"type":"null"},"discountAmount":{"type":"integer"},"dueDate":{"format":"date","type":"string"},"firstViewedAt":{"type":"null"},"id":{"format":"uuid","type":"string"},"issueDate":{"format":"date","type":"string"},"issuer":{"properties":{"address":{"type":"null"},"name":{"type":"string"}},"required":["name","address"],"type":"object"},"items":{"items":{"properties":{"description":{"type":"null"},"discount":{"type":"null"},"id":{"format":"uuid","type":"string"},"name":{"type":"string"},"quantity":{"type":"integer"},"serviceId":{"type":"null"},"unitPrice":{"type":"integer"}},"required":["id","name","discount","quantity","serviceId","unitPrice","description"],"type":"object"},"type":"array"},"language":{"type":"null"},"lastViewedAt":{"type":"null"},"notes":{"type":["null","string"]},"number":{"type":"string"},"organizationId":{"format":"uuid","type":"string"},"overdue":{"type":"boolean"},"owner":{"properties":{"id":{"format":"uuid","type":"string"},"name":{"type":"string"}},"required":["id","name"],"type":"object"},"ownerId":{"format":"uuid","type":"string"},"paidAt":{"type":"null"},"paymentMethod":{"type":"null"},"paymentNote":{"type":"null"},"publicId":{"type":"string"},"recipient":{"properties":{"address":{"type":"null"},"name":{"type":"string"}},"required":["name","address"],"type":["null","object"]},"recurrence":{"properties":{"autoSend":{"type":"boolean"},"dayOfMonth":{"type":"integer"},"dueDays":{"type":"integer"},"interval":{"type":"string"},"nextIssueDate":{"format":"date","type":"string"}},"required":["autoSend","interval","dayOfMonth","nextIssueDate"],"type":["null","object"]},"recurringFromId":{"format":"uuid","type":["null","string"]},"reminderDays":{"type":"null"},"remindersSent":{"items":{"type":"string"},"type":"array"},"sentAt":{"format":"date-time","type":["null","string"]},"status":{"type":"string"},"subtotal":{"type":"integer"},"taxAmount":{"type":"integer"},"taxBasisPoints":{"type":"null"},"taxPercent":{"type":"null"},"total":{"type":"integer"},"updatedAt":{"format":"date-time","type":"string"},"updatedBy":{"format":"uuid","type":["null","string"]},"viewCount":{"type":"integer"},"voidReason":{"type":"null"},"voidedAt":{"type":"null"}},"required":["id","organizationId","publicId","number","status","dealId","companyId","contactId","ownerId","issuer","recipient","language","currency","issueDate","dueDate","items","discount","taxBasisPoints","notes","subtotal","discountAmount","taxAmount","total","sentAt","paidAt","acceptPayments","paymentMethod","paymentNote","voidedAt","voidReason","viewCount","firstViewedAt","lastViewedAt","reminderDays","remindersSent","recurrence","recurringFromId","createdBy","updatedBy","createdAt","updatedAt","taxPercent","overdue","company","contact","owner","deal"],"type":"object"},"type":"array"},"page":{"type":"integer"},"pageSize":{"type":"integer"},"summary":{"properties":{"open":{"items":{"properties":{"amount":{"type":"integer"},"count":{"type":"integer"},"currency":{"type":"string"}},"required":["currency","count","amount"],"type":"object"},"type":"array"},"overdue":{"items":{"properties":{"amount":{"type":"integer"},"count":{"type":"integer"},"currency":{"type":"string"}},"required":["currency","count","amount"],"type":"object"},"type":"array"},"paidThisMonth":{"type":"array"}},"required":["open","overdue","paidThisMonth"],"type":"object"},"total":{"type":"integer"}},"required":["data","page","pageSize","total","summary"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"post":{"operationId":"POST /v1/invoices","summary":"Creates an invoice draft with its items.","tags":["invoices"],"x-feature":"invoices","x-action":"create","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"number":{"type":"string","minLength":1,"maxLength":60},"dealId":{"anyOf":[{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},{"type":"null"}]},"companyId":{"anyOf":[{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},{"type":"null"}]},"contactId":{"anyOf":[{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},{"type":"null"}]},"issuer":{"anyOf":[{"type":"object","properties":{"name":{"type":"string","minLength":1,"maxLength":200},"address":{"anyOf":[{"type":"string","maxLength":1000},{"type":"null"}]}},"required":["name"]},{"type":"null"}]},"recipient":{"anyOf":[{"type":"object","properties":{"name":{"type":"string","minLength":1,"maxLength":200},"address":{"anyOf":[{"type":"string","maxLength":1000},{"type":"null"}]}},"required":["name"]},{"type":"null"}]},"language":{"anyOf":[{"type":"string","enum":["pt","es","en","fr"]},{"type":"null"}]},"ownerId":{"anyOf":[{"type":"string","minLength":1},{"type":"null"}]},"currency":{"type":"string","pattern":"^[A-Z]{3}$"},"issueDate":{"type":"string","format":"date","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))$"},"dueDate":{"type":"string","format":"date","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))$"},"items":{"maxItems":200,"type":"array","items":{"type":"object","properties":{"id":{"type":"string","minLength":1,"maxLength":64},"serviceId":{"anyOf":[{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},{"type":"null"}]},"name":{"type":"string","minLength":1,"maxLength":200},"description":{"anyOf":[{"type":"string","maxLength":2000},{"type":"null"}]},"quantity":{"default":1,"type":"number","exclusiveMinimum":0,"maximum":100000},"unitPrice":{"type":"integer","minimum":0,"maximum":10000000000000},"discount":{"anyOf":[{"oneOf":[{"type":"object","properties":{"type":{"type":"string","const":"percent"},"value":{"type":"number","exclusiveMinimum":0,"maximum":100,"multipleOf":0.01}},"required":["type","value"]},{"type":"object","properties":{"type":{"type":"string","const":"amount"},"value":{"type":"integer","exclusiveMinimum":0,"maximum":10000000000000}},"required":["type","value"]}]},{"type":"null"}]}},"required":["name","unitPrice"]}},"discount":{"anyOf":[{"oneOf":[{"type":"object","properties":{"type":{"type":"string","const":"percent"},"value":{"type":"number","exclusiveMinimum":0,"maximum":100,"multipleOf":0.01}},"required":["type","value"]},{"type":"object","properties":{"type":{"type":"string","const":"amount"},"value":{"type":"integer","exclusiveMinimum":0,"maximum":10000000000000}},"required":["type","value"]}]},{"type":"null"}]},"taxPercent":{"anyOf":[{"type":"number","minimum":0,"maximum":100,"multipleOf":0.01},{"type":"null"}]},"notes":{"anyOf":[{"type":"string","maxLength":10000},{"type":"null"}]},"recurrence":{"anyOf":[{"type":"object","properties":{"interval":{"type":"string","enum":["monthly","quarterly","yearly"]},"dayOfMonth":{"type":"integer","minimum":1,"maximum":31},"dueDays":{"type":"integer","minimum":0,"maximum":365},"nextIssueDate":{"type":"string","format":"date","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))$"},"autoSend":{"default":false,"type":"boolean"}},"required":["interval"]},{"type":"null"}]},"acceptPayments":{"type":"boolean"},"reminderDays":{"anyOf":[{"maxItems":5,"type":"array","items":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991}},{"type":"null"}]}}}}}},"responses":{"201":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"acceptPayments":{"type":"boolean"},"company":{"properties":{"id":{"format":"uuid","type":"string"},"name":{"type":"string"}},"required":["id","name"],"type":["null","object"]},"companyId":{"format":"uuid","type":["null","string"]},"contact":{"properties":{"id":{"format":"uuid","type":"string"},"name":{"type":"string"}},"required":["id","name"],"type":["null","object"]},"contactEmail":{"format":"email","type":["null","string"]},"contactId":{"format":"uuid","type":["null","string"]},"createdAt":{"format":"date-time","type":"string"},"createdBy":{"format":"uuid","type":"string"},"currency":{"type":"string"},"deal":{"type":"null"},"dealId":{"type":"null"},"discount":{"properties":{"type":{"type":"string"},"value":{"type":"integer"}},"required":["type","value"],"type":["null","object"]},"discountAmount":{"type":"integer"},"dueDate":{"format":"date","type":"string"},"firstViewedAt":{"type":"null"},"id":{"format":"uuid","type":"string"},"issueDate":{"format":"date","type":"string"},"issuer":{"properties":{"address":{"type":["null","string"]},"name":{"type":"string"}},"required":["address","name"],"type":"object"},"items":{"items":{"properties":{"description":{"type":"null"},"discount":{"properties":{"type":{"type":"string"},"value":{"type":"integer"}},"required":["type","value"],"type":["null","object"]},"id":{"format":"uuid","type":"string"},"name":{"type":"string"},"quantity":{"type":"integer"},"serviceId":{"format":"uuid","type":["null","string"]},"unitPrice":{"type":"integer"}},"required":["description","discount","id","name","quantity","serviceId","unitPrice"],"type":"object"},"type":"array"},"language":{"type":["null","string"]},"lastViewedAt":{"type":"null"},"notes":{"type":["null","string"]},"number":{"type":"string"},"organizationId":{"format":"uuid","type":"string"},"overdue":{"type":"boolean"},"owner":{"properties":{"id":{"format":"uuid","type":"string"},"name":{"type":"string"}},"required":["id","name"],"type":"object"},"ownerId":{"format":"uuid","type":"string"},"paidAt":{"type":"null"},"payment":{"type":"null"},"paymentMethod":{"type":"null"},"paymentNote":{"type":"null"},"publicId":{"type":"string"},"recipient":{"properties":{"address":{"type":["null","string"]},"name":{"type":"string"}},"required":["address","name"],"type":["null","object"]},"recurrence":{"properties":{"autoSend":{"type":"boolean"},"dayOfMonth":{"type":"integer"},"dueDays":{"type":"integer"},"interval":{"type":"string"},"nextIssueDate":{"format":"date","type":"string"}},"required":["autoSend","dayOfMonth","interval","nextIssueDate"],"type":["null","object"]},"recurringFromId":{"type":"null"},"reminderDays":{"items":{"type":"integer"},"type":["array","null"]},"remindersSent":{"type":"array"},"sentAt":{"type":"null"},"status":{"type":"string"},"subtotal":{"type":"integer"},"taxAmount":{"type":"integer"},"taxBasisPoints":{"type":["integer","null"]},"taxPercent":{"type":["integer","null"]},"total":{"type":"integer"},"updatedAt":{"format":"date-time","type":"string"},"updatedBy":{"format":"uuid","type":"string"},"url":{"type":"null"},"viewCount":{"type":"integer"},"voidReason":{"type":"null"},"voidedAt":{"type":"null"}},"required":["acceptPayments","company","companyId","contact","contactEmail","contactId","createdAt","createdBy","currency","deal","dealId","discount","discountAmount","dueDate","firstViewedAt","id","issueDate","issuer","items","language","lastViewedAt","notes","number","organizationId","overdue","owner","ownerId","paidAt","payment","paymentMethod","paymentNote","publicId","recipient","recurrence","recurringFromId","reminderDays","remindersSent","sentAt","status","subtotal","taxAmount","taxBasisPoints","taxPercent","total","updatedAt","updatedBy","url","viewCount","voidReason","voidedAt"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/invoices/{id}":{"delete":{"operationId":"DELETE /v1/invoices/{id}","summary":"Deletes an invoice draft.","tags":["invoices"],"x-feature":"invoices","x-action":"delete","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"204":{"description":"Done, with no content."},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"get":{"operationId":"GET /v1/invoices/{id}","summary":"Returns an invoice with its items, payments and status.","tags":["invoices"],"x-feature":"invoices","x-action":"read","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"acceptPayments":{"type":"boolean"},"company":{"type":"null"},"companyId":{"type":"null"},"contact":{"properties":{"id":{"format":"uuid","type":"string"},"name":{"type":"string"}},"required":["id","name"],"type":["null","object"]},"contactEmail":{"format":"email","type":["null","string"]},"contactId":{"format":"uuid","type":["null","string"]},"createdAt":{"format":"date-time","type":"string"},"createdBy":{"format":"uuid","type":["null","string"]},"currency":{"type":"string"},"deal":{"properties":{"id":{"format":"uuid","type":"string"},"title":{"type":"string"}},"required":["id","title"],"type":["null","object"]},"dealId":{"format":"uuid","type":["null","string"]},"discount":{"properties":{"type":{"type":"string"},"value":{"type":"integer"}},"required":["type","value"],"type":["null","object"]},"discountAmount":{"type":"integer"},"dueDate":{"format":"date","type":"string"},"firstViewedAt":{"format":"date-time","type":["null","string"]},"id":{"format":"uuid","type":"string"},"issueDate":{"format":"date","type":"string"},"issuer":{"properties":{"address":{"type":"null"},"name":{"type":"string"}},"required":["address","name"],"type":"object"},"items":{"items":{"properties":{"description":{"type":"null"},"discount":{"type":"null"},"id":{"format":"uuid","type":"string"},"name":{"type":"string"},"quantity":{"type":"integer"},"serviceId":{"type":"null"},"unitPrice":{"type":"integer"}},"required":["description","discount","id","name","quantity","serviceId","unitPrice"],"type":"object"},"type":"array"},"language":{"type":"null"},"lastViewedAt":{"format":"date-time","type":["null","string"]},"notes":{"type":["null","string"]},"number":{"type":"string"},"organizationId":{"format":"uuid","type":"string"},"overdue":{"type":"boolean"},"owner":{"properties":{"id":{"format":"uuid","type":"string"},"name":{"type":"string"}},"required":["id","name"],"type":"object"},"ownerId":{"format":"uuid","type":"string"},"paidAt":{"format":"date-time","type":["null","string"]},"payment":{"properties":{"amount":{"type":"integer"},"applicationFee":{"type":"integer"},"createdAt":{"format":"date-time","type":"string"},"currency":{"type":"string"},"id":{"format":"uuid","type":"string"},"paidAt":{"format":"date-time","type":"string"},"payerEmail":{"format":"email","type":"string"},"payerName":{"type":"string"},"status":{"type":"string"}},"required":["amount","applicationFee","createdAt","currency","id","paidAt","payerEmail","payerName","status"],"type":["null","object"]},"paymentMethod":{"type":["null","string"]},"paymentNote":{"type":"null"},"publicId":{"type":"string"},"recipient":{"properties":{"address":{"type":"null"},"name":{"type":"string"}},"required":["address","name"],"type":["null","object"]},"recurrence":{"properties":{"autoSend":{"type":"boolean"},"dayOfMonth":{"type":"integer"},"dueDays":{"type":"integer"},"interval":{"type":"string"},"nextIssueDate":{"format":"date","type":"string"}},"required":["autoSend","interval","dayOfMonth","nextIssueDate"],"type":["null","object"]},"recurringFromId":{"type":"null"},"reminderDays":{"type":"null"},"remindersSent":{"type":"array"},"sentAt":{"format":"date-time","type":["null","string"]},"status":{"type":"string"},"subtotal":{"type":"integer"},"taxAmount":{"type":"integer"},"taxBasisPoints":{"type":"null"},"taxPercent":{"type":"null"},"total":{"type":"integer"},"updatedAt":{"format":"date-time","type":"string"},"updatedBy":{"format":"uuid","type":["null","string"]},"url":{"format":"uri","type":["null","string"]},"viewCount":{"type":"integer"},"voidReason":{"type":"null"},"voidedAt":{"type":"null"}},"required":["acceptPayments","company","companyId","contact","contactEmail","contactId","createdAt","createdBy","currency","deal","dealId","discount","discountAmount","dueDate","firstViewedAt","id","issueDate","issuer","items","language","lastViewedAt","notes","number","organizationId","overdue","owner","ownerId","paidAt","payment","paymentMethod","paymentNote","publicId","recipient","recurrence","recurringFromId","reminderDays","remindersSent","sentAt","status","subtotal","taxAmount","taxBasisPoints","taxPercent","total","updatedAt","updatedBy","url","viewCount","voidReason","voidedAt"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"patch":{"operationId":"PATCH /v1/invoices/{id}","summary":"Changes an invoice draft.","tags":["invoices"],"x-feature":"invoices","x-action":"update","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"dealId":{"anyOf":[{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},{"type":"null"}]},"companyId":{"anyOf":[{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},{"type":"null"}]},"contactId":{"anyOf":[{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},{"type":"null"}]},"issuer":{"anyOf":[{"type":"object","properties":{"name":{"type":"string","minLength":1,"maxLength":200},"address":{"anyOf":[{"type":"string","maxLength":1000},{"type":"null"}]}},"required":["name"]},{"type":"null"}]},"recipient":{"anyOf":[{"type":"object","properties":{"name":{"type":"string","minLength":1,"maxLength":200},"address":{"anyOf":[{"type":"string","maxLength":1000},{"type":"null"}]}},"required":["name"]},{"type":"null"}]},"language":{"anyOf":[{"type":"string","enum":["pt","es","en","fr"]},{"type":"null"}]},"ownerId":{"anyOf":[{"type":"string","minLength":1},{"type":"null"}]},"currency":{"type":"string","pattern":"^[A-Z]{3}$"},"issueDate":{"type":"string","format":"date","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))$"},"dueDate":{"type":"string","format":"date","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))$"},"items":{"maxItems":200,"type":"array","items":{"type":"object","properties":{"id":{"type":"string","minLength":1,"maxLength":64},"serviceId":{"anyOf":[{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},{"type":"null"}]},"name":{"type":"string","minLength":1,"maxLength":200},"description":{"anyOf":[{"type":"string","maxLength":2000},{"type":"null"}]},"quantity":{"default":1,"type":"number","exclusiveMinimum":0,"maximum":100000},"unitPrice":{"type":"integer","minimum":0,"maximum":10000000000000},"discount":{"anyOf":[{"oneOf":[{"type":"object","properties":{"type":{"type":"string","const":"percent"},"value":{"type":"number","exclusiveMinimum":0,"maximum":100,"multipleOf":0.01}},"required":["type","value"]},{"type":"object","properties":{"type":{"type":"string","const":"amount"},"value":{"type":"integer","exclusiveMinimum":0,"maximum":10000000000000}},"required":["type","value"]}]},{"type":"null"}]}},"required":["name","unitPrice"]}},"discount":{"anyOf":[{"oneOf":[{"type":"object","properties":{"type":{"type":"string","const":"percent"},"value":{"type":"number","exclusiveMinimum":0,"maximum":100,"multipleOf":0.01}},"required":["type","value"]},{"type":"object","properties":{"type":{"type":"string","const":"amount"},"value":{"type":"integer","exclusiveMinimum":0,"maximum":10000000000000}},"required":["type","value"]}]},{"type":"null"}]},"taxPercent":{"anyOf":[{"type":"number","minimum":0,"maximum":100,"multipleOf":0.01},{"type":"null"}]},"notes":{"anyOf":[{"type":"string","maxLength":10000},{"type":"null"}]},"recurrence":{"anyOf":[{"type":"object","properties":{"interval":{"type":"string","enum":["monthly","quarterly","yearly"]},"dayOfMonth":{"type":"integer","minimum":1,"maximum":31},"dueDays":{"type":"integer","minimum":0,"maximum":365},"nextIssueDate":{"type":"string","format":"date","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))$"},"autoSend":{"default":false,"type":"boolean"}},"required":["interval"]},{"type":"null"}]},"acceptPayments":{"type":"boolean"},"reminderDays":{"anyOf":[{"maxItems":5,"type":"array","items":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991}},{"type":"null"}]},"number":{"type":"string","minLength":1,"maxLength":60}}}}}},"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"acceptPayments":{"type":"boolean"},"company":{"type":"null"},"companyId":{"type":"null"},"contact":{"properties":{"id":{"format":"uuid","type":"string"},"name":{"type":"string"}},"required":["id","name"],"type":["null","object"]},"contactEmail":{"format":"email","type":["null","string"]},"contactId":{"format":"uuid","type":["null","string"]},"createdAt":{"format":"date-time","type":"string"},"createdBy":{"format":"uuid","type":"string"},"currency":{"type":"string"},"deal":{"type":"null"},"dealId":{"type":"null"},"discount":{"type":"null"},"discountAmount":{"type":"integer"},"dueDate":{"format":"date","type":"string"},"firstViewedAt":{"type":"null"},"id":{"format":"uuid","type":"string"},"issueDate":{"format":"date","type":"string"},"issuer":{"properties":{"address":{"type":["null","string"]},"name":{"type":"string"}},"required":["address","name"],"type":"object"},"items":{"items":{"properties":{"description":{"type":"null"},"discount":{"type":"null"},"id":{"format":"uuid","type":"string"},"name":{"type":"string"},"quantity":{"type":"integer"},"serviceId":{"type":"null"},"unitPrice":{"type":"integer"}},"required":["description","discount","id","name","quantity","serviceId","unitPrice"],"type":"object"},"type":"array"},"language":{"type":"null"},"lastViewedAt":{"type":"null"},"notes":{"type":["null","string"]},"number":{"type":"string"},"organizationId":{"format":"uuid","type":"string"},"overdue":{"type":"boolean"},"owner":{"properties":{"id":{"format":"uuid","type":"string"},"name":{"type":"string"}},"required":["id","name"],"type":"object"},"ownerId":{"format":"uuid","type":"string"},"paidAt":{"type":"null"},"payment":{"properties":{"amount":{"type":"integer"},"applicationFee":{"type":"integer"},"createdAt":{"format":"date-time","type":"string"},"currency":{"type":"string"},"id":{"format":"uuid","type":"string"},"paidAt":{"type":"null"},"payerEmail":{"type":"null"},"payerName":{"type":"null"},"status":{"type":"string"}},"required":["amount","applicationFee","createdAt","currency","id","paidAt","payerEmail","payerName","status"],"type":["null","object"]},"paymentMethod":{"type":"null"},"paymentNote":{"type":"null"},"publicId":{"type":"string"},"recipient":{"properties":{"address":{"type":["null","string"]},"name":{"type":"string"}},"required":["address","name"],"type":["null","object"]},"recurrence":{"properties":{"autoSend":{"type":"boolean"},"dayOfMonth":{"type":"integer"},"dueDays":{"type":"integer"},"interval":{"type":"string"},"nextIssueDate":{"format":"date","type":"string"}},"required":["autoSend","dayOfMonth","dueDays","interval","nextIssueDate"],"type":["null","object"]},"recurringFromId":{"type":"null"},"reminderDays":{"type":"null"},"remindersSent":{"type":"array"},"sentAt":{"format":"date-time","type":["null","string"]},"status":{"type":"string"},"subtotal":{"type":"integer"},"taxAmount":{"type":"integer"},"taxBasisPoints":{"type":"null"},"taxPercent":{"type":"null"},"total":{"type":"integer"},"updatedAt":{"format":"date-time","type":"string"},"updatedBy":{"format":"uuid","type":"string"},"url":{"format":"uri","type":["null","string"]},"viewCount":{"type":"integer"},"voidReason":{"type":"null"},"voidedAt":{"type":"null"}},"required":["acceptPayments","company","companyId","contact","contactEmail","contactId","createdAt","createdBy","currency","deal","dealId","discount","discountAmount","dueDate","firstViewedAt","id","issueDate","issuer","items","language","lastViewedAt","notes","number","organizationId","overdue","owner","ownerId","paidAt","payment","paymentMethod","paymentNote","publicId","recipient","recurrence","recurringFromId","reminderDays","remindersSent","sentAt","status","subtotal","taxAmount","taxBasisPoints","taxPercent","total","updatedAt","updatedBy","url","viewCount","voidReason","voidedAt"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/invoices/{id}/duplicate":{"post":{"operationId":"POST /v1/invoices/{id}/duplicate","summary":"A new draft with the same items and client.","tags":["invoices"],"x-feature":"invoices","x-action":"create","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"201":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"acceptPayments":{"type":"boolean"},"company":{"type":"null"},"companyId":{"type":"null"},"contact":{"properties":{"id":{"format":"uuid","type":"string"},"name":{"type":"string"}},"required":["id","name"],"type":"object"},"contactEmail":{"format":"email","type":"string"},"contactId":{"format":"uuid","type":"string"},"createdAt":{"format":"date-time","type":"string"},"createdBy":{"format":"uuid","type":"string"},"currency":{"type":"string"},"deal":{"type":"null"},"dealId":{"type":"null"},"discount":{"type":"null"},"discountAmount":{"type":"integer"},"dueDate":{"format":"date","type":"string"},"firstViewedAt":{"type":"null"},"id":{"format":"uuid","type":"string"},"issueDate":{"format":"date","type":"string"},"issuer":{"properties":{"address":{"type":"null"},"name":{"type":"string"}},"required":["name","address"],"type":"object"},"items":{"items":{"properties":{"description":{"type":"null"},"discount":{"type":"null"},"id":{"format":"uuid","type":"string"},"name":{"type":"string"},"quantity":{"type":"integer"},"serviceId":{"type":"null"},"unitPrice":{"type":"integer"}},"required":["id","name","discount","quantity","serviceId","unitPrice","description"],"type":"object"},"type":"array"},"language":{"type":"null"},"lastViewedAt":{"type":"null"},"notes":{"type":"null"},"number":{"type":"string"},"organizationId":{"format":"uuid","type":"string"},"overdue":{"type":"boolean"},"owner":{"properties":{"id":{"format":"uuid","type":"string"},"name":{"type":"string"}},"required":["id","name"],"type":"object"},"ownerId":{"format":"uuid","type":"string"},"paidAt":{"type":"null"},"payment":{"type":"null"},"paymentMethod":{"type":"null"},"paymentNote":{"type":"null"},"publicId":{"type":"string"},"recipient":{"properties":{"address":{"type":"null"},"name":{"type":"string"}},"required":["name","address"],"type":"object"},"recurrence":{"type":"null"},"recurringFromId":{"type":"null"},"reminderDays":{"type":"null"},"remindersSent":{"type":"array"},"sentAt":{"type":"null"},"status":{"type":"string"},"subtotal":{"type":"integer"},"taxAmount":{"type":"integer"},"taxBasisPoints":{"type":"null"},"taxPercent":{"type":"null"},"total":{"type":"integer"},"updatedAt":{"format":"date-time","type":"string"},"updatedBy":{"format":"uuid","type":"string"},"url":{"type":"null"},"viewCount":{"type":"integer"},"voidReason":{"type":"null"},"voidedAt":{"type":"null"}},"required":["id","organizationId","publicId","number","status","dealId","companyId","contactId","ownerId","issuer","recipient","language","currency","issueDate","dueDate","items","discount","taxBasisPoints","notes","subtotal","discountAmount","taxAmount","total","sentAt","paidAt","acceptPayments","paymentMethod","paymentNote","voidedAt","voidReason","viewCount","firstViewedAt","lastViewedAt","reminderDays","remindersSent","recurrence","recurringFromId","createdBy","updatedBy","createdAt","updatedAt","taxPercent","overdue","company","contact","owner","deal","url","contactEmail","payment"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/invoices/{id}/pay":{"post":{"operationId":"POST /v1/invoices/{id}/pay","summary":"Marks an invoice as paid outside Stripe, with the date and how.","tags":["invoices"],"x-feature":"invoices","x-action":"update","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"paidAt":{"type":"string","format":"date-time"},"method":{"anyOf":[{"type":"string","maxLength":60},{"type":"null"}]},"note":{"anyOf":[{"type":"string","maxLength":1000},{"type":"null"}]}}}}}},"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"acceptPayments":{"type":"boolean"},"company":{"properties":{"id":{"format":"uuid","type":"string"},"name":{"type":"string"}},"required":["id","name"],"type":["null","object"]},"companyId":{"format":"uuid","type":["null","string"]},"contact":{"properties":{"id":{"format":"uuid","type":"string"},"name":{"type":"string"}},"required":["id","name"],"type":["null","object"]},"contactEmail":{"format":"email","type":["null","string"]},"contactId":{"format":"uuid","type":["null","string"]},"createdAt":{"format":"date-time","type":"string"},"createdBy":{"format":"uuid","type":"string"},"currency":{"type":"string"},"deal":{"type":"null"},"dealId":{"type":"null"},"discount":{"type":"null"},"discountAmount":{"type":"integer"},"dueDate":{"format":"date","type":"string"},"firstViewedAt":{"format":"date-time","type":["null","string"]},"id":{"format":"uuid","type":"string"},"issueDate":{"format":"date","type":"string"},"issuer":{"properties":{"address":{"type":"null"},"name":{"type":"string"}},"required":["address","name"],"type":"object"},"items":{"items":{"properties":{"description":{"type":"null"},"discount":{"type":"null"},"id":{"format":"uuid","type":"string"},"name":{"type":"string"},"quantity":{"type":"integer"},"serviceId":{"type":"null"},"unitPrice":{"type":"integer"}},"required":["description","discount","id","name","quantity","serviceId","unitPrice"],"type":"object"},"type":"array"},"language":{"type":"null"},"lastViewedAt":{"format":"date-time","type":["null","string"]},"notes":{"type":"null"},"number":{"type":"string"},"organizationId":{"format":"uuid","type":"string"},"overdue":{"type":"boolean"},"owner":{"properties":{"id":{"format":"uuid","type":"string"},"name":{"type":"string"}},"required":["id","name"],"type":"object"},"ownerId":{"format":"uuid","type":"string"},"paidAt":{"format":"date-time","type":"string"},"payment":{"type":"null"},"paymentMethod":{"type":"string"},"paymentNote":{"type":"null"},"publicId":{"type":"string"},"recipient":{"properties":{"address":{"type":"null"},"name":{"type":"string"}},"required":["address","name"],"type":["null","object"]},"recurrence":{"type":"null"},"recurringFromId":{"type":"null"},"reminderDays":{"type":"null"},"remindersSent":{"type":"array"},"sentAt":{"format":"date-time","type":["null","string"]},"status":{"type":"string"},"subtotal":{"type":"integer"},"taxAmount":{"type":"integer"},"taxBasisPoints":{"type":"null"},"taxPercent":{"type":"null"},"total":{"type":"integer"},"updatedAt":{"format":"date-time","type":"string"},"updatedBy":{"format":"uuid","type":"string"},"url":{"format":"uri","type":"string"},"viewCount":{"type":"integer"},"voidReason":{"type":"null"},"voidedAt":{"type":"null"}},"required":["acceptPayments","company","companyId","contact","contactEmail","contactId","createdAt","createdBy","currency","deal","dealId","discount","discountAmount","dueDate","firstViewedAt","id","issueDate","issuer","items","language","lastViewedAt","notes","number","organizationId","overdue","owner","ownerId","paidAt","payment","paymentMethod","paymentNote","publicId","recipient","recurrence","recurringFromId","reminderDays","remindersSent","sentAt","status","subtotal","taxAmount","taxBasisPoints","taxPercent","total","updatedAt","updatedBy","url","viewCount","voidReason","voidedAt"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/invoices/{id}/preview":{"get":{"operationId":"GET /v1/invoices/{id}/preview","summary":"The invoice as the client sees it, without counting a view.","tags":["invoices"],"x-feature":"invoices","x-action":"read","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"billTo":{"properties":{"address":{"type":["null","string"]},"contact":{"type":["null","string"]},"name":{"type":["null","string"]}},"required":["address","contact","name"],"type":"object"},"currency":{"type":"string"},"dealUrl":{"type":"null"},"discount":{"type":"null"},"discountAmount":{"type":"integer"},"dueDate":{"format":"date","type":"string"},"issueDate":{"format":"date","type":"string"},"issuer":{"properties":{"address":{"type":["null","string"]},"name":{"type":"string"}},"required":["address","name"],"type":"object"},"items":{"type":"array"},"language":{"type":"string"},"notes":{"type":"null"},"number":{"type":"string"},"organization":{"properties":{"name":{"type":"string"}},"required":["name"],"type":"object"},"overdue":{"type":"boolean"},"paidAt":{"type":"null"},"payment":{"type":"null"},"status":{"type":"string"},"subtotal":{"type":"integer"},"taxAmount":{"type":"integer"},"taxPercent":{"type":"null"},"templateId":{"type":"string"},"theme":{"properties":{"accentColor":{"type":"string"},"backgroundColor":{"type":"string"},"bodyFont":{"type":"string"},"cornerRadius":{"type":"string"},"headingFont":{"type":"string"},"primaryColor":{"type":"string"},"textColor":{"type":"string"}},"required":["accentColor","backgroundColor","bodyFont","cornerRadius","headingFont","primaryColor","textColor"],"type":"object"},"total":{"type":"integer"}},"required":["billTo","currency","dealUrl","discount","discountAmount","dueDate","issueDate","issuer","items","language","notes","number","organization","overdue","paidAt","payment","status","subtotal","taxAmount","taxPercent","templateId","theme","total"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/invoices/{id}/send":{"post":{"operationId":"POST /v1/invoices/{id}/send","summary":"Sends the invoice to the client by email.","tags":["invoices"],"x-feature":"invoices","x-action":"update","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"email":{"default":true,"type":"boolean"},"to":{"type":"string","maxLength":320,"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,}$"}}}}}},"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"acceptPayments":{"type":"boolean"},"company":{"type":"null"},"companyId":{"type":"null"},"contact":{"properties":{"id":{"format":"uuid","type":"string"},"name":{"type":"string"}},"required":["id","name"],"type":["null","object"]},"contactEmail":{"format":"email","type":["null","string"]},"contactId":{"format":"uuid","type":["null","string"]},"createdAt":{"format":"date-time","type":"string"},"createdBy":{"format":"uuid","type":"string"},"currency":{"type":"string"},"deal":{"type":"null"},"dealId":{"type":"null"},"discount":{"type":"null"},"discountAmount":{"type":"integer"},"dueDate":{"format":"date","type":"string"},"firstViewedAt":{"type":"null"},"id":{"format":"uuid","type":"string"},"issueDate":{"format":"date","type":"string"},"issuer":{"properties":{"address":{"type":["null","string"]},"name":{"type":"string"}},"required":["address","name"],"type":"object"},"items":{"items":{"properties":{"description":{"type":"null"},"discount":{"type":"null"},"id":{"format":"uuid","type":"string"},"name":{"type":"string"},"quantity":{"type":"integer"},"serviceId":{"type":"null"},"unitPrice":{"type":"integer"}},"required":["description","discount","id","name","quantity","serviceId","unitPrice"],"type":"object"},"type":"array"},"language":{"type":["null","string"]},"lastViewedAt":{"type":"null"},"notes":{"type":"null"},"number":{"type":"string"},"organizationId":{"format":"uuid","type":"string"},"overdue":{"type":"boolean"},"owner":{"properties":{"id":{"format":"uuid","type":"string"},"name":{"type":"string"}},"required":["id","name"],"type":"object"},"ownerId":{"format":"uuid","type":"string"},"paidAt":{"type":"null"},"payment":{"type":"null"},"paymentMethod":{"type":"null"},"paymentNote":{"type":"null"},"publicId":{"type":"string"},"recipient":{"properties":{"address":{"type":["null","string"]},"name":{"type":"string"}},"required":["address","name"],"type":["null","object"]},"recurrence":{"type":"null"},"recurringFromId":{"type":"null"},"reminderDays":{"items":{"type":"integer"},"type":["array","null"]},"remindersSent":{"type":"array"},"sentAt":{"format":"date-time","type":"string"},"status":{"type":"string"},"subtotal":{"type":"integer"},"taxAmount":{"type":"integer"},"taxBasisPoints":{"type":"null"},"taxPercent":{"type":"null"},"total":{"type":"integer"},"updatedAt":{"format":"date-time","type":"string"},"updatedBy":{"format":"uuid","type":"string"},"url":{"format":"uri","type":"string"},"viewCount":{"type":"integer"},"voidReason":{"type":"null"},"voidedAt":{"type":"null"}},"required":["acceptPayments","company","companyId","contact","contactEmail","contactId","createdAt","createdBy","currency","deal","dealId","discount","discountAmount","dueDate","firstViewedAt","id","issueDate","issuer","items","language","lastViewedAt","notes","number","organizationId","overdue","owner","ownerId","paidAt","payment","paymentMethod","paymentNote","publicId","recipient","recurrence","recurringFromId","reminderDays","remindersSent","sentAt","status","subtotal","taxAmount","taxBasisPoints","taxPercent","total","updatedAt","updatedBy","url","viewCount","voidReason","voidedAt"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/invoices/{id}/unpay":{"post":{"operationId":"POST /v1/invoices/{id}/unpay","summary":"Undoes marking an invoice as paid.","tags":["invoices"],"x-feature":"invoices","x-action":"update","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"acceptPayments":{"type":"boolean"},"company":{"type":"null"},"companyId":{"type":"null"},"contact":{"properties":{"id":{"format":"uuid","type":"string"},"name":{"type":"string"}},"required":["id","name"],"type":"object"},"contactEmail":{"format":"email","type":"string"},"contactId":{"format":"uuid","type":"string"},"createdAt":{"format":"date-time","type":"string"},"createdBy":{"format":"uuid","type":"string"},"currency":{"type":"string"},"deal":{"type":"null"},"dealId":{"type":"null"},"discount":{"type":"null"},"discountAmount":{"type":"integer"},"dueDate":{"format":"date","type":"string"},"firstViewedAt":{"format":"date-time","type":"string"},"id":{"format":"uuid","type":"string"},"issueDate":{"format":"date","type":"string"},"issuer":{"properties":{"address":{"type":"null"},"name":{"type":"string"}},"required":["name","address"],"type":"object"},"items":{"items":{"properties":{"description":{"type":"null"},"discount":{"type":"null"},"id":{"format":"uuid","type":"string"},"name":{"type":"string"},"quantity":{"type":"integer"},"serviceId":{"type":"null"},"unitPrice":{"type":"integer"}},"required":["id","name","discount","quantity","serviceId","unitPrice","description"],"type":"object"},"type":"array"},"language":{"type":"null"},"lastViewedAt":{"format":"date-time","type":"string"},"notes":{"type":"null"},"number":{"type":"string"},"organizationId":{"format":"uuid","type":"string"},"overdue":{"type":"boolean"},"owner":{"properties":{"id":{"format":"uuid","type":"string"},"name":{"type":"string"}},"required":["id","name"],"type":"object"},"ownerId":{"format":"uuid","type":"string"},"paidAt":{"type":"null"},"payment":{"type":"null"},"paymentMethod":{"type":"null"},"paymentNote":{"type":"null"},"publicId":{"type":"string"},"recipient":{"properties":{"address":{"type":"null"},"name":{"type":"string"}},"required":["name","address"],"type":"object"},"recurrence":{"type":"null"},"recurringFromId":{"type":"null"},"reminderDays":{"type":"null"},"remindersSent":{"type":"array"},"sentAt":{"format":"date-time","type":"string"},"status":{"type":"string"},"subtotal":{"type":"integer"},"taxAmount":{"type":"integer"},"taxBasisPoints":{"type":"null"},"taxPercent":{"type":"null"},"total":{"type":"integer"},"updatedAt":{"format":"date-time","type":"string"},"updatedBy":{"format":"uuid","type":"string"},"url":{"format":"uri","type":"string"},"viewCount":{"type":"integer"},"voidReason":{"type":"null"},"voidedAt":{"type":"null"}},"required":["id","organizationId","publicId","number","status","dealId","companyId","contactId","ownerId","issuer","recipient","language","currency","issueDate","dueDate","items","discount","taxBasisPoints","notes","subtotal","discountAmount","taxAmount","total","sentAt","paidAt","acceptPayments","paymentMethod","paymentNote","voidedAt","voidReason","viewCount","firstViewedAt","lastViewedAt","reminderDays","remindersSent","recurrence","recurringFromId","createdBy","updatedBy","createdAt","updatedAt","taxPercent","overdue","company","contact","owner","deal","url","contactEmail","payment"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/invoices/{id}/void":{"post":{"operationId":"POST /v1/invoices/{id}/void","summary":"Cancels an invoice, refunding it through Stripe when asked (administrators).","tags":["invoices"],"x-feature":"invoices","x-action":"update","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"default":{},"type":"object","properties":{"reason":{"anyOf":[{"type":"string","maxLength":1000},{"type":"null"}]},"refund":{"default":false,"type":"boolean"}}}}}},"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"acceptPayments":{"type":"boolean"},"company":{"type":"null"},"companyId":{"type":"null"},"contact":{"properties":{"id":{"format":"uuid","type":"string"},"name":{"type":"string"}},"required":["id","name"],"type":["null","object"]},"contactEmail":{"format":"email","type":["null","string"]},"contactId":{"format":"uuid","type":["null","string"]},"createdAt":{"format":"date-time","type":"string"},"createdBy":{"format":"uuid","type":"string"},"currency":{"type":"string"},"deal":{"type":"null"},"dealId":{"type":"null"},"discount":{"type":"null"},"discountAmount":{"type":"integer"},"dueDate":{"format":"date","type":"string"},"firstViewedAt":{"format":"date-time","type":["null","string"]},"id":{"format":"uuid","type":"string"},"issueDate":{"format":"date","type":"string"},"issuer":{"properties":{"address":{"type":"null"},"name":{"type":"string"}},"required":["address","name"],"type":"object"},"items":{"items":{"properties":{"description":{"type":"null"},"discount":{"type":"null"},"id":{"format":"uuid","type":"string"},"name":{"type":"string"},"quantity":{"type":"integer"},"serviceId":{"type":"null"},"unitPrice":{"type":"integer"}},"required":["description","discount","id","name","quantity","serviceId","unitPrice"],"type":"object"},"type":"array"},"language":{"type":"null"},"lastViewedAt":{"format":"date-time","type":["null","string"]},"notes":{"type":"null"},"number":{"type":"string"},"organizationId":{"format":"uuid","type":"string"},"overdue":{"type":"boolean"},"owner":{"properties":{"id":{"format":"uuid","type":"string"},"name":{"type":"string"}},"required":["id","name"],"type":"object"},"ownerId":{"format":"uuid","type":"string"},"paidAt":{"type":"null"},"payment":{"properties":{"amount":{"type":"integer"},"applicationFee":{"type":"integer"},"createdAt":{"format":"date-time","type":"string"},"currency":{"type":"string"},"id":{"format":"uuid","type":"string"},"paidAt":{"format":"date-time","type":"string"},"payerEmail":{"format":"email","type":"string"},"payerName":{"type":"string"},"status":{"type":"string"}},"required":["amount","applicationFee","createdAt","currency","id","paidAt","payerEmail","payerName","status"],"type":["null","object"]},"paymentMethod":{"type":"null"},"paymentNote":{"type":"null"},"publicId":{"type":"string"},"recipient":{"properties":{"address":{"type":"null"},"name":{"type":"string"}},"required":["name","address"],"type":["null","object"]},"recurrence":{"type":"null"},"recurringFromId":{"type":"null"},"reminderDays":{"type":"null"},"remindersSent":{"type":"array"},"sentAt":{"format":"date-time","type":"string"},"status":{"type":"string"},"subtotal":{"type":"integer"},"taxAmount":{"type":"integer"},"taxBasisPoints":{"type":"null"},"taxPercent":{"type":"null"},"total":{"type":"integer"},"updatedAt":{"format":"date-time","type":"string"},"updatedBy":{"format":"uuid","type":"string"},"url":{"format":"uri","type":"string"},"viewCount":{"type":"integer"},"voidReason":{"type":["null","string"]},"voidedAt":{"format":"date-time","type":"string"}},"required":["acceptPayments","company","companyId","contact","contactEmail","contactId","createdAt","createdBy","currency","deal","dealId","discount","discountAmount","dueDate","firstViewedAt","id","issueDate","issuer","items","language","lastViewedAt","notes","number","organizationId","overdue","owner","ownerId","paidAt","payment","paymentMethod","paymentNote","publicId","recipient","recurrence","recurringFromId","reminderDays","remindersSent","sentAt","status","subtotal","taxAmount","taxBasisPoints","taxPercent","total","updatedAt","updatedBy","url","viewCount","voidReason","voidedAt"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/link-pages":{"get":{"operationId":"GET /v1/link-pages","summary":"Lists the link pages.","tags":["linkPages"],"x-feature":"linkPages","x-action":"read","responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"items":{"properties":{"active":{"type":"boolean"},"bio":{"type":"string"},"clicks30":{"type":"integer"},"createdAt":{"format":"date-time","type":"string"},"createdBy":{"format":"uuid","type":"string"},"id":{"format":"uuid","type":"string"},"links":{"items":{"properties":{"active":{"type":"boolean"},"featured":{"type":"boolean"},"icon":{"type":"null"},"id":{"type":"string"},"kind":{"type":"string"},"style":{"type":"null"},"title":{"type":"string"},"url":{"type":["null","string"]}},"required":["id","url","icon","kind","style","title","active","featured"],"type":"object"},"type":"array"},"name":{"type":"string"},"showBranding":{"type":"boolean"},"slug":{"type":"string"},"templateId":{"type":"null"},"theme":{"properties":{},"required":[],"type":"object"},"title":{"type":"string"},"updatedAt":{"format":"date-time","type":"string"},"updatedBy":{"format":"uuid","type":"string"},"url":{"format":"uri","type":"string"},"views30":{"type":"integer"}},"required":["id","slug","name","title","bio","links","showBranding","templateId","theme","active","createdBy","updatedBy","createdAt","updatedAt","url","views30","clicks30"],"type":"object"},"type":"array"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"post":{"operationId":"POST /v1/link-pages","summary":"Creates a link page.","tags":["linkPages"],"x-feature":"linkPages","x-action":"create","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"name":{"type":"string","minLength":1,"maxLength":120},"slug":{"type":"string","pattern":"^[a-z0-9](?:[a-z0-9-]{1,38}[a-z0-9])$"},"title":{"type":"string","minLength":1,"maxLength":120},"bio":{"anyOf":[{"type":"string","maxLength":300},{"type":"null"}]},"links":{"maxItems":100,"type":"array","items":{"type":"object","properties":{"id":{"type":"string","pattern":"^[A-Za-z0-9_-]{6,40}$"},"kind":{"default":"link","type":"string","enum":["link","header"]},"title":{"type":"string","minLength":1,"maxLength":100},"url":{"anyOf":[{"type":"string","maxLength":2000},{"type":"null"}]},"icon":{"anyOf":[{"type":"string","enum":["link","globe","instagram","whatsapp","tiktok","youtube","linkedin","facebook","x","telegram","spotify","email","phone","calendar","form","file","shop","star","map","gift"]},{"type":"null"}]},"featured":{"default":false,"type":"boolean"},"active":{"default":true,"type":"boolean"},"style":{"anyOf":[{"type":"object","properties":{"background":{"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"text":{"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"border":{"default":"none","type":"string","enum":["none","thin","thick"]},"borderColor":{"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"shadow":{"default":"none","type":"string","enum":["none","soft","hard"]},"shadowColor":{"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"radius":{"default":"theme","type":"string","enum":["theme","square","rounded","pill"]},"hover":{"default":"simple","type":"string","enum":["simple","lift","grow","outline","none"]}}},{"type":"null"}]}},"required":["id","title"]}},"showBranding":{"default":true,"type":"boolean"},"templateId":{"anyOf":[{"type":"string","enum":["classic","modern","minimal","bold"]},{"type":"null"}]},"theme":{"default":{},"type":"object","properties":{"primaryColor":{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"accentColor":{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"backgroundColor":{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"textColor":{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"headingFont":{"type":"string","pattern":"^[A-Za-z0-9 ]{1,60}$"},"bodyFont":{"type":"string","pattern":"^[A-Za-z0-9 ]{1,60}$"},"coverImageUrl":{"type":"string","maxLength":2000,"format":"uri"},"cornerRadius":{"type":"string","enum":["none","small","medium","large"]}},"additionalProperties":false},"active":{"default":true,"type":"boolean"}},"required":["name","title"]}}}},"responses":{"201":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"active":{"type":"boolean"},"bio":{"type":["null","string"]},"clicks30":{"type":"integer"},"createdAt":{"format":"date-time","type":"string"},"createdBy":{"format":"uuid","type":"string"},"id":{"format":"uuid","type":"string"},"links":{"items":{"properties":{"active":{"type":"boolean"},"featured":{"type":"boolean"},"icon":{"type":["null","string"]},"id":{"type":"string"},"kind":{"type":"string"},"style":{"additionalProperties":{},"type":["null","object"]},"title":{"type":"string"},"url":{"type":["null","string"]}},"required":["id","url","icon","kind","style","title","active","featured"],"type":"object"},"type":"array"},"name":{"type":"string"},"showBranding":{"type":"boolean"},"slug":{"type":"string"},"templateId":{"type":"null"},"theme":{"properties":{},"required":[],"type":"object"},"title":{"type":"string"},"updatedAt":{"format":"date-time","type":"string"},"updatedBy":{"format":"uuid","type":"string"},"url":{"format":"uri","type":"string"},"views30":{"type":"integer"}},"required":["active","bio","clicks30","createdAt","createdBy","id","links","name","showBranding","slug","templateId","theme","title","updatedAt","updatedBy","url","views30"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/link-pages/{id}":{"delete":{"operationId":"DELETE /v1/link-pages/{id}","summary":"Deletes a link page.","tags":["linkPages"],"x-feature":"linkPages","x-action":"delete","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"204":{"description":"Done, with no content."},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"get":{"operationId":"GET /v1/link-pages/{id}","summary":"Returns a link page with its links and look.","tags":["linkPages"],"x-feature":"linkPages","x-action":"read","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"patch":{"operationId":"PATCH /v1/link-pages/{id}","summary":"Changes a link page: links, texts, look and address.","tags":["linkPages"],"x-feature":"linkPages","x-action":"update","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"name":{"type":"string","minLength":1,"maxLength":120},"slug":{"type":"string","pattern":"^[a-z0-9](?:[a-z0-9-]{1,38}[a-z0-9])$"},"title":{"type":"string","minLength":1,"maxLength":120},"bio":{"anyOf":[{"type":"string","maxLength":300},{"type":"null"}]},"links":{"maxItems":100,"type":"array","items":{"type":"object","properties":{"id":{"type":"string","pattern":"^[A-Za-z0-9_-]{6,40}$"},"kind":{"default":"link","type":"string","enum":["link","header"]},"title":{"type":"string","minLength":1,"maxLength":100},"url":{"anyOf":[{"type":"string","maxLength":2000},{"type":"null"}]},"icon":{"anyOf":[{"type":"string","enum":["link","globe","instagram","whatsapp","tiktok","youtube","linkedin","facebook","x","telegram","spotify","email","phone","calendar","form","file","shop","star","map","gift"]},{"type":"null"}]},"featured":{"default":false,"type":"boolean"},"active":{"default":true,"type":"boolean"},"style":{"anyOf":[{"type":"object","properties":{"background":{"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"text":{"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"border":{"default":"none","type":"string","enum":["none","thin","thick"]},"borderColor":{"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"shadow":{"default":"none","type":"string","enum":["none","soft","hard"]},"shadowColor":{"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"radius":{"default":"theme","type":"string","enum":["theme","square","rounded","pill"]},"hover":{"default":"simple","type":"string","enum":["simple","lift","grow","outline","none"]}}},{"type":"null"}]}},"required":["id","title"]}},"showBranding":{"type":"boolean"},"templateId":{"anyOf":[{"type":"string","enum":["classic","modern","minimal","bold"]},{"type":"null"}]},"theme":{"type":"object","properties":{"primaryColor":{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"accentColor":{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"backgroundColor":{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"textColor":{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"headingFont":{"type":"string","pattern":"^[A-Za-z0-9 ]{1,60}$"},"bodyFont":{"type":"string","pattern":"^[A-Za-z0-9 ]{1,60}$"},"coverImageUrl":{"type":"string","maxLength":2000,"format":"uri"},"cornerRadius":{"type":"string","enum":["none","small","medium","large"]}},"additionalProperties":false},"active":{"type":"boolean"}}}}}},"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/link-pages/{id}/stats":{"get":{"operationId":"GET /v1/link-pages/{id}/stats","summary":"Views of a link page and clicks per link, per day.","tags":["linkPages"],"x-feature":"linkPages","x-action":"read","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}},{"name":"days","in":"query","required":false,"schema":{"default":30,"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"days":{"type":"integer"},"links":{"items":{"properties":{"clicks":{"type":"integer"},"id":{"type":"string"},"title":{"type":"string"},"url":{"type":"string"}},"required":["id","title","url","clicks"],"type":"object"},"type":"array"},"series":{"items":{"properties":{"clicks":{"type":"integer"},"day":{"format":"date","type":"string"},"views":{"type":"integer"}},"required":["day","views","clicks"],"type":"object"},"type":"array"},"sources":{"items":{"properties":{"source":{"type":"string"},"views":{"type":"integer"}},"required":["source","views"],"type":"object"},"type":"array"},"totals":{"properties":{"clickRate":{"type":"number"},"clicks":{"type":"integer"},"views":{"type":"integer"}},"required":["views","clicks","clickRate"],"type":"object"}},"required":["days","totals","series","links","sources"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/link-pages/look":{"get":{"operationId":"GET /v1/link-pages/look","summary":"The look a link page’s preview starts from; saves nothing.","tags":["linkPages"],"x-feature":"linkPages","x-action":"read","parameters":[{"name":"templateId","in":"query","required":false,"schema":{"type":"string","enum":["classic","modern","minimal","bold"]}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/link-pages/slug-check":{"get":{"operationId":"GET /v1/link-pages/slug-check","summary":"Whether an address is free for a link page.","tags":["linkPages"],"x-feature":"linkPages","x-action":"read","parameters":[{"name":"slug","in":"query","required":true,"schema":{"type":"string","maxLength":60}},{"name":"exclude","in":"query","required":false,"schema":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"available":{"type":"boolean"},"slug":{"type":"string"},"valid":{"type":"boolean"}},"required":["slug","available","valid"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/lists":{"get":{"operationId":"GET /v1/lists","summary":"Lists the contact lists.","tags":["lists"],"x-feature":"lists","x-action":"read","responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"post":{"operationId":"POST /v1/lists","summary":"Creates a list: manual, or smart from filters.","tags":["lists"],"x-feature":"lists","x-action":"create","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"name":{"type":"string","minLength":1,"maxLength":100},"description":{"anyOf":[{"type":"string","maxLength":500},{"type":"null"}]},"color":{"default":"gray","type":"string","enum":["gray","red","orange","yellow","green","teal","blue","purple","pink"]},"kind":{"type":"string","enum":["manual","smart"]},"filters":{"default":{},"type":"object","properties":{"lifecycleStages":{"maxItems":10,"type":"array","items":{"type":"string","enum":["subscriber","lead","opportunity","customer","evangelist","other"]}},"leadStatuses":{"maxItems":10,"type":"array","items":{"type":"string","enum":["new","open","in_progress","connected","qualified","unqualified"]}},"ownerIds":{"maxItems":50,"type":"array","items":{"type":"string","minLength":1}},"companyIds":{"maxItems":50,"type":"array","items":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"}},"tagIds":{"maxItems":50,"type":"array","items":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"}},"sources":{"maxItems":20,"type":"array","items":{"type":"string","minLength":1,"maxLength":100}},"hasEmail":{"type":"boolean"},"hasPhone":{"type":"boolean"},"marketingOptIn":{"type":"boolean"},"createdFrom":{"type":"string","format":"date","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))$"},"createdTo":{"type":"string","format":"date","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))$"},"custom":{"maxItems":10,"type":"array","items":{"type":"object","properties":{"key":{"type":"string","minLength":1,"maxLength":64},"op":{"type":"string","enum":["equals","isSet","isNotSet"]},"value":{"anyOf":[{"type":"string","maxLength":500},{"type":"number"},{"type":"boolean"}]}},"required":["key","op"]}}},"additionalProperties":false},"addMatching":{"type":"object","properties":{"lifecycleStages":{"maxItems":10,"type":"array","items":{"type":"string","enum":["subscriber","lead","opportunity","customer","evangelist","other"]}},"leadStatuses":{"maxItems":10,"type":"array","items":{"type":"string","enum":["new","open","in_progress","connected","qualified","unqualified"]}},"ownerIds":{"maxItems":50,"type":"array","items":{"type":"string","minLength":1}},"companyIds":{"maxItems":50,"type":"array","items":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"}},"tagIds":{"maxItems":50,"type":"array","items":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"}},"sources":{"maxItems":20,"type":"array","items":{"type":"string","minLength":1,"maxLength":100}},"hasEmail":{"type":"boolean"},"hasPhone":{"type":"boolean"},"marketingOptIn":{"type":"boolean"},"createdFrom":{"type":"string","format":"date","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))$"},"createdTo":{"type":"string","format":"date","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))$"},"custom":{"maxItems":10,"type":"array","items":{"type":"object","properties":{"key":{"type":"string","minLength":1,"maxLength":64},"op":{"type":"string","enum":["equals","isSet","isNotSet"]},"value":{"anyOf":[{"type":"string","maxLength":500},{"type":"number"},{"type":"boolean"}]}},"required":["key","op"]}}},"additionalProperties":false}},"required":["name","kind"]}}}},"responses":{"201":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"color":{"type":"string"},"createdAt":{"format":"date-time","type":"string"},"createdBy":{"format":"uuid","type":"string"},"description":{"type":"null"},"filters":{"properties":{"lifecycleStages":{"items":{"type":"string"},"type":"array"},"tagIds":{"items":{"format":"uuid","type":"string"},"type":"array"}},"required":[],"type":"object"},"id":{"format":"uuid","type":"string"},"kind":{"type":"string"},"limit":{"type":"integer"},"matchingCount":{"type":"integer"},"memberCount":{"type":"integer"},"name":{"type":"string"},"organizationId":{"format":"uuid","type":"string"},"paused":{"type":"boolean"},"updatedAt":{"format":"date-time","type":"string"},"updatedBy":{"format":"uuid","type":"string"}},"required":["color","createdAt","createdBy","description","filters","id","kind","limit","matchingCount","memberCount","name","organizationId","paused","updatedAt","updatedBy"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/lists/{id}":{"delete":{"operationId":"DELETE /v1/lists/{id}","summary":"Deletes a list; its contacts stay.","tags":["lists"],"x-feature":"lists","x-action":"delete","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"204":{"description":"Done, with no content."},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"get":{"operationId":"GET /v1/lists/{id}","summary":"Returns a list with its filters and size.","tags":["lists"],"x-feature":"lists","x-action":"read","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"color":{"type":"string"},"createdAt":{"format":"date-time","type":"string"},"createdBy":{"format":"uuid","type":"string"},"description":{"type":"null"},"filters":{"properties":{},"required":[],"type":"object"},"id":{"format":"uuid","type":"string"},"kind":{"type":"string"},"limit":{"type":"integer"},"matchingCount":{"type":"integer"},"memberCount":{"type":"integer"},"name":{"type":"string"},"organizationId":{"format":"uuid","type":"string"},"paused":{"type":"boolean"},"updatedAt":{"format":"date-time","type":"string"},"updatedBy":{"format":"uuid","type":"string"}},"required":["color","createdAt","createdBy","description","filters","id","kind","limit","matchingCount","memberCount","name","organizationId","paused","updatedAt","updatedBy"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"patch":{"operationId":"PATCH /v1/lists/{id}","summary":"Changes a list’s name or filters.","tags":["lists"],"x-feature":"lists","x-action":"update","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"name":{"type":"string","minLength":1,"maxLength":100},"description":{"anyOf":[{"type":"string","maxLength":500},{"type":"null"}]},"color":{"default":"gray","type":"string","enum":["gray","red","orange","yellow","green","teal","blue","purple","pink"]},"filters":{"type":"object","properties":{"lifecycleStages":{"maxItems":10,"type":"array","items":{"type":"string","enum":["subscriber","lead","opportunity","customer","evangelist","other"]}},"leadStatuses":{"maxItems":10,"type":"array","items":{"type":"string","enum":["new","open","in_progress","connected","qualified","unqualified"]}},"ownerIds":{"maxItems":50,"type":"array","items":{"type":"string","minLength":1}},"companyIds":{"maxItems":50,"type":"array","items":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"}},"tagIds":{"maxItems":50,"type":"array","items":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"}},"sources":{"maxItems":20,"type":"array","items":{"type":"string","minLength":1,"maxLength":100}},"hasEmail":{"type":"boolean"},"hasPhone":{"type":"boolean"},"marketingOptIn":{"type":"boolean"},"createdFrom":{"type":"string","format":"date","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))$"},"createdTo":{"type":"string","format":"date","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))$"},"custom":{"maxItems":10,"type":"array","items":{"type":"object","properties":{"key":{"type":"string","minLength":1,"maxLength":64},"op":{"type":"string","enum":["equals","isSet","isNotSet"]},"value":{"anyOf":[{"type":"string","maxLength":500},{"type":"number"},{"type":"boolean"}]}},"required":["key","op"]}}},"additionalProperties":false}}}}}},"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"color":{"type":"string"},"createdAt":{"format":"date-time","type":"string"},"createdBy":{"format":"uuid","type":"string"},"description":{"type":"null"},"filters":{"properties":{"custom":{"items":{"properties":{"key":{"type":"string"},"op":{"type":"string"},"value":{"type":"string"}},"required":["op","key"],"type":"object"},"type":"array"},"hasEmail":{"type":"boolean"}},"required":[],"type":"object"},"id":{"format":"uuid","type":"string"},"kind":{"type":"string"},"limit":{"type":"integer"},"matchingCount":{"type":"integer"},"memberCount":{"type":"integer"},"name":{"type":"string"},"organizationId":{"format":"uuid","type":"string"},"paused":{"type":"boolean"},"updatedAt":{"format":"date-time","type":"string"},"updatedBy":{"format":"uuid","type":"string"}},"required":["id","organizationId","name","description","color","kind","filters","createdBy","updatedBy","createdAt","updatedAt","memberCount","matchingCount","limit","paused"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/lists/{id}/convert":{"post":{"operationId":"POST /v1/lists/{id}/convert","summary":"Turns a smart list into a manual one with the contacts it matches now.","tags":["lists"],"x-feature":"lists","x-action":"update","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"color":{"type":"string"},"createdAt":{"format":"date-time","type":"string"},"createdBy":{"format":"uuid","type":"string"},"description":{"type":"null"},"filters":{"properties":{},"required":[],"type":"object"},"id":{"format":"uuid","type":"string"},"kind":{"type":"string"},"limit":{"type":"integer"},"matchingCount":{"type":"integer"},"memberCount":{"type":"integer"},"name":{"type":"string"},"organizationId":{"format":"uuid","type":"string"},"paused":{"type":"boolean"},"updatedAt":{"format":"date-time","type":"string"},"updatedBy":{"format":"uuid","type":"string"}},"required":["id","organizationId","name","description","color","kind","filters","createdBy","updatedBy","createdAt","updatedAt","memberCount","matchingCount","limit","paused"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/lists/{id}/export":{"get":{"operationId":"GET /v1/lists/{id}/export","summary":"Downloads a list’s contacts as a CSV file.","tags":["lists"],"x-feature":"lists","x-action":"read","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/lists/{id}/import":{"post":{"operationId":"POST /v1/lists/{id}/import","summary":"Imports up to 500 spreadsheet rows into a list, creating or updating contacts.","tags":["lists"],"x-feature":"lists","x-action":"update","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"rows":{"minItems":1,"maxItems":500,"type":"array","items":{"type":"object","properties":{"email":{"type":"string","maxLength":320},"firstName":{"anyOf":[{"type":"string","maxLength":100},{"type":"null"}]},"lastName":{"anyOf":[{"type":"string","maxLength":100},{"type":"null"}]},"phone":{"anyOf":[{"type":"string","maxLength":40},{"type":"null"}]},"jobTitle":{"anyOf":[{"type":"string","maxLength":150},{"type":"null"}]},"source":{"anyOf":[{"type":"string","maxLength":100},{"type":"null"}]}},"required":["email"]}}},"required":["rows"]}}}},"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"added":{"type":"integer"},"created":{"type":"integer"},"errors":{"items":{"properties":{"code":{"type":"string"},"row":{"type":"integer"}},"required":["row","code"],"type":"object"},"type":"array"},"list":{"properties":{"color":{"type":"string"},"createdAt":{"format":"date-time","type":"string"},"createdBy":{"format":"uuid","type":"string"},"description":{"type":"null"},"filters":{"properties":{},"required":[],"type":"object"},"id":{"format":"uuid","type":"string"},"kind":{"type":"string"},"limit":{"type":"integer"},"matchingCount":{"type":"integer"},"memberCount":{"type":"integer"},"name":{"type":"string"},"organizationId":{"format":"uuid","type":"string"},"paused":{"type":"boolean"},"updatedAt":{"format":"date-time","type":"string"},"updatedBy":{"format":"uuid","type":"string"}},"required":["color","createdAt","createdBy","description","filters","id","kind","limit","matchingCount","memberCount","name","organizationId","paused","updatedAt","updatedBy"],"type":"object"},"matched":{"type":"integer"}},"required":["added","created","errors","list","matched"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/lists/{id}/members":{"get":{"operationId":"GET /v1/lists/{id}/members","summary":"Lists a list’s contacts.","tags":["lists"],"x-feature":"lists","x-action":"read","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}},{"name":"page","in":"query","required":false,"schema":{"default":1,"type":"integer","minimum":1,"maximum":9007199254740991}},{"name":"pageSize","in":"query","required":false,"schema":{"default":50,"type":"integer","minimum":1,"maximum":100}},{"name":"q","in":"query","required":false,"schema":{"type":"string","minLength":1,"maxLength":200}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"data":{"items":{"properties":{"addedAt":{"type":["null","string"]},"companyName":{"type":"null"},"createdAt":{"format":"date-time","type":"string"},"email":{"format":"email","type":["null","string"]},"firstName":{"type":"string"},"id":{"format":"uuid","type":"string"},"jobTitle":{"type":"null"},"lastName":{"type":["null","string"]},"leadStatus":{"type":"null"},"lifecycleStage":{"type":["null","string"]},"marketingOptIn":{"type":"boolean"},"ownerId":{"format":"uuid","type":["null","string"]},"ownerName":{"type":["null","string"]},"phone":{"type":["null","string"]},"source":{"type":["null","string"]},"tags":{"type":["null","string"]}},"required":["addedAt","companyName","createdAt","email","firstName","id","jobTitle","lastName","leadStatus","lifecycleStage","marketingOptIn","ownerId","ownerName","phone","source","tags"],"type":"object"},"type":"array"},"page":{"type":"integer"},"pageSize":{"type":"integer"},"total":{"type":"integer"}},"required":["data","page","pageSize","total"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"post":{"operationId":"POST /v1/lists/{id}/members","summary":"Adds contacts to a manual list.","tags":["lists"],"x-feature":"lists","x-action":"update","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"contactIds":{"minItems":1,"maxItems":1000,"type":"array","items":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"}}},"required":["contactIds"]}}}},"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"added":{"type":"integer"},"alreadyInList":{"type":"integer"},"list":{"properties":{"color":{"type":"string"},"createdAt":{"format":"date-time","type":"string"},"createdBy":{"format":"uuid","type":"string"},"description":{"type":"null"},"filters":{"properties":{},"required":[],"type":"object"},"id":{"format":"uuid","type":"string"},"kind":{"type":"string"},"limit":{"type":"integer"},"matchingCount":{"type":"integer"},"memberCount":{"type":"integer"},"name":{"type":"string"},"organizationId":{"format":"uuid","type":"string"},"paused":{"type":"boolean"},"updatedAt":{"format":"date-time","type":"string"},"updatedBy":{"format":"uuid","type":"string"}},"required":["color","createdAt","createdBy","description","filters","id","kind","limit","matchingCount","memberCount","name","organizationId","paused","updatedAt","updatedBy"],"type":"object"}},"required":["added","alreadyInList","list"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/lists/{id}/members/bulk":{"post":{"operationId":"POST /v1/lists/{id}/members/bulk","summary":"Changes the owner, lifecycle stage or lead status of a list’s contacts.","tags":["lists"],"x-feature":"lists","x-action":"update","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"contactIds":{"minItems":1,"maxItems":500,"type":"array","items":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"}},"set":{"type":"object","properties":{"ownerId":{"anyOf":[{"type":"string","minLength":1},{"type":"null"}]},"lifecycleStage":{"anyOf":[{"type":"string","enum":["subscriber","lead","opportunity","customer","evangelist","other"]},{"type":"null"}]},"leadStatus":{"anyOf":[{"type":"string","enum":["new","open","in_progress","connected","qualified","unqualified"]},{"type":"null"}]}}}},"required":["contactIds","set"]}}}},"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"updated":{"type":"integer"}},"required":["updated"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/lists/{id}/members/remove":{"post":{"operationId":"POST /v1/lists/{id}/members/remove","summary":"Removes contacts from a manual list.","tags":["lists"],"x-feature":"lists","x-action":"update","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"contactIds":{"minItems":1,"maxItems":1000,"type":"array","items":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"}}},"required":["contactIds"]}}}},"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"list":{"properties":{"color":{"type":"string"},"createdAt":{"format":"date-time","type":"string"},"createdBy":{"format":"uuid","type":"string"},"description":{"type":"null"},"filters":{"properties":{},"required":[],"type":"object"},"id":{"format":"uuid","type":"string"},"kind":{"type":"string"},"limit":{"type":"integer"},"matchingCount":{"type":"integer"},"memberCount":{"type":"integer"},"name":{"type":"string"},"organizationId":{"format":"uuid","type":"string"},"paused":{"type":"boolean"},"updatedAt":{"format":"date-time","type":"string"},"updatedBy":{"format":"uuid","type":"string"}},"required":["id","organizationId","name","description","color","kind","filters","createdBy","updatedBy","createdAt","updatedAt","memberCount","matchingCount","limit","paused"],"type":"object"},"removed":{"type":"integer"}},"required":["removed","list"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/lists/for-contact/{contactId}":{"get":{"operationId":"GET /v1/lists/for-contact/{contactId}","summary":"The lists a contact is in.","tags":["lists"],"x-feature":"lists","x-action":"read","parameters":[{"name":"contactId","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"items":{"properties":{"color":{"type":"string"},"id":{"format":"uuid","type":"string"},"kind":{"type":"string"},"name":{"type":"string"}},"required":["color","id","kind","name"],"type":"object"},"type":"array"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/lists/preview":{"post":{"operationId":"POST /v1/lists/preview","summary":"How many contacts some filters match now; changes nothing.","tags":["lists"],"x-feature":"lists","x-action":"read","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"filters":{"default":{},"type":"object","properties":{"lifecycleStages":{"maxItems":10,"type":"array","items":{"type":"string","enum":["subscriber","lead","opportunity","customer","evangelist","other"]}},"leadStatuses":{"maxItems":10,"type":"array","items":{"type":"string","enum":["new","open","in_progress","connected","qualified","unqualified"]}},"ownerIds":{"maxItems":50,"type":"array","items":{"type":"string","minLength":1}},"companyIds":{"maxItems":50,"type":"array","items":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"}},"tagIds":{"maxItems":50,"type":"array","items":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"}},"sources":{"maxItems":20,"type":"array","items":{"type":"string","minLength":1,"maxLength":100}},"hasEmail":{"type":"boolean"},"hasPhone":{"type":"boolean"},"marketingOptIn":{"type":"boolean"},"createdFrom":{"type":"string","format":"date","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))$"},"createdTo":{"type":"string","format":"date","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))$"},"custom":{"maxItems":10,"type":"array","items":{"type":"object","properties":{"key":{"type":"string","minLength":1,"maxLength":64},"op":{"type":"string","enum":["equals","isSet","isNotSet"]},"value":{"anyOf":[{"type":"string","maxLength":500},{"type":"number"},{"type":"boolean"}]}},"required":["key","op"]}}},"additionalProperties":false}}}}}},"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"limit":{"type":"integer"},"matchingCount":{"type":"integer"},"memberCount":{"type":"integer"}},"required":["matchingCount","memberCount","limit"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/loyalty/companies/{companyId}":{"get":{"operationId":"GET /v1/loyalty/companies/{companyId}","summary":"The loyalty cards of a company’s contacts.","tags":["loyalty"],"x-feature":"loyalty","x-action":"read","parameters":[{"name":"companyId","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/loyalty/contacts/{contactId}":{"get":{"operationId":"GET /v1/loyalty/contacts/{contactId}","summary":"A contact’s card: member or not, balance, tier, history and redemptions.","tags":["loyalty"],"x-feature":"loyalty","x-action":"read","parameters":[{"name":"contactId","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"member":{"properties":{"balance":{"type":"integer"},"cardUrl":{"format":"uri","type":"string"},"contactId":{"format":"uuid","type":"string"},"createdAt":{"format":"date-time","type":"string"},"currency":{"type":"string"},"id":{"format":"uuid","type":"string"},"lastActivityAt":{"format":"date-time","type":"string"},"lifetimePoints":{"type":"integer"},"nextTier":{"properties":{"name":{"type":"string"},"pointsToGo":{"type":"integer"}},"required":["name","pointsToGo"],"type":["null","object"]},"purchases":{"type":"integer"},"spent":{"type":"integer"},"tier":{"properties":{"index":{"type":"integer"},"name":{"type":"string"}},"required":["index","name"],"type":["null","object"]}},"required":["balance","cardUrl","contactId","createdAt","currency","id","lastActivityAt","lifetimePoints","nextTier","purchases","spent","tier"],"type":["null","object"]},"program":{"properties":{"active":{"type":"boolean"},"autoEnroll":{"type":"boolean"},"currency":{"type":"string"},"eventRules":{"items":{"properties":{"event":{"type":"string"},"perDay":{"type":"integer"},"points":{"type":"integer"}},"required":["event","perDay","points"],"type":"object"},"type":"array"},"expirationMonths":{"type":["integer","null"]},"minPurchaseAmount":{"type":"integer"},"name":{"type":["null","string"]},"organizationId":{"format":"uuid","type":"string"},"pointsLabel":{"type":["null","string"]},"pointsPerPurchase":{"type":"integer"},"pointsPerUnit":{"type":"integer"},"selfRedeem":{"type":"boolean"},"sources":{"properties":{"invoices":{"type":"boolean"},"manualPayments":{"type":"boolean"},"payments":{"type":"boolean"}},"required":["invoices","manualPayments","payments"],"type":"object"},"terms":{"type":["null","string"]},"tiers":{"items":{"properties":{"minPoints":{"type":"integer"},"multiplierPercent":{"type":"integer"},"name":{"type":"string"}},"required":["name","minPoints","multiplierPercent"],"type":"object"},"type":"array"},"unitAmount":{"type":"integer"},"updatedAt":{"format":"date-time","type":"string"},"welcomePoints":{"type":"integer"}},"required":["active","autoEnroll","currency","eventRules","expirationMonths","minPurchaseAmount","name","organizationId","pointsLabel","pointsPerPurchase","pointsPerUnit","selfRedeem","sources","terms","tiers","unitAmount","updatedAt","welcomePoints"],"type":"object"},"redemptions":{"items":{"properties":{"canceledAt":{"format":"date-time","type":["null","string"]},"code":{"type":"string"},"createdAt":{"format":"date-time","type":"string"},"createdBy":{"type":"null"},"fulfilledAt":{"type":"null"},"fulfilledBy":{"type":"null"},"id":{"format":"uuid","type":"string"},"memberId":{"format":"uuid","type":"string"},"organizationId":{"format":"uuid","type":"string"},"points":{"type":"integer"},"reward":{"properties":{"currency":{"type":"string"},"kind":{"type":"string"},"name":{"type":"string"},"value":{"type":"null"}},"required":["kind","name","value","currency"],"type":"object"},"rewardId":{"format":"uuid","type":"string"},"source":{"type":"string"},"status":{"type":"string"}},"required":["id","organizationId","memberId","rewardId","reward","points","code","status","source","createdBy","fulfilledAt","fulfilledBy","canceledAt","createdAt"],"type":"object"},"type":"array"},"transactions":{"items":{"properties":{"amount":{"type":["integer","null"]},"createdAt":{"format":"date-time","type":"string"},"createdBy":{"format":"uuid","type":["null","string"]},"currency":{"type":["null","string"]},"id":{"format":"uuid","type":"string"},"kind":{"type":"string"},"memberId":{"format":"uuid","type":"string"},"note":{"type":["null","string"]},"organizationId":{"format":"uuid","type":"string"},"points":{"type":"integer"},"reversedAt":{"format":"date-time","type":["null","string"]},"source":{"type":"string"},"sourceKey":{"type":["null","string"]}},"required":["amount","createdAt","createdBy","currency","id","kind","memberId","note","organizationId","points","reversedAt","source","sourceKey"],"type":"object"},"type":"array"}},"required":["member","program","redemptions","transactions"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/loyalty/contacts/{contactId}/adjust":{"post":{"operationId":"POST /v1/loyalty/contacts/{contactId}/adjust","summary":"Adds or takes away points by hand, with the reason.","tags":["loyalty"],"x-feature":"loyalty","x-action":"update","parameters":[{"name":"contactId","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"points":{"type":"integer","minimum":-10000000,"maximum":10000000},"note":{"type":"string","minLength":1,"maxLength":500}},"required":["points","note"]}}}},"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"member":{"properties":{"balance":{"type":"integer"},"cardUrl":{"format":"uri","type":"string"},"contactId":{"format":"uuid","type":"string"},"createdAt":{"format":"date-time","type":"string"},"currency":{"type":"string"},"id":{"format":"uuid","type":"string"},"lastActivityAt":{"format":"date-time","type":"string"},"lifetimePoints":{"type":"integer"},"nextTier":{"properties":{"name":{"type":"string"},"pointsToGo":{"type":"integer"}},"required":["name","pointsToGo"],"type":"object"},"purchases":{"type":"integer"},"spent":{"type":"integer"},"tier":{"type":"null"}},"required":["id","contactId","balance","lifetimePoints","purchases","spent","currency","tier","nextTier","cardUrl","lastActivityAt","createdAt"],"type":"object"},"program":{"properties":{"active":{"type":"boolean"},"autoEnroll":{"type":"boolean"},"currency":{"type":"string"},"eventRules":{"type":"array"},"expirationMonths":{"type":"null"},"minPurchaseAmount":{"type":"integer"},"name":{"type":"string"},"organizationId":{"format":"uuid","type":"string"},"pointsLabel":{"type":"string"},"pointsPerPurchase":{"type":"integer"},"pointsPerUnit":{"type":"integer"},"selfRedeem":{"type":"boolean"},"sources":{"properties":{"invoices":{"type":"boolean"},"manualPayments":{"type":"boolean"},"payments":{"type":"boolean"}},"required":["invoices","payments","manualPayments"],"type":"object"},"terms":{"type":"string"},"tiers":{"items":{"properties":{"minPoints":{"type":"integer"},"multiplierPercent":{"type":"integer"},"name":{"type":"string"}},"required":["name","minPoints","multiplierPercent"],"type":"object"},"type":"array"},"unitAmount":{"type":"integer"},"updatedAt":{"format":"date-time","type":"string"},"welcomePoints":{"type":"integer"}},"required":["organizationId","active","name","pointsLabel","currency","pointsPerPurchase","pointsPerUnit","unitAmount","minPurchaseAmount","welcomePoints","expirationMonths","tiers","eventRules","sources","autoEnroll","selfRedeem","terms","updatedAt"],"type":"object"},"redemptions":{"type":"array"},"transactions":{"items":{"properties":{"amount":{"type":"null"},"createdAt":{"format":"date-time","type":"string"},"createdBy":{"format":"uuid","type":"string"},"currency":{"type":"null"},"id":{"format":"uuid","type":"string"},"kind":{"type":"string"},"memberId":{"format":"uuid","type":"string"},"note":{"type":["null","string"]},"organizationId":{"format":"uuid","type":"string"},"points":{"type":"integer"},"reversedAt":{"type":"null"},"source":{"type":"string"},"sourceKey":{"type":["null","string"]}},"required":["id","organizationId","memberId","kind","points","source","sourceKey","amount","currency","note","reversedAt","createdBy","createdAt"],"type":"object"},"type":"array"}},"required":["program","member","transactions","redemptions"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/loyalty/contacts/{contactId}/enroll":{"post":{"operationId":"POST /v1/loyalty/contacts/{contactId}/enroll","summary":"Makes a contact a member, with the welcome points.","tags":["loyalty"],"x-feature":"loyalty","x-action":"create","parameters":[{"name":"contactId","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/loyalty/contacts/{contactId}/send":{"post":{"operationId":"POST /v1/loyalty/contacts/{contactId}/send","summary":"Emails a contact the link to their card.","tags":["loyalty"],"x-feature":"loyalty","x-action":"update","parameters":[{"name":"contactId","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"email":{"type":"string","maxLength":320,"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,}$"}}}}}},"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/loyalty/members":{"get":{"operationId":"GET /v1/loyalty/members","summary":"Lists the members with their balance and tier.","tags":["loyalty"],"x-feature":"loyalty","x-action":"read","parameters":[{"name":"q","in":"query","required":false,"schema":{"type":"string","maxLength":100}},{"name":"page","in":"query","required":false,"schema":{"default":1,"type":"integer","minimum":1,"maximum":9007199254740991}},{"name":"pageSize","in":"query","required":false,"schema":{"default":25,"type":"integer","minimum":1,"maximum":100}},{"name":"sort","in":"query","required":false,"schema":{"default":"balance","type":"string","enum":["balance","lifetimePoints","lastActivityAt","createdAt"]}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"data":{"type":"array"},"page":{"type":"integer"},"pageSize":{"type":"integer"},"total":{"type":"integer"}},"required":["data","page","pageSize","total"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/loyalty/overview":{"get":{"operationId":"GET /v1/loyalty/overview","summary":"The program’s numbers: members, points given and spent, redemptions.","tags":["loyalty"],"x-feature":"loyalty","x-action":"read","responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"last30":{"properties":{"earned":{"type":"integer"},"expired":{"type":"integer"},"redeemed":{"type":"integer"}},"required":["earned","redeemed","expired"],"type":"object"},"members":{"type":"integer"},"outstanding":{"type":"integer"},"pendingRedemptions":{"type":"integer"},"program":{"properties":{"active":{"type":"boolean"},"autoEnroll":{"type":"boolean"},"currency":{"type":"string"},"eventRules":{"type":"array"},"expirationMonths":{"type":"null"},"minPurchaseAmount":{"type":"integer"},"name":{"type":"string"},"organizationId":{"format":"uuid","type":"string"},"pointsLabel":{"type":"string"},"pointsPerPurchase":{"type":"integer"},"pointsPerUnit":{"type":"integer"},"selfRedeem":{"type":"boolean"},"sources":{"properties":{"invoices":{"type":"boolean"},"manualPayments":{"type":"boolean"},"payments":{"type":"boolean"}},"required":["invoices","payments","manualPayments"],"type":"object"},"terms":{"type":"string"},"tiers":{"items":{"properties":{"minPoints":{"type":"integer"},"multiplierPercent":{"type":"integer"},"name":{"type":"string"}},"required":["name","minPoints","multiplierPercent"],"type":"object"},"type":"array"},"unitAmount":{"type":"integer"},"updatedAt":{"format":"date-time","type":"string"},"welcomePoints":{"type":"integer"}},"required":["organizationId","active","name","pointsLabel","currency","pointsPerPurchase","pointsPerUnit","unitAmount","minPurchaseAmount","welcomePoints","expirationMonths","tiers","eventRules","sources","autoEnroll","selfRedeem","terms","updatedAt"],"type":"object"},"spent":{"type":"integer"},"topRewards":{"items":{"properties":{"name":{"type":"string"},"rewardId":{"format":"uuid","type":"string"},"total":{"type":"integer"}},"required":["rewardId","name","total"],"type":"object"},"type":"array"}},"required":["program","members","outstanding","spent","last30","pendingRedemptions","topRewards"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/loyalty/program":{"get":{"operationId":"GET /v1/loyalty/program","summary":"The program’s rules: how purchases earn, tiers and expiration.","tags":["loyalty"],"x-feature":"loyalty","x-action":"read","responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"active":{"type":"boolean"},"autoEnroll":{"type":"boolean"},"currency":{"type":"string"},"eventRules":{"type":"array"},"expirationMonths":{"type":"null"},"minPurchaseAmount":{"type":"integer"},"name":{"type":"null"},"organizationId":{"format":"uuid","type":"string"},"pointsLabel":{"type":"null"},"pointsPerPurchase":{"type":"integer"},"pointsPerUnit":{"type":"integer"},"selfRedeem":{"type":"boolean"},"sources":{"properties":{"invoices":{"type":"boolean"},"manualPayments":{"type":"boolean"},"payments":{"type":"boolean"}},"required":["payments","invoices","manualPayments"],"type":"object"},"terms":{"type":"null"},"tiers":{"type":"array"},"unitAmount":{"type":"integer"},"updatedAt":{"format":"date-time","type":"string"},"welcomePoints":{"type":"integer"}},"required":["active","name","pointsLabel","currency","pointsPerPurchase","pointsPerUnit","unitAmount","minPurchaseAmount","welcomePoints","expirationMonths","tiers","eventRules","sources","autoEnroll","selfRedeem","terms","organizationId","updatedAt"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"put":{"operationId":"PUT /v1/loyalty/program","summary":"Saves the program’s rules (administrators).","tags":["loyalty"],"x-feature":"loyalty","x-action":"update","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"active":{"type":"boolean"},"name":{"anyOf":[{"type":"string","maxLength":80},{"type":"null"}]},"pointsLabel":{"anyOf":[{"type":"string","maxLength":30},{"type":"null"}]},"currency":{"type":"string","pattern":"^[A-Z]{3}$"},"pointsPerPurchase":{"type":"integer","minimum":0,"maximum":1000000},"pointsPerUnit":{"type":"integer","minimum":0,"maximum":1000000},"unitAmount":{"type":"integer","minimum":1,"maximum":1000000000000},"minPurchaseAmount":{"type":"integer","minimum":0,"maximum":1000000000000},"welcomePoints":{"type":"integer","minimum":0,"maximum":1000000},"expirationMonths":{"anyOf":[{"type":"integer","minimum":1,"maximum":60},{"type":"null"}]},"tiers":{"maxItems":5,"type":"array","items":{"type":"object","properties":{"name":{"type":"string","minLength":1,"maxLength":40},"minPoints":{"type":"integer","minimum":0,"maximum":1000000000},"multiplierPercent":{"default":100,"type":"integer","minimum":100,"maximum":1000}},"required":["name","minPoints"]}},"eventRules":{"maxItems":10,"type":"array","items":{"type":"object","properties":{"event":{"type":"string"},"points":{"type":"integer","minimum":1,"maximum":1000000},"perDay":{"default":null,"anyOf":[{"type":"integer","minimum":1,"maximum":100},{"type":"null"}]}},"required":["event","points"]}},"sources":{"type":"object","properties":{"payments":{"type":"boolean"},"invoices":{"type":"boolean"},"manualPayments":{"type":"boolean"}},"required":["payments","invoices","manualPayments"]},"autoEnroll":{"type":"boolean"},"selfRedeem":{"type":"boolean"},"terms":{"anyOf":[{"type":"string","maxLength":4000},{"type":"null"}]}},"required":["active","currency","pointsPerPurchase","pointsPerUnit","unitAmount","minPurchaseAmount","welcomePoints","expirationMonths","tiers","sources","autoEnroll","selfRedeem"]}}}},"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"active":{"type":"boolean"},"autoEnroll":{"type":"boolean"},"currency":{"type":"string"},"eventRules":{"items":{"properties":{"event":{"type":"string"},"perDay":{"type":"integer"},"points":{"type":"integer"}},"required":["event","perDay","points"],"type":"object"},"type":"array"},"expirationMonths":{"type":"null"},"minPurchaseAmount":{"type":"integer"},"name":{"type":["null","string"]},"organizationId":{"format":"uuid","type":"string"},"pointsLabel":{"type":["null","string"]},"pointsPerPurchase":{"type":"integer"},"pointsPerUnit":{"type":"integer"},"selfRedeem":{"type":"boolean"},"sources":{"properties":{"invoices":{"type":"boolean"},"manualPayments":{"type":"boolean"},"payments":{"type":"boolean"}},"required":["invoices","manualPayments","payments"],"type":"object"},"terms":{"type":["null","string"]},"tiers":{"items":{"properties":{"minPoints":{"type":"integer"},"multiplierPercent":{"type":"integer"},"name":{"type":"string"}},"required":["name","minPoints","multiplierPercent"],"type":"object"},"type":"array"},"unitAmount":{"type":"integer"},"updatedAt":{"format":"date-time","type":"string"},"welcomePoints":{"type":"integer"}},"required":["active","autoEnroll","currency","eventRules","expirationMonths","minPurchaseAmount","name","organizationId","pointsLabel","pointsPerPurchase","pointsPerUnit","selfRedeem","sources","terms","tiers","unitAmount","updatedAt","welcomePoints"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/loyalty/redemptions":{"get":{"operationId":"GET /v1/loyalty/redemptions","summary":"Lists the rewards taken, by status.","tags":["loyalty"],"x-feature":"loyalty","x-action":"read","parameters":[{"name":"status","in":"query","required":false,"schema":{"type":"string","enum":["pending","fulfilled","canceled"]}},{"name":"code","in":"query","required":false,"schema":{"type":"string","maxLength":20}},{"name":"contactId","in":"query","required":false,"schema":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"}},{"name":"page","in":"query","required":false,"schema":{"default":1,"type":"integer","minimum":1,"maximum":9007199254740991}},{"name":"pageSize","in":"query","required":false,"schema":{"default":25,"type":"integer","minimum":1,"maximum":100}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"data":{"items":{"properties":{"canceledAt":{"type":"null"},"code":{"type":"string"},"contactId":{"format":"uuid","type":"string"},"createdAt":{"format":"date-time","type":"string"},"createdBy":{"type":"null"},"fulfilledAt":{"type":"null"},"fulfilledBy":{"type":"null"},"id":{"format":"uuid","type":"string"},"memberId":{"format":"uuid","type":"string"},"name":{"type":"string"},"organizationId":{"format":"uuid","type":"string"},"points":{"type":"integer"},"reward":{"properties":{"currency":{"type":"string"},"kind":{"type":"string"},"name":{"type":"string"},"value":{"type":"null"}},"required":["kind","name","value","currency"],"type":"object"},"rewardId":{"format":"uuid","type":"string"},"source":{"type":"string"},"status":{"type":"string"}},"required":["id","organizationId","memberId","rewardId","reward","points","code","status","source","createdBy","fulfilledAt","fulfilledBy","canceledAt","createdAt","contactId","name"],"type":"object"},"type":"array"},"page":{"type":"integer"},"pageSize":{"type":"integer"},"total":{"type":"integer"}},"required":["data","page","pageSize","total"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"post":{"operationId":"POST /v1/loyalty/redemptions","summary":"Takes a reward for a contact, spending their points.","tags":["loyalty"],"x-feature":"loyalty","x-action":"create","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"contactId":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},"rewardId":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"}},"required":["contactId","rewardId"]}}}},"responses":{"201":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"canceledAt":{"type":"null"},"code":{"type":"string"},"createdAt":{"format":"date-time","type":"string"},"createdBy":{"format":"uuid","type":"string"},"fulfilledAt":{"type":"null"},"fulfilledBy":{"type":"null"},"id":{"format":"uuid","type":"string"},"memberId":{"format":"uuid","type":"string"},"organizationId":{"format":"uuid","type":"string"},"points":{"type":"integer"},"reward":{"properties":{"currency":{"type":"string"},"kind":{"type":"string"},"name":{"type":"string"},"value":{"type":"null"}},"required":["kind","name","value","currency"],"type":"object"},"rewardId":{"format":"uuid","type":"string"},"source":{"type":"string"},"status":{"type":"string"}},"required":["id","organizationId","memberId","rewardId","reward","points","code","status","source","createdBy","fulfilledAt","fulfilledBy","canceledAt","createdAt"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/loyalty/redemptions/{id}/cancel":{"post":{"operationId":"POST /v1/loyalty/redemptions/{id}/cancel","summary":"Cancels a reward not handed over; the points go back.","tags":["loyalty"],"x-feature":"loyalty","x-action":"update","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"canceledAt":{"format":"date-time","type":"string"},"code":{"type":"string"},"createdAt":{"format":"date-time","type":"string"},"createdBy":{"type":"null"},"fulfilledAt":{"type":"null"},"fulfilledBy":{"type":"null"},"id":{"format":"uuid","type":"string"},"memberId":{"format":"uuid","type":"string"},"organizationId":{"format":"uuid","type":"string"},"points":{"type":"integer"},"reward":{"properties":{"currency":{"type":"string"},"kind":{"type":"string"},"name":{"type":"string"},"value":{"type":"null"}},"required":["kind","name","value","currency"],"type":"object"},"rewardId":{"format":"uuid","type":"string"},"source":{"type":"string"},"status":{"type":"string"}},"required":["id","organizationId","memberId","rewardId","reward","points","code","status","source","createdBy","fulfilledAt","fulfilledBy","canceledAt","createdAt"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/loyalty/redemptions/{id}/fulfill":{"post":{"operationId":"POST /v1/loyalty/redemptions/{id}/fulfill","summary":"Marks a reward as handed over.","tags":["loyalty"],"x-feature":"loyalty","x-action":"update","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"canceledAt":{"type":"null"},"code":{"type":"string"},"createdAt":{"format":"date-time","type":"string"},"createdBy":{"format":"uuid","type":"string"},"fulfilledAt":{"format":"date-time","type":"string"},"fulfilledBy":{"format":"uuid","type":"string"},"id":{"format":"uuid","type":"string"},"memberId":{"format":"uuid","type":"string"},"organizationId":{"format":"uuid","type":"string"},"points":{"type":"integer"},"reward":{"properties":{"currency":{"type":"string"},"kind":{"type":"string"},"name":{"type":"string"},"value":{"type":"null"}},"required":["kind","name","value","currency"],"type":"object"},"rewardId":{"format":"uuid","type":"string"},"source":{"type":"string"},"status":{"type":"string"}},"required":["id","organizationId","memberId","rewardId","reward","points","code","status","source","createdBy","fulfilledAt","fulfilledBy","canceledAt","createdAt"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/loyalty/rewards":{"get":{"operationId":"GET /v1/loyalty/rewards","summary":"Lists the rewards members can take.","tags":["loyalty"],"x-feature":"loyalty","x-action":"read","responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"items":{"properties":{"active":{"type":"boolean"},"cost":{"type":"integer"},"createdAt":{"format":"date-time","type":"string"},"description":{"type":"null"},"id":{"format":"uuid","type":"string"},"kind":{"type":"string"},"minTier":{"type":"null"},"name":{"type":"string"},"organizationId":{"format":"uuid","type":"string"},"perMember":{"type":["integer","null"]},"position":{"type":"integer"},"stock":{"type":["integer","null"]},"updatedAt":{"format":"date-time","type":"string"},"value":{"type":["integer","null"]}},"required":["id","organizationId","name","description","kind","value","cost","stock","perMember","minTier","active","position","createdAt","updatedAt"],"type":"object"},"type":"array"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"post":{"operationId":"POST /v1/loyalty/rewards","summary":"Creates a reward: an item, a discount or cashback, and its points.","tags":["loyalty"],"x-feature":"loyalty","x-action":"create","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"name":{"type":"string","minLength":1,"maxLength":120},"description":{"anyOf":[{"type":"string","maxLength":1000},{"type":"null"}]},"kind":{"type":"string","enum":["item","discount_percent","discount_amount","cashback"]},"value":{"anyOf":[{"type":"integer","minimum":1,"maximum":10000000000},{"type":"null"}]},"cost":{"type":"integer","minimum":1,"maximum":1000000000},"stock":{"anyOf":[{"type":"integer","minimum":0,"maximum":10000000},{"type":"null"}]},"perMember":{"anyOf":[{"type":"integer","minimum":1,"maximum":1000},{"type":"null"}]},"minTier":{"anyOf":[{"type":"integer","minimum":0,"maximum":4},{"type":"null"}]},"active":{"default":true,"type":"boolean"},"position":{"default":0,"type":"integer","minimum":0,"maximum":1000}},"required":["name","kind","cost"]}}}},"responses":{"201":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"active":{"type":"boolean"},"cost":{"type":"integer"},"createdAt":{"format":"date-time","type":"string"},"description":{"type":"null"},"id":{"format":"uuid","type":"string"},"kind":{"type":"string"},"minTier":{"type":"null"},"name":{"type":"string"},"organizationId":{"format":"uuid","type":"string"},"perMember":{"type":["integer","null"]},"position":{"type":"integer"},"stock":{"type":["integer","null"]},"updatedAt":{"format":"date-time","type":"string"},"value":{"type":["integer","null"]}},"required":["id","organizationId","name","description","kind","value","cost","stock","perMember","minTier","active","position","createdAt","updatedAt"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/loyalty/rewards/{id}":{"delete":{"operationId":"DELETE /v1/loyalty/rewards/{id}","summary":"Deletes a reward; rewards already taken stay.","tags":["loyalty"],"x-feature":"loyalty","x-action":"delete","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"204":{"description":"Done, with no content."},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"put":{"operationId":"PUT /v1/loyalty/rewards/{id}","summary":"Changes a reward.","tags":["loyalty"],"x-feature":"loyalty","x-action":"update","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"name":{"type":"string","minLength":1,"maxLength":120},"description":{"anyOf":[{"type":"string","maxLength":1000},{"type":"null"}]},"kind":{"type":"string","enum":["item","discount_percent","discount_amount","cashback"]},"value":{"anyOf":[{"type":"integer","minimum":1,"maximum":10000000000},{"type":"null"}]},"cost":{"type":"integer","minimum":1,"maximum":1000000000},"stock":{"anyOf":[{"type":"integer","minimum":0,"maximum":10000000},{"type":"null"}]},"perMember":{"anyOf":[{"type":"integer","minimum":1,"maximum":1000},{"type":"null"}]},"minTier":{"anyOf":[{"type":"integer","minimum":0,"maximum":4},{"type":"null"}]},"active":{"default":true,"type":"boolean"},"position":{"default":0,"type":"integer","minimum":0,"maximum":1000}},"required":["name","kind","cost"]}}}},"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/manual-payments":{"post":{"operationId":"POST /v1/manual-payments","summary":"Records a sale made outside Firmado; a repeated `reference` is kept once.","tags":["payments"],"x-feature":"payments","x-action":"create","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"contactId":{"anyOf":[{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},{"type":"null"}]},"companyId":{"anyOf":[{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},{"type":"null"}]},"description":{"anyOf":[{"type":"string","maxLength":1000},{"type":"null"}]},"items":{"maxItems":200,"type":"array","items":{"type":"object","properties":{"id":{"type":"string","minLength":1,"maxLength":64},"serviceId":{"anyOf":[{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},{"type":"null"}]},"name":{"type":"string","minLength":1,"maxLength":200},"description":{"anyOf":[{"type":"string","maxLength":2000},{"type":"null"}]},"quantity":{"default":1,"type":"number","exclusiveMinimum":0,"maximum":100000},"unitPrice":{"type":"integer","minimum":0,"maximum":10000000000000},"discount":{"anyOf":[{"oneOf":[{"type":"object","properties":{"type":{"type":"string","const":"percent"},"value":{"type":"number","exclusiveMinimum":0,"maximum":100,"multipleOf":0.01}},"required":["type","value"]},{"type":"object","properties":{"type":{"type":"string","const":"amount"},"value":{"type":"integer","exclusiveMinimum":0,"maximum":10000000000000}},"required":["type","value"]}]},{"type":"null"}]}},"required":["name","unitPrice"]}},"amount":{"anyOf":[{"type":"integer","exclusiveMinimum":0,"maximum":10000000000000},{"type":"null"}]},"currency":{"type":"string","pattern":"^[A-Z]{3}$"},"status":{"default":"paid","type":"string","enum":["paid","processing","refunded"]},"paidAt":{"type":"string","format":"date-time"},"method":{"anyOf":[{"type":"string","maxLength":60},{"type":"null"}]},"payerName":{"anyOf":[{"type":"string","maxLength":200},{"type":"null"}]},"payerEmail":{"anyOf":[{"anyOf":[{"type":"string","maxLength":320,"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,}$"},{"type":"null"}]},{"type":"string","const":""}]},"channel":{"anyOf":[{"type":"string","maxLength":60},{"type":"null"}]},"reference":{"type":"string","minLength":1,"maxLength":120,"pattern":"^[\\w.:-]+$"},"createContact":{"default":true,"type":"boolean"}},"required":["currency"]}}}},"responses":{"201":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"amount":{"type":"integer"},"channel":{"type":["null","string"]},"companyId":{"format":"uuid","type":["null","string"]},"contactId":{"format":"uuid","type":["null","string"]},"createdAt":{"format":"date-time","type":"string"},"createdBy":{"format":"uuid","type":"string"},"currency":{"type":"string"},"description":{"type":["null","string"]},"id":{"format":"uuid","type":"string"},"items":{"items":{"properties":{"description":{"type":"null"},"discount":{"properties":{"type":{"type":"string"},"value":{"type":"integer"}},"required":["type","value"],"type":["null","object"]},"id":{"format":"uuid","type":"string"},"name":{"type":"string"},"quantity":{"type":"integer"},"serviceId":{"format":"uuid","type":["null","string"]},"unitPrice":{"type":"integer"}},"required":["id","name","discount","quantity","serviceId","unitPrice","description"],"type":"object"},"type":"array"},"method":{"type":["null","string"]},"organizationId":{"format":"uuid","type":"string"},"paidAt":{"format":"date-time","type":"string"},"payerEmail":{"format":"email","type":["null","string"]},"payerName":{"type":["null","string"]},"reference":{"type":["null","string"]},"status":{"type":"string"},"updatedAt":{"format":"date-time","type":"string"},"updatedBy":{"format":"uuid","type":"string"}},"required":["amount","channel","companyId","contactId","createdAt","createdBy","currency","description","id","items","method","organizationId","paidAt","payerEmail","payerName","reference","status","updatedAt","updatedBy"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/manual-payments/{id}":{"delete":{"operationId":"DELETE /v1/manual-payments/{id}","summary":"Deletes a sale made outside Firmado.","tags":["payments"],"x-feature":"payments","x-action":"delete","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"204":{"description":"Done, with no content."},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"get":{"operationId":"GET /v1/manual-payments/{id}","summary":"Returns a sale made outside Firmado.","tags":["payments"],"x-feature":"payments","x-action":"read","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"amount":{"type":"integer"},"channel":{"type":"null"},"companyId":{"type":"null"},"contactId":{"format":"uuid","type":"string"},"createdAt":{"format":"date-time","type":"string"},"createdBy":{"format":"uuid","type":"string"},"currency":{"type":"string"},"description":{"type":"string"},"id":{"format":"uuid","type":"string"},"items":{"type":"array"},"method":{"type":"null"},"organizationId":{"format":"uuid","type":"string"},"paidAt":{"format":"date-time","type":"string"},"payerEmail":{"type":"null"},"payerName":{"type":"null"},"reference":{"type":"null"},"status":{"type":"string"},"updatedAt":{"format":"date-time","type":"string"},"updatedBy":{"format":"uuid","type":"string"}},"required":["id","organizationId","contactId","companyId","description","items","amount","currency","status","paidAt","method","payerName","payerEmail","channel","reference","createdBy","updatedBy","createdAt","updatedAt"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"patch":{"operationId":"PATCH /v1/manual-payments/{id}","summary":"Changes a sale made outside Firmado.","tags":["payments"],"x-feature":"payments","x-action":"update","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"contactId":{"anyOf":[{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},{"type":"null"}]},"companyId":{"anyOf":[{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},{"type":"null"}]},"description":{"anyOf":[{"type":"string","maxLength":1000},{"type":"null"}]},"items":{"maxItems":200,"type":"array","items":{"type":"object","properties":{"id":{"type":"string","minLength":1,"maxLength":64},"serviceId":{"anyOf":[{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},{"type":"null"}]},"name":{"type":"string","minLength":1,"maxLength":200},"description":{"anyOf":[{"type":"string","maxLength":2000},{"type":"null"}]},"quantity":{"default":1,"type":"number","exclusiveMinimum":0,"maximum":100000},"unitPrice":{"type":"integer","minimum":0,"maximum":10000000000000},"discount":{"anyOf":[{"oneOf":[{"type":"object","properties":{"type":{"type":"string","const":"percent"},"value":{"type":"number","exclusiveMinimum":0,"maximum":100,"multipleOf":0.01}},"required":["type","value"]},{"type":"object","properties":{"type":{"type":"string","const":"amount"},"value":{"type":"integer","exclusiveMinimum":0,"maximum":10000000000000}},"required":["type","value"]}]},{"type":"null"}]}},"required":["name","unitPrice"]}},"amount":{"anyOf":[{"type":"integer","exclusiveMinimum":0,"maximum":10000000000000},{"type":"null"}]},"currency":{"type":"string","pattern":"^[A-Z]{3}$"},"status":{"type":"string","enum":["paid","processing","refunded"]},"paidAt":{"type":"string","format":"date-time"},"method":{"anyOf":[{"type":"string","maxLength":60},{"type":"null"}]},"payerName":{"anyOf":[{"type":"string","maxLength":200},{"type":"null"}]},"payerEmail":{"anyOf":[{"anyOf":[{"type":"string","maxLength":320,"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,}$"},{"type":"null"}]},{"type":"string","const":""}]},"channel":{"anyOf":[{"type":"string","maxLength":60},{"type":"null"}]}}}}}},"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"amount":{"type":"integer"},"channel":{"type":"null"},"companyId":{"format":"uuid","type":"string"},"contactId":{"type":"null"},"createdAt":{"format":"date-time","type":"string"},"createdBy":{"format":"uuid","type":"string"},"currency":{"type":"string"},"description":{"type":"string"},"id":{"format":"uuid","type":"string"},"items":{"items":{"properties":{"description":{"type":"null"},"discount":{"type":"null"},"id":{"format":"uuid","type":"string"},"name":{"type":"string"},"quantity":{"type":"integer"},"serviceId":{"type":"null"},"unitPrice":{"type":"integer"}},"required":["id","name","discount","quantity","serviceId","unitPrice","description"],"type":"object"},"type":"array"},"method":{"type":"null"},"organizationId":{"format":"uuid","type":"string"},"paidAt":{"format":"date-time","type":"string"},"payerEmail":{"type":"null"},"payerName":{"type":"null"},"reference":{"type":"null"},"status":{"type":"string"},"updatedAt":{"format":"date-time","type":"string"},"updatedBy":{"format":"uuid","type":"string"}},"required":["id","organizationId","contactId","companyId","description","items","amount","currency","status","paidAt","method","payerName","payerEmail","channel","reference","createdBy","updatedBy","createdAt","updatedAt"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/manual-payments/reference/{reference}":{"delete":{"operationId":"DELETE /v1/manual-payments/reference/{reference}","summary":"Takes back a sale by its reference (returned, canceled).","tags":["payments"],"x-feature":"payments","x-action":"delete","parameters":[{"name":"reference","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"204":{"description":"Done, with no content."},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"get":{"operationId":"GET /v1/manual-payments/reference/{reference}","summary":"Finds a sale by the sender’s own reference.","tags":["payments"],"x-feature":"payments","x-action":"read","parameters":[{"name":"reference","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"amount":{"type":"integer"},"channel":{"type":"string"},"companyId":{"type":"null"},"contactId":{"format":"uuid","type":"string"},"createdAt":{"format":"date-time","type":"string"},"createdBy":{"format":"uuid","type":"string"},"currency":{"type":"string"},"description":{"type":"string"},"id":{"format":"uuid","type":"string"},"items":{"type":"array"},"method":{"type":"null"},"organizationId":{"format":"uuid","type":"string"},"paidAt":{"format":"date-time","type":"string"},"payerEmail":{"format":"email","type":"string"},"payerName":{"type":"string"},"reference":{"type":"string"},"status":{"type":"string"},"updatedAt":{"format":"date-time","type":"string"},"updatedBy":{"format":"uuid","type":"string"}},"required":["id","organizationId","contactId","companyId","description","items","amount","currency","status","paidAt","method","payerName","payerEmail","channel","reference","createdBy","updatedBy","createdAt","updatedAt"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/marketing/posts":{"get":{"operationId":"GET /v1/marketing/posts","summary":"Lists the comment automations.","tags":["postAutomations"],"x-feature":"postAutomations","x-action":"read","responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"connections":{"items":{"properties":{"channel":{"type":"string"},"enabled":{"type":"boolean"},"id":{"format":"uuid","type":"string"},"label":{"type":"string"}},"required":["channel","enabled","id","label"],"type":"object"},"type":"array"},"data":{"items":{"properties":{"connectionId":{"format":"uuid","type":"string"},"createContacts":{"type":"boolean"},"createdAt":{"format":"date-time","type":"string"},"enabled":{"type":"boolean"},"endsAt":{"format":"date-time","type":"string"},"engagement":{"properties":{"error":{"type":"null"},"fetchedAt":{"format":"date-time","type":["null","string"]},"metrics":{"properties":{"comments":{"type":"integer"},"reactions":{"type":"integer"},"shares":{"type":"integer"}},"required":["comments","reactions"],"type":["null","object"]},"nextFetchAt":{"format":"date-time","type":"string"}},"required":["error","fetchedAt","metrics","nextFetchAt"],"type":"object"},"id":{"format":"uuid","type":"string"},"includeExisting":{"type":"boolean"},"keywords":{"items":{"type":"string"},"type":"array"},"like":{"type":"boolean"},"nextScanAt":{"format":"date-time","type":"string"},"oncePerUser":{"type":"boolean"},"organizationId":{"format":"uuid","type":"string"},"permalink":{"format":"uri","type":"string"},"planBlocked":{"type":"boolean"},"postId":{"type":"string"},"privateReply":{"type":"string"},"publicReply":{"type":["null","string"]},"scanAfter":{"type":"null"},"scanError":{"type":"null"},"startsAt":{"format":"date-time","type":"string"},"title":{"type":"string"}},"required":["connectionId","createContacts","createdAt","enabled","endsAt","engagement","id","includeExisting","keywords","like","nextScanAt","oncePerUser","organizationId","permalink","planBlocked","postId","privateReply","publicReply","scanAfter","scanError","startsAt","title"],"type":"object"},"type":"array"},"limit":{"type":"integer"}},"required":["connections","data","limit"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"post":{"operationId":"POST /v1/marketing/posts","summary":"Starts a comment automation on a post: what triggers it and what it replies.","tags":["postAutomations"],"x-feature":"postAutomations","x-action":"create","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"enabled":{"default":true,"type":"boolean"},"startsAt":{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z))$"},"endsAt":{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z))$"},"like":{"default":false,"type":"boolean"},"publicReply":{"default":null,"anyOf":[{"type":"string","maxLength":1000},{"type":"null"}]},"privateReply":{"default":null,"anyOf":[{"type":"string","maxLength":1000},{"type":"null"}]},"keywords":{"default":[],"maxItems":30,"type":"array","items":{"type":"string","minLength":1,"maxLength":80}},"createContacts":{"default":false,"type":"boolean"},"includeExisting":{"default":false,"type":"boolean"},"oncePerUser":{"default":true,"type":"boolean"},"connectionId":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},"postId":{"type":"string","pattern":"^[\\d_]{1,150}$"}},"required":["startsAt","endsAt","connectionId","postId"]}}}},"responses":{"201":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"connections":{"items":{"properties":{"channel":{"type":"string"},"enabled":{"type":"boolean"},"id":{"format":"uuid","type":"string"},"label":{"type":"string"}},"required":["channel","enabled","id","label"],"type":"object"},"type":"array"},"data":{"items":{"properties":{"connectionId":{"format":"uuid","type":"string"},"createContacts":{"type":"boolean"},"createdAt":{"format":"date-time","type":"string"},"enabled":{"type":"boolean"},"endsAt":{"format":"date-time","type":"string"},"engagement":{"properties":{"error":{"type":"null"},"fetchedAt":{"type":"null"},"metrics":{"type":"null"},"nextFetchAt":{"format":"date-time","type":"string"}},"required":["error","fetchedAt","metrics","nextFetchAt"],"type":"object"},"id":{"format":"uuid","type":"string"},"includeExisting":{"type":"boolean"},"keywords":{"items":{"type":"string"},"type":"array"},"like":{"type":"boolean"},"nextScanAt":{"format":"date-time","type":"string"},"oncePerUser":{"type":"boolean"},"organizationId":{"format":"uuid","type":"string"},"permalink":{"format":"uri","type":["null","string"]},"planBlocked":{"type":"boolean"},"postId":{"type":"string"},"privateReply":{"type":["null","string"]},"publicReply":{"type":"string"},"scanAfter":{"type":"null"},"scanError":{"type":"null"},"startsAt":{"format":"date-time","type":"string"},"title":{"type":"string"}},"required":["connectionId","createContacts","createdAt","enabled","endsAt","engagement","id","includeExisting","keywords","like","nextScanAt","oncePerUser","organizationId","permalink","planBlocked","postId","privateReply","publicReply","scanAfter","scanError","startsAt","title"],"type":"object"},"type":"array"},"limit":{"type":"integer"}},"required":["connections","data","limit"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/marketing/posts/{id}":{"delete":{"operationId":"DELETE /v1/marketing/posts/{id}","summary":"Deletes a comment automation.","tags":["postAutomations"],"x-feature":"postAutomations","x-action":"delete","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"connections":{"items":{"properties":{"channel":{"type":"string"},"enabled":{"type":"boolean"},"id":{"format":"uuid","type":"string"},"label":{"type":"string"}},"required":["id","channel","label","enabled"],"type":"object"},"type":"array"},"data":{"items":{"properties":{"connectionId":{"format":"uuid","type":"string"},"createContacts":{"type":"boolean"},"createdAt":{"format":"date-time","type":"string"},"enabled":{"type":"boolean"},"endsAt":{"format":"date-time","type":"string"},"engagement":{"properties":{"error":{"type":"null"},"fetchedAt":{"type":"null"},"metrics":{"type":"null"},"nextFetchAt":{"format":"date-time","type":"string"}},"required":["metrics","fetchedAt","nextFetchAt","error"],"type":"object"},"id":{"format":"uuid","type":"string"},"includeExisting":{"type":"boolean"},"keywords":{"type":"array"},"like":{"type":"boolean"},"nextScanAt":{"format":"date-time","type":"string"},"oncePerUser":{"type":"boolean"},"organizationId":{"format":"uuid","type":"string"},"permalink":{"format":"uri","type":"string"},"planBlocked":{"type":"boolean"},"postId":{"type":"string"},"privateReply":{"type":"string"},"publicReply":{"type":"string"},"scanAfter":{"type":"null"},"scanError":{"type":"null"},"startsAt":{"format":"date-time","type":"string"},"title":{"type":"string"}},"required":["id","organizationId","connectionId","postId","title","permalink","enabled","startsAt","endsAt","like","publicReply","privateReply","keywords","createContacts","includeExisting","oncePerUser","scanAfter","nextScanAt","scanError","createdAt","planBlocked","engagement"],"type":"object"},"type":"array"},"limit":{"type":"integer"}},"required":["limit","data","connections"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"put":{"operationId":"PUT /v1/marketing/posts/{id}","summary":"Changes a comment automation, or pauses it.","tags":["postAutomations"],"x-feature":"postAutomations","x-action":"update","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"enabled":{"default":true,"type":"boolean"},"startsAt":{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z))$"},"endsAt":{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z))$"},"like":{"default":false,"type":"boolean"},"publicReply":{"default":null,"anyOf":[{"type":"string","maxLength":1000},{"type":"null"}]},"privateReply":{"default":null,"anyOf":[{"type":"string","maxLength":1000},{"type":"null"}]},"keywords":{"default":[],"maxItems":30,"type":"array","items":{"type":"string","minLength":1,"maxLength":80}},"createContacts":{"default":false,"type":"boolean"},"includeExisting":{"default":false,"type":"boolean"},"oncePerUser":{"default":true,"type":"boolean"}},"required":["startsAt","endsAt"]}}}},"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/marketing/posts/{id}/logs":{"get":{"operationId":"GET /v1/marketing/posts/{id}/logs","summary":"What a comment automation did: comments seen, replies and messages sent.","tags":["postAutomations"],"x-feature":"postAutomations","x-action":"read","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/marketing/posts/accounts/{id}/posts":{"get":{"operationId":"GET /v1/marketing/posts/accounts/{id}/posts","summary":"A connected account’s recent posts, to pick one for an automation.","tags":["postAutomations"],"x-feature":"postAutomations","x-action":"read","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"data":{"items":{"properties":{"id":{"type":"string"},"permalink":{"format":"uri","type":"string"},"title":{"type":"string"}},"required":["id","title","permalink"],"type":"object"},"type":"array"},"next":{"type":"null"}},"required":["data","next"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/microsites":{"get":{"operationId":"GET /v1/microsites","summary":"Lists the microsites (one per organization at most).","tags":["microsites"],"x-feature":"microsites","x-action":"read","responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"post":{"operationId":"POST /v1/microsites","summary":"Creates the microsite (Pro, one per organization).","tags":["microsites"],"x-feature":"microsites","x-action":"create","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"name":{"type":"string","minLength":1,"maxLength":120},"slug":{"type":"string","pattern":"^[a-z0-9](?:[a-z0-9-]{1,38}[a-z0-9])$"},"title":{"type":"string","minLength":1,"maxLength":120},"description":{"anyOf":[{"type":"string","maxLength":300},{"type":"null"}]},"document":{"default":{"version":1,"settings":{"backdropColor":"#ffffff","contentColor":"#ffffff","width":720,"fontFamily":"Arial","headingFontFamily":"Arial","fontSize":16,"lineHeight":1.5,"textColor":"#1f2937","headingColor":"#111827","linkColor":"#2563eb","primaryColor":"#2563eb","onPrimaryColor":"#ffffff","radius":0,"outerPadding":0,"backdropImage":"","contentImage":"","backdropImageStyle":{"size":"cover","sizeValue":100,"x":50,"y":50,"repeat":"no-repeat","gapX":0,"gapY":0,"attachment":"scroll","blend":"normal"},"contentImageStyle":{"size":"cover","sizeValue":100,"x":50,"y":50,"repeat":"no-repeat","gapX":0,"gapY":0,"attachment":"scroll","blend":"normal"},"contentCorners":null},"hero":null,"rows":[]},"type":"object","properties":{"version":{"default":1,"type":"number","const":1},"settings":{"default":{"backdropColor":"#ffffff","contentColor":"#ffffff","width":720,"fontFamily":"Arial","headingFontFamily":"Arial","fontSize":16,"lineHeight":1.5,"textColor":"#1f2937","headingColor":"#111827","linkColor":"#2563eb","primaryColor":"#2563eb","onPrimaryColor":"#ffffff","radius":0,"outerPadding":0,"backdropImage":"","contentImage":"","backdropImageStyle":{"size":"cover","sizeValue":100,"x":50,"y":50,"repeat":"no-repeat","gapX":0,"gapY":0,"attachment":"scroll","blend":"normal"},"contentImageStyle":{"size":"cover","sizeValue":100,"x":50,"y":50,"repeat":"no-repeat","gapX":0,"gapY":0,"attachment":"scroll","blend":"normal"},"contentCorners":null},"type":"object","properties":{"backdropColor":{"default":"#ffffff","type":"string","maxLength":400},"contentColor":{"default":"#ffffff","type":"string","maxLength":400},"width":{"default":720,"type":"integer","minimum":320,"maximum":1200},"fontFamily":{"default":"Arial","type":"string","maxLength":60},"headingFontFamily":{"default":"Arial","type":"string","maxLength":60},"fontSize":{"default":16,"type":"integer","minimum":0,"maximum":40},"lineHeight":{"default":1.5,"type":"number","minimum":0.8,"maximum":3},"textColor":{"default":"#1f2937","type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"headingColor":{"default":"#111827","type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"linkColor":{"default":"#2563eb","type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"primaryColor":{"default":"#2563eb","type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"onPrimaryColor":{"default":"#ffffff","type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"radius":{"default":0,"type":"integer","minimum":0,"maximum":40},"outerPadding":{"default":0,"type":"integer","minimum":0,"maximum":120},"backdropImage":{"default":"","type":"string","maxLength":2000},"contentImage":{"default":"","type":"string","maxLength":2000},"backdropImageStyle":{"default":{"size":"cover","sizeValue":100,"x":50,"y":50,"repeat":"no-repeat","gapX":0,"gapY":0,"attachment":"scroll","blend":"normal"},"type":"object","properties":{"size":{"default":"cover","type":"string","enum":["cover","contain","auto","custom"]},"sizeValue":{"default":100,"type":"integer","minimum":1,"maximum":400},"x":{"default":50,"type":"integer","minimum":0,"maximum":100},"y":{"default":50,"type":"integer","minimum":0,"maximum":100},"repeat":{"default":"no-repeat","type":"string","enum":["no-repeat","repeat","repeat-x","repeat-y","space","round"]},"gapX":{"default":0,"type":"integer","minimum":0,"maximum":400},"gapY":{"default":0,"type":"integer","minimum":0,"maximum":400},"attachment":{"default":"scroll","type":"string","enum":["scroll","fixed"]},"blend":{"default":"normal","type":"string","enum":["normal","multiply","screen","overlay","darken","lighten","color-dodge","color-burn","soft-light","hard-light","difference","luminosity"]}}},"contentImageStyle":{"default":{"size":"cover","sizeValue":100,"x":50,"y":50,"repeat":"no-repeat","gapX":0,"gapY":0,"attachment":"scroll","blend":"normal"},"type":"object","properties":{"size":{"default":"cover","type":"string","enum":["cover","contain","auto","custom"]},"sizeValue":{"default":100,"type":"integer","minimum":1,"maximum":400},"x":{"default":50,"type":"integer","minimum":0,"maximum":100},"y":{"default":50,"type":"integer","minimum":0,"maximum":100},"repeat":{"default":"no-repeat","type":"string","enum":["no-repeat","repeat","repeat-x","repeat-y","space","round"]},"gapX":{"default":0,"type":"integer","minimum":0,"maximum":400},"gapY":{"default":0,"type":"integer","minimum":0,"maximum":400},"attachment":{"default":"scroll","type":"string","enum":["scroll","fixed"]},"blend":{"default":"normal","type":"string","enum":["normal","multiply","screen","overlay","darken","lighten","color-dodge","color-burn","soft-light","hard-light","difference","luminosity"]}}},"contentCorners":{"default":null,"anyOf":[{"type":"object","properties":{"topLeft":{"type":"integer","minimum":0,"maximum":120},"topRight":{"type":"integer","minimum":0,"maximum":120},"bottomRight":{"type":"integer","minimum":0,"maximum":120},"bottomLeft":{"type":"integer","minimum":0,"maximum":120}},"required":["topLeft","topRight","bottomRight","bottomLeft"]},{"type":"null"}]}}},"hero":{"default":null,"anyOf":[{"type":"object","properties":{"coverColor":{"default":null,"anyOf":[{"type":"string","maxLength":400},{"type":"null"}]},"coverImage":{"default":"","type":"string","maxLength":2000},"coverImageStyle":{"default":{"size":"cover","sizeValue":100,"x":50,"y":50,"repeat":"no-repeat","gapX":0,"gapY":0,"attachment":"scroll","blend":"normal"},"type":"object","properties":{"size":{"default":"cover","type":"string","enum":["cover","contain","auto","custom"]},"sizeValue":{"default":100,"type":"integer","minimum":1,"maximum":400},"x":{"default":50,"type":"integer","minimum":0,"maximum":100},"y":{"default":50,"type":"integer","minimum":0,"maximum":100},"repeat":{"default":"no-repeat","type":"string","enum":["no-repeat","repeat","repeat-x","repeat-y","space","round"]},"gapX":{"default":0,"type":"integer","minimum":0,"maximum":400},"gapY":{"default":0,"type":"integer","minimum":0,"maximum":400},"attachment":{"default":"scroll","type":"string","enum":["scroll","fixed"]},"blend":{"default":"normal","type":"string","enum":["normal","multiply","screen","overlay","darken","lighten","color-dodge","color-burn","soft-light","hard-light","difference","luminosity"]}}},"coverHeight":{"default":200,"type":"integer","minimum":40,"maximum":800},"radius":{"default":16,"type":"integer","minimum":0,"maximum":60},"radiusTop":{"default":null,"anyOf":[{"type":"integer","minimum":0,"maximum":60},{"type":"null"}]},"radiusBottom":{"default":null,"anyOf":[{"type":"integer","minimum":0,"maximum":60},{"type":"null"}]},"fade":{"default":false,"type":"boolean"},"fadeColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"fadeHeight":{"default":50,"type":"integer","minimum":5,"maximum":100},"avatar":{"default":"","type":"string","maxLength":2000},"avatarAlt":{"default":"","type":"string","maxLength":200},"avatarSize":{"default":112,"type":"integer","minimum":32,"maximum":320},"avatarShape":{"default":"circle","type":"string","enum":["circle","rounded","square"]},"avatarRadius":{"default":20,"type":"integer","minimum":0,"maximum":80},"avatarBorderWidth":{"default":4,"type":"integer","minimum":0,"maximum":16},"avatarBorderColor":{"default":"#ffffff","type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"avatarShadow":{"default":null,"anyOf":[{"type":"object","properties":{"x":{"default":0,"type":"integer","minimum":-100,"maximum":100},"y":{"default":4,"type":"integer","minimum":-100,"maximum":100},"blur":{"default":16,"type":"integer","minimum":0,"maximum":200},"spread":{"default":0,"type":"integer","minimum":-100,"maximum":100},"color":{"default":"#000000","type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"opacity":{"default":20,"type":"integer","minimum":0,"maximum":100}}},{"type":"null"}]},"avatarAlign":{"default":"center","type":"string","enum":["left","center","right"]},"avatarOverlap":{"default":50,"type":"integer","minimum":0,"maximum":100},"buttonTheme":{"default":"dark","type":"string","enum":["dark","light"]},"buttonSize":{"default":36,"type":"integer","minimum":24,"maximum":72},"buttonShape":{"default":"circle","type":"string","enum":["circle","rounded","square"]},"buttonInset":{"default":12,"type":"integer","minimum":0,"maximum":64},"buttonOpacity":{"default":85,"type":"integer","minimum":10,"maximum":100},"left":{"default":[],"maxItems":3,"type":"array","items":{"type":"object","properties":{"id":{"type":"string","pattern":"^[A-Za-z0-9_-]{1,40}$"},"icon":{"default":"link","type":"string","enum":["link","globe","instagram","whatsapp","tiktok","youtube","linkedin","facebook","x","telegram","spotify","email","phone","calendar","form","file","shop","star","map","gift","share","menu","heart","user-plus","bell","message","info"]},"action":{"default":"link","type":"string","enum":["link","share"]},"url":{"default":"","type":"string","maxLength":2000},"label":{"default":"","type":"string","maxLength":60}},"required":["id"]}},"right":{"default":[],"maxItems":3,"type":"array","items":{"type":"object","properties":{"id":{"type":"string","pattern":"^[A-Za-z0-9_-]{1,40}$"},"icon":{"default":"link","type":"string","enum":["link","globe","instagram","whatsapp","tiktok","youtube","linkedin","facebook","x","telegram","spotify","email","phone","calendar","form","file","shop","star","map","gift","share","menu","heart","user-plus","bell","message","info"]},"action":{"default":"link","type":"string","enum":["link","share"]},"url":{"default":"","type":"string","maxLength":2000},"label":{"default":"","type":"string","maxLength":60}},"required":["id"]}},"padding":{"default":{"top":0,"right":0,"bottom":16,"left":0},"type":"object","properties":{"top":{"type":"integer","minimum":0,"maximum":200},"right":{"type":"integer","minimum":0,"maximum":200},"bottom":{"type":"integer","minimum":0,"maximum":200},"left":{"type":"integer","minimum":0,"maximum":200}},"required":["top","right","bottom","left"]}}},{"type":"null"}]},"rows":{"maxItems":100,"type":"array","items":{"type":"object","properties":{"id":{"type":"string","minLength":1,"maxLength":40},"columns":{"minItems":1,"maxItems":4,"type":"array","items":{"type":"object","properties":{"id":{"type":"string","minLength":1,"maxLength":40},"blocks":{"maxItems":60,"type":"array","items":{"oneOf":[{"type":"object","properties":{"type":{"type":"string","const":"heading"},"id":{"type":"string","minLength":1,"maxLength":40},"padding":{"default":{"top":10,"right":25,"bottom":10,"left":25},"type":"object","properties":{"top":{"type":"integer","minimum":0,"maximum":200},"right":{"type":"integer","minimum":0,"maximum":200},"bottom":{"type":"integer","minimum":0,"maximum":200},"left":{"type":"integer","minimum":0,"maximum":200}},"required":["top","right","bottom","left"]},"backgroundColor":{"default":null,"anyOf":[{"type":"string","maxLength":400},{"type":"null"}]},"hideOn":{"default":null,"anyOf":[{"type":"string","enum":["mobile","desktop"]},{"type":"null"}]},"fontFamily":{"default":null,"anyOf":[{"type":"string","maxLength":60,"pattern":"^[\\p{L}\\p{N} '-]+$"},{"type":"null"}]},"fontSize":{"default":null,"anyOf":[{"type":"integer","minimum":0,"maximum":96},{"type":"null"}]},"color":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"lineHeight":{"default":null,"anyOf":[{"type":"number","minimum":0.8,"maximum":3},{"type":"null"}]},"letterSpacing":{"default":0,"type":"number","minimum":-5,"maximum":20},"align":{"default":"left","type":"string","enum":["left","center","right"]},"html":{"type":"string","maxLength":50000},"level":{"default":1,"anyOf":[{"type":"number","const":1},{"type":"number","const":2},{"type":"number","const":3}]},"fontWeight":{"default":700,"type":"integer","minimum":100,"maximum":900},"shadow":{"default":null,"anyOf":[{"type":"object","properties":{"x":{"default":0,"type":"integer","minimum":-100,"maximum":100},"y":{"default":4,"type":"integer","minimum":-100,"maximum":100},"blur":{"default":16,"type":"integer","minimum":0,"maximum":200},"spread":{"default":0,"type":"integer","minimum":-100,"maximum":100},"color":{"default":"#000000","type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"opacity":{"default":20,"type":"integer","minimum":0,"maximum":100}}},{"type":"null"}]}},"required":["type","id","html"]},{"type":"object","properties":{"type":{"type":"string","const":"text"},"id":{"type":"string","minLength":1,"maxLength":40},"padding":{"default":{"top":10,"right":25,"bottom":10,"left":25},"type":"object","properties":{"top":{"type":"integer","minimum":0,"maximum":200},"right":{"type":"integer","minimum":0,"maximum":200},"bottom":{"type":"integer","minimum":0,"maximum":200},"left":{"type":"integer","minimum":0,"maximum":200}},"required":["top","right","bottom","left"]},"backgroundColor":{"default":null,"anyOf":[{"type":"string","maxLength":400},{"type":"null"}]},"hideOn":{"default":null,"anyOf":[{"type":"string","enum":["mobile","desktop"]},{"type":"null"}]},"fontFamily":{"default":null,"anyOf":[{"type":"string","maxLength":60,"pattern":"^[\\p{L}\\p{N} '-]+$"},{"type":"null"}]},"fontSize":{"default":null,"anyOf":[{"type":"integer","minimum":0,"maximum":96},{"type":"null"}]},"color":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"lineHeight":{"default":null,"anyOf":[{"type":"number","minimum":0.8,"maximum":3},{"type":"null"}]},"letterSpacing":{"default":0,"type":"number","minimum":-5,"maximum":20},"align":{"default":"left","type":"string","enum":["left","center","right"]},"html":{"type":"string","maxLength":50000},"shadow":{"default":null,"anyOf":[{"type":"object","properties":{"x":{"default":0,"type":"integer","minimum":-100,"maximum":100},"y":{"default":4,"type":"integer","minimum":-100,"maximum":100},"blur":{"default":16,"type":"integer","minimum":0,"maximum":200},"spread":{"default":0,"type":"integer","minimum":-100,"maximum":100},"color":{"default":"#000000","type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"opacity":{"default":20,"type":"integer","minimum":0,"maximum":100}}},{"type":"null"}]}},"required":["type","id","html"]},{"type":"object","properties":{"type":{"type":"string","const":"button"},"id":{"type":"string","minLength":1,"maxLength":40},"padding":{"default":{"top":10,"right":25,"bottom":10,"left":25},"type":"object","properties":{"top":{"type":"integer","minimum":0,"maximum":200},"right":{"type":"integer","minimum":0,"maximum":200},"bottom":{"type":"integer","minimum":0,"maximum":200},"left":{"type":"integer","minimum":0,"maximum":200}},"required":["top","right","bottom","left"]},"backgroundColor":{"default":null,"anyOf":[{"type":"string","maxLength":400},{"type":"null"}]},"hideOn":{"default":null,"anyOf":[{"type":"string","enum":["mobile","desktop"]},{"type":"null"}]},"label":{"type":"string","maxLength":200},"url":{"type":"string","maxLength":2000},"align":{"default":"center","type":"string","enum":["left","center","right"]},"buttonColor":{"default":null,"anyOf":[{"type":"string","maxLength":400},{"type":"null"}]},"textColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"fontFamily":{"default":null,"anyOf":[{"type":"string","maxLength":60,"pattern":"^[\\p{L}\\p{N} '-]+$"},{"type":"null"}]},"fontSize":{"default":16,"type":"integer","minimum":0,"maximum":48},"fontWeight":{"default":600,"type":"integer","minimum":100,"maximum":900},"radius":{"default":6,"type":"integer","minimum":0,"maximum":100},"innerPadding":{"default":{"vertical":12,"horizontal":24},"type":"object","properties":{"vertical":{"type":"integer","minimum":0,"maximum":60},"horizontal":{"type":"integer","minimum":0,"maximum":120}},"required":["vertical","horizontal"]},"borderColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"borderWidth":{"default":0,"type":"integer","minimum":0,"maximum":10},"fullWidth":{"default":false,"type":"boolean"},"shadow":{"default":null,"anyOf":[{"type":"object","properties":{"x":{"default":0,"type":"integer","minimum":-100,"maximum":100},"y":{"default":4,"type":"integer","minimum":-100,"maximum":100},"blur":{"default":16,"type":"integer","minimum":0,"maximum":200},"spread":{"default":0,"type":"integer","minimum":-100,"maximum":100},"color":{"default":"#000000","type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"opacity":{"default":20,"type":"integer","minimum":0,"maximum":100}}},{"type":"null"}]},"hover":{"default":null,"anyOf":[{"type":"object","properties":{"duration":{"default":200,"type":"integer","minimum":0,"maximum":3000},"easing":{"default":"ease","type":"string","enum":["ease","ease-in","ease-out","ease-in-out","linear"]},"style":{"default":{},"type":"object","propertyNames":{"type":"string"},"additionalProperties":{}}}},{"type":"null"}]}},"required":["type","id","label","url"]},{"type":"object","properties":{"type":{"type":"string","const":"image"},"id":{"type":"string","minLength":1,"maxLength":40},"padding":{"default":{"top":10,"right":25,"bottom":10,"left":25},"type":"object","properties":{"top":{"type":"integer","minimum":0,"maximum":200},"right":{"type":"integer","minimum":0,"maximum":200},"bottom":{"type":"integer","minimum":0,"maximum":200},"left":{"type":"integer","minimum":0,"maximum":200}},"required":["top","right","bottom","left"]},"backgroundColor":{"default":null,"anyOf":[{"type":"string","maxLength":400},{"type":"null"}]},"hideOn":{"default":null,"anyOf":[{"type":"string","enum":["mobile","desktop"]},{"type":"null"}]},"src":{"type":"string","maxLength":2000},"alt":{"default":"","type":"string","maxLength":300},"url":{"default":"","type":"string","maxLength":2000},"width":{"default":100,"type":"integer","minimum":5,"maximum":100},"align":{"default":"center","type":"string","enum":["left","center","right"]},"radius":{"default":0,"type":"integer","minimum":0,"maximum":200},"shadow":{"default":null,"anyOf":[{"type":"object","properties":{"x":{"default":0,"type":"integer","minimum":-100,"maximum":100},"y":{"default":4,"type":"integer","minimum":-100,"maximum":100},"blur":{"default":16,"type":"integer","minimum":0,"maximum":200},"spread":{"default":0,"type":"integer","minimum":-100,"maximum":100},"color":{"default":"#000000","type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"opacity":{"default":20,"type":"integer","minimum":0,"maximum":100}}},{"type":"null"}]}},"required":["type","id","src"]},{"type":"object","properties":{"type":{"type":"string","const":"divider"},"id":{"type":"string","minLength":1,"maxLength":40},"padding":{"default":{"top":10,"right":25,"bottom":10,"left":25},"type":"object","properties":{"top":{"type":"integer","minimum":0,"maximum":200},"right":{"type":"integer","minimum":0,"maximum":200},"bottom":{"type":"integer","minimum":0,"maximum":200},"left":{"type":"integer","minimum":0,"maximum":200}},"required":["top","right","bottom","left"]},"backgroundColor":{"default":null,"anyOf":[{"type":"string","maxLength":400},{"type":"null"}]},"hideOn":{"default":null,"anyOf":[{"type":"string","enum":["mobile","desktop"]},{"type":"null"}]},"color":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"thickness":{"default":1,"type":"integer","minimum":0,"maximum":20},"style":{"default":"solid","type":"string","enum":["solid","dashed","dotted"]},"width":{"default":100,"type":"integer","minimum":5,"maximum":100},"align":{"default":"center","type":"string","enum":["left","center","right"]},"shadow":{"default":null,"anyOf":[{"type":"object","properties":{"x":{"default":0,"type":"integer","minimum":-100,"maximum":100},"y":{"default":4,"type":"integer","minimum":-100,"maximum":100},"blur":{"default":16,"type":"integer","minimum":0,"maximum":200},"spread":{"default":0,"type":"integer","minimum":-100,"maximum":100},"color":{"default":"#000000","type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"opacity":{"default":20,"type":"integer","minimum":0,"maximum":100}}},{"type":"null"}]}},"required":["type","id"]},{"type":"object","properties":{"type":{"type":"string","const":"spacer"},"id":{"type":"string","minLength":1,"maxLength":40},"padding":{"default":{"top":10,"right":25,"bottom":10,"left":25},"type":"object","properties":{"top":{"type":"integer","minimum":0,"maximum":200},"right":{"type":"integer","minimum":0,"maximum":200},"bottom":{"type":"integer","minimum":0,"maximum":200},"left":{"type":"integer","minimum":0,"maximum":200}},"required":["top","right","bottom","left"]},"backgroundColor":{"default":null,"anyOf":[{"type":"string","maxLength":400},{"type":"null"}]},"hideOn":{"default":null,"anyOf":[{"type":"string","enum":["mobile","desktop"]},{"type":"null"}]},"height":{"default":24,"type":"integer","minimum":0,"maximum":400},"shadow":{"default":null,"anyOf":[{"type":"object","properties":{"x":{"default":0,"type":"integer","minimum":-100,"maximum":100},"y":{"default":4,"type":"integer","minimum":-100,"maximum":100},"blur":{"default":16,"type":"integer","minimum":0,"maximum":200},"spread":{"default":0,"type":"integer","minimum":-100,"maximum":100},"color":{"default":"#000000","type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"opacity":{"default":20,"type":"integer","minimum":0,"maximum":100}}},{"type":"null"}]}},"required":["type","id"]},{"type":"object","properties":{"type":{"type":"string","const":"social"},"id":{"type":"string","minLength":1,"maxLength":40},"padding":{"default":{"top":10,"right":25,"bottom":10,"left":25},"type":"object","properties":{"top":{"type":"integer","minimum":0,"maximum":200},"right":{"type":"integer","minimum":0,"maximum":200},"bottom":{"type":"integer","minimum":0,"maximum":200},"left":{"type":"integer","minimum":0,"maximum":200}},"required":["top","right","bottom","left"]},"backgroundColor":{"default":null,"anyOf":[{"type":"string","maxLength":400},{"type":"null"}]},"hideOn":{"default":null,"anyOf":[{"type":"string","enum":["mobile","desktop"]},{"type":"null"}]},"links":{"maxItems":10,"type":"array","items":{"type":"object","properties":{"network":{"type":"string","enum":["facebook","instagram","linkedin","x","youtube","tiktok","whatsapp","threads","discord","pinterest","github","phone","web"]},"url":{"type":"string","maxLength":2000}},"required":["network","url"]}},"iconSize":{"default":28,"type":"integer","minimum":0,"maximum":64},"gap":{"default":8,"type":"integer","minimum":0,"maximum":40},"iconStyle":{"default":"filled","type":"string","enum":["filled","plain"]},"iconColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"iconRadius":{"default":4,"type":"integer","minimum":0,"maximum":32},"align":{"default":"center","type":"string","enum":["left","center","right"]},"shadow":{"default":null,"anyOf":[{"type":"object","properties":{"x":{"default":0,"type":"integer","minimum":-100,"maximum":100},"y":{"default":4,"type":"integer","minimum":-100,"maximum":100},"blur":{"default":16,"type":"integer","minimum":0,"maximum":200},"spread":{"default":0,"type":"integer","minimum":-100,"maximum":100},"color":{"default":"#000000","type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"opacity":{"default":20,"type":"integer","minimum":0,"maximum":100}}},{"type":"null"}]}},"required":["type","id","links"]},{"type":"object","properties":{"type":{"type":"string","const":"catalog"},"id":{"type":"string","minLength":1,"maxLength":40},"padding":{"default":{"top":10,"right":25,"bottom":10,"left":25},"type":"object","properties":{"top":{"type":"integer","minimum":0,"maximum":200},"right":{"type":"integer","minimum":0,"maximum":200},"bottom":{"type":"integer","minimum":0,"maximum":200},"left":{"type":"integer","minimum":0,"maximum":200}},"required":["top","right","bottom","left"]},"backgroundColor":{"default":null,"anyOf":[{"type":"string","maxLength":400},{"type":"null"}]},"hideOn":{"default":null,"anyOf":[{"type":"string","enum":["mobile","desktop"]},{"type":"null"}]},"items":{"maxItems":12,"type":"array","items":{"type":"object","properties":{"kind":{"type":"string","enum":["service","package"]},"id":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},"url":{"default":"","type":"string","maxLength":2000}},"required":["kind","id"]}},"layout":{"default":"grid","type":"string","enum":["grid","list"]},"columns":{"default":2,"anyOf":[{"type":"number","const":1},{"type":"number","const":2},{"type":"number","const":3}]},"gap":{"default":16,"type":"integer","minimum":0,"maximum":40},"currency":{"default":null,"anyOf":[{"type":"string","pattern":"^[A-Z]{3}$"},{"type":"null"}]},"textAlign":{"default":"left","type":"string","enum":["left","center","right"]},"fontFamily":{"default":null,"anyOf":[{"type":"string","maxLength":60,"pattern":"^[\\p{L}\\p{N} '-]+$"},{"type":"null"}]},"cardColor":{"default":null,"anyOf":[{"type":"string","maxLength":400},{"type":"null"}]},"cardBorderColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"cardBorderWidth":{"default":1,"type":"integer","minimum":0,"maximum":10},"cardRadius":{"default":8,"type":"integer","minimum":0,"maximum":40},"cardPadding":{"default":16,"type":"integer","minimum":0,"maximum":60},"showImage":{"default":true,"type":"boolean"},"imageRatio":{"default":"square","type":"string","enum":["square","landscape","portrait","original"]},"imageRadius":{"default":4,"type":"integer","minimum":0,"maximum":40},"nameFontFamily":{"default":null,"anyOf":[{"type":"string","maxLength":60,"pattern":"^[\\p{L}\\p{N} '-]+$"},{"type":"null"}]},"nameFontSize":{"default":18,"type":"integer","minimum":0,"maximum":48},"nameFontWeight":{"default":700,"type":"integer","minimum":100,"maximum":900},"nameColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"showDescription":{"default":true,"type":"boolean"},"descriptionLength":{"default":120,"type":"integer","minimum":20,"maximum":600},"descriptionFontSize":{"default":14,"type":"integer","minimum":0,"maximum":32},"descriptionColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"showPrice":{"default":true,"type":"boolean"},"showOriginalPrice":{"default":true,"type":"boolean"},"priceFontSize":{"default":18,"type":"integer","minimum":0,"maximum":48},"priceFontWeight":{"default":700,"type":"integer","minimum":100,"maximum":900},"priceColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"showButton":{"default":true,"type":"boolean"},"buttonLabel":{"default":"","type":"string","maxLength":80},"buttonUrl":{"default":"","type":"string","maxLength":2000},"linkTo":{"default":"item","type":"string","enum":["item","catalogPage"]},"catalogPageId":{"default":null,"anyOf":[{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},{"type":"null"}]},"buttonColor":{"default":null,"anyOf":[{"type":"string","maxLength":400},{"type":"null"}]},"buttonTextColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"buttonFontSize":{"default":14,"type":"integer","minimum":0,"maximum":32},"buttonRadius":{"default":6,"type":"integer","minimum":0,"maximum":40},"buttonFullWidth":{"default":true,"type":"boolean"},"shadow":{"default":null,"anyOf":[{"type":"object","properties":{"x":{"default":0,"type":"integer","minimum":-100,"maximum":100},"y":{"default":4,"type":"integer","minimum":-100,"maximum":100},"blur":{"default":16,"type":"integer","minimum":0,"maximum":200},"spread":{"default":0,"type":"integer","minimum":-100,"maximum":100},"color":{"default":"#000000","type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"opacity":{"default":20,"type":"integer","minimum":0,"maximum":100}}},{"type":"null"}]},"hover":{"default":null,"anyOf":[{"type":"object","properties":{"duration":{"default":200,"type":"integer","minimum":0,"maximum":3000},"easing":{"default":"ease","type":"string","enum":["ease","ease-in","ease-out","ease-in-out","linear"]},"style":{"default":{},"type":"object","propertyNames":{"type":"string"},"additionalProperties":{}}}},{"type":"null"}]}},"required":["type","id","items"]},{"type":"object","properties":{"type":{"type":"string","const":"video"},"id":{"type":"string","minLength":1,"maxLength":40},"padding":{"default":{"top":10,"right":25,"bottom":10,"left":25},"type":"object","properties":{"top":{"type":"integer","minimum":0,"maximum":200},"right":{"type":"integer","minimum":0,"maximum":200},"bottom":{"type":"integer","minimum":0,"maximum":200},"left":{"type":"integer","minimum":0,"maximum":200}},"required":["top","right","bottom","left"]},"backgroundColor":{"default":null,"anyOf":[{"type":"string","maxLength":400},{"type":"null"}]},"hideOn":{"default":null,"anyOf":[{"type":"string","enum":["mobile","desktop"]},{"type":"null"}]},"url":{"type":"string","maxLength":500},"title":{"default":"","type":"string","maxLength":200},"ratio":{"default":"16:9","type":"string","enum":["16:9","4:3","1:1","9:16"]},"width":{"default":100,"type":"integer","minimum":20,"maximum":100},"align":{"default":"center","type":"string","enum":["left","center","right"]},"radius":{"default":8,"type":"integer","minimum":0,"maximum":60},"shadow":{"default":null,"anyOf":[{"type":"object","properties":{"x":{"default":0,"type":"integer","minimum":-100,"maximum":100},"y":{"default":4,"type":"integer","minimum":-100,"maximum":100},"blur":{"default":16,"type":"integer","minimum":0,"maximum":200},"spread":{"default":0,"type":"integer","minimum":-100,"maximum":100},"color":{"default":"#000000","type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"opacity":{"default":20,"type":"integer","minimum":0,"maximum":100}}},{"type":"null"}]}},"required":["type","id","url"]},{"type":"object","properties":{"type":{"type":"string","const":"form"},"id":{"type":"string","minLength":1,"maxLength":40},"padding":{"default":{"top":10,"right":25,"bottom":10,"left":25},"type":"object","properties":{"top":{"type":"integer","minimum":0,"maximum":200},"right":{"type":"integer","minimum":0,"maximum":200},"bottom":{"type":"integer","minimum":0,"maximum":200},"left":{"type":"integer","minimum":0,"maximum":200}},"required":["top","right","bottom","left"]},"backgroundColor":{"default":null,"anyOf":[{"type":"string","maxLength":400},{"type":"null"}]},"hideOn":{"default":null,"anyOf":[{"type":"string","enum":["mobile","desktop"]},{"type":"null"}]},"formId":{"default":null,"anyOf":[{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},{"type":"null"}]},"fieldsOnly":{"default":false,"type":"boolean"},"pageTheme":{"default":false,"type":"boolean"},"shadow":{"default":null,"anyOf":[{"type":"object","properties":{"x":{"default":0,"type":"integer","minimum":-100,"maximum":100},"y":{"default":4,"type":"integer","minimum":-100,"maximum":100},"blur":{"default":16,"type":"integer","minimum":0,"maximum":200},"spread":{"default":0,"type":"integer","minimum":-100,"maximum":100},"color":{"default":"#000000","type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"opacity":{"default":20,"type":"integer","minimum":0,"maximum":100}}},{"type":"null"}]}},"required":["type","id"]},{"type":"object","properties":{"type":{"type":"string","const":"card"},"id":{"type":"string","minLength":1,"maxLength":40},"padding":{"default":{"top":10,"right":25,"bottom":10,"left":25},"type":"object","properties":{"top":{"type":"integer","minimum":0,"maximum":200},"right":{"type":"integer","minimum":0,"maximum":200},"bottom":{"type":"integer","minimum":0,"maximum":200},"left":{"type":"integer","minimum":0,"maximum":200}},"required":["top","right","bottom","left"]},"backgroundColor":{"default":null,"anyOf":[{"type":"string","maxLength":400},{"type":"null"}]},"hideOn":{"default":null,"anyOf":[{"type":"string","enum":["mobile","desktop"]},{"type":"null"}]},"src":{"type":"string","maxLength":2000},"alt":{"default":"","type":"string","maxLength":300},"imagePosition":{"default":"left","type":"string","enum":["top","left","right"]},"imageWidth":{"default":40,"type":"integer","minimum":20,"maximum":70},"imageRatio":{"default":"landscape","type":"string","enum":["original","square","landscape","portrait"]},"imageRadius":{"default":8,"type":"integer","minimum":0,"maximum":200},"imageBleed":{"default":false,"type":"boolean"},"title":{"default":"","type":"string","maxLength":200},"html":{"default":"","type":"string","maxLength":20000},"url":{"default":"","type":"string","maxLength":2000},"titleFontSize":{"default":20,"type":"integer","minimum":10,"maximum":72},"titleColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"textColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"fontFamily":{"default":null,"anyOf":[{"type":"string","maxLength":60,"pattern":"^[\\p{L}\\p{N} '-]+$"},{"type":"null"}]},"textAlign":{"default":"left","type":"string","enum":["left","center","right"]},"verticalAlign":{"default":"middle","type":"string","enum":["top","middle"]},"cardColor":{"default":null,"anyOf":[{"type":"string","maxLength":400},{"type":"null"}]},"borderColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"borderWidth":{"default":1,"type":"integer","minimum":0,"maximum":10},"radius":{"default":12,"type":"integer","minimum":0,"maximum":60},"cardPadding":{"default":16,"type":"integer","minimum":0,"maximum":80},"gap":{"default":16,"type":"integer","minimum":0,"maximum":80},"shadow":{"default":null,"anyOf":[{"type":"object","properties":{"x":{"default":0,"type":"integer","minimum":-100,"maximum":100},"y":{"default":4,"type":"integer","minimum":-100,"maximum":100},"blur":{"default":16,"type":"integer","minimum":0,"maximum":200},"spread":{"default":0,"type":"integer","minimum":-100,"maximum":100},"color":{"default":"#000000","type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"opacity":{"default":20,"type":"integer","minimum":0,"maximum":100}}},{"type":"null"}]},"hover":{"default":null,"anyOf":[{"type":"object","properties":{"duration":{"default":200,"type":"integer","minimum":0,"maximum":3000},"easing":{"default":"ease","type":"string","enum":["ease","ease-in","ease-out","ease-in-out","linear"]},"style":{"default":{},"type":"object","propertyNames":{"type":"string"},"additionalProperties":{}}}},{"type":"null"}]}},"required":["type","id","src"]}]}},"backgroundColor":{"default":null,"anyOf":[{"type":"string","maxLength":400},{"type":"null"}]},"padding":{"default":{"top":0,"right":0,"bottom":0,"left":0},"type":"object","properties":{"top":{"type":"integer","minimum":0,"maximum":200},"right":{"type":"integer","minimum":0,"maximum":200},"bottom":{"type":"integer","minimum":0,"maximum":200},"left":{"type":"integer","minimum":0,"maximum":200}},"required":["top","right","bottom","left"]},"radius":{"default":0,"type":"integer","minimum":0,"maximum":100},"verticalAlign":{"default":"top","type":"string","enum":["top","middle","bottom"]},"shadow":{"default":null,"anyOf":[{"type":"object","properties":{"x":{"default":0,"type":"integer","minimum":-100,"maximum":100},"y":{"default":4,"type":"integer","minimum":-100,"maximum":100},"blur":{"default":16,"type":"integer","minimum":0,"maximum":200},"spread":{"default":0,"type":"integer","minimum":-100,"maximum":100},"color":{"default":"#000000","type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"opacity":{"default":20,"type":"integer","minimum":0,"maximum":100}}},{"type":"null"}]}},"required":["id","blocks"]}},"widths":{"minItems":1,"maxItems":4,"type":"array","items":{"type":"number","minimum":10,"maximum":100}},"backgroundColor":{"default":null,"anyOf":[{"type":"string","maxLength":400},{"type":"null"}]},"backgroundImage":{"default":"","type":"string","maxLength":2000},"fullWidth":{"default":false,"type":"boolean"},"padding":{"default":{"top":10,"right":0,"bottom":10,"left":0},"type":"object","properties":{"top":{"type":"integer","minimum":0,"maximum":200},"right":{"type":"integer","minimum":0,"maximum":200},"bottom":{"type":"integer","minimum":0,"maximum":200},"left":{"type":"integer","minimum":0,"maximum":200}},"required":["top","right","bottom","left"]},"radius":{"default":0,"type":"integer","minimum":0,"maximum":100},"borderColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"borderWidth":{"default":0,"type":"integer","minimum":0,"maximum":10},"stackOnMobile":{"default":true,"type":"boolean"},"hideOn":{"default":null,"anyOf":[{"type":"string","enum":["mobile","desktop"]},{"type":"null"}]},"shadow":{"default":null,"anyOf":[{"type":"object","properties":{"x":{"default":0,"type":"integer","minimum":-100,"maximum":100},"y":{"default":4,"type":"integer","minimum":-100,"maximum":100},"blur":{"default":16,"type":"integer","minimum":0,"maximum":200},"spread":{"default":0,"type":"integer","minimum":-100,"maximum":100},"color":{"default":"#000000","type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"opacity":{"default":20,"type":"integer","minimum":0,"maximum":100}}},{"type":"null"}]}},"required":["id","columns","widths"]}}},"required":["rows"]},"showBranding":{"default":true,"type":"boolean"},"active":{"default":false,"type":"boolean"}}}}}},"responses":{"201":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"active":{"type":"boolean"},"clicks30":{"type":"integer"},"createdAt":{"format":"date-time","type":"string"},"createdBy":{"format":"uuid","type":"string"},"description":{"type":["null","string"]},"document":{"properties":{"hero":{"type":"null"},"rows":{"items":{"properties":{"backgroundColor":{"type":"null"},"backgroundImage":{"type":"string"},"borderColor":{"type":"null"},"borderWidth":{"type":"integer"},"columns":{"items":{"properties":{"backgroundColor":{"type":"null"},"blocks":{"items":{"properties":{"align":{"type":"string"},"alt":{"type":"string"},"backgroundColor":{"type":"null"},"borderColor":{"type":"null"},"borderWidth":{"type":"integer"},"buttonColor":{"type":"null"},"cardColor":{"type":"null"},"cardPadding":{"type":"integer"},"color":{"type":"null"},"fieldsOnly":{"type":"boolean"},"fontFamily":{"type":"null"},"fontSize":{"type":["integer","null"]},"fontWeight":{"type":"integer"},"formId":{"format":"uuid","type":"string"},"fullWidth":{"type":"boolean"},"gap":{"type":"integer"},"hideOn":{"type":"null"},"hover":{"type":"null"},"html":{"type":"string"},"id":{"type":"string"},"imageBleed":{"type":"boolean"},"imagePosition":{"type":"string"},"imageRadius":{"type":"integer"},"imageRatio":{"type":"string"},"imageWidth":{"type":"integer"},"innerPadding":{"properties":{"horizontal":{"type":"integer"},"vertical":{"type":"integer"}},"required":["vertical","horizontal"],"type":"object"},"label":{"type":"string"},"letterSpacing":{"type":"integer"},"level":{"type":"integer"},"lineHeight":{"type":"null"},"padding":{"properties":{"bottom":{"type":"integer"},"left":{"type":"integer"},"right":{"type":"integer"},"top":{"type":"integer"}},"required":["top","left","right","bottom"],"type":"object"},"pageTheme":{"type":"boolean"},"radius":{"type":"integer"},"ratio":{"type":"string"},"shadow":{"type":"null"},"src":{"format":"uri","type":"string"},"textAlign":{"type":"string"},"textColor":{"type":"null"},"title":{"type":"string"},"titleColor":{"type":"null"},"titleFontSize":{"type":"integer"},"type":{"type":"string"},"url":{"format":"uri","type":"string"},"verticalAlign":{"type":"string"},"width":{"type":"integer"}},"required":["id","type","hideOn","shadow","padding","backgroundColor"],"type":"object"},"type":"array"},"id":{"type":"string"},"padding":{"properties":{"bottom":{"type":"integer"},"left":{"type":"integer"},"right":{"type":"integer"},"top":{"type":"integer"}},"required":["top","left","right","bottom"],"type":"object"},"radius":{"type":"integer"},"shadow":{"type":"null"},"verticalAlign":{"type":"string"}},"required":["id","blocks","radius","shadow","padding","verticalAlign","backgroundColor"],"type":"object"},"type":"array"},"fullWidth":{"type":"boolean"},"hideOn":{"type":"null"},"id":{"type":"string"},"padding":{"properties":{"bottom":{"type":"integer"},"left":{"type":"integer"},"right":{"type":"integer"},"top":{"type":"integer"}},"required":["top","left","right","bottom"],"type":"object"},"radius":{"type":"integer"},"shadow":{"type":"null"},"stackOnMobile":{"type":"boolean"},"widths":{"items":{"type":"integer"},"type":"array"}},"required":["id","hideOn","radius","shadow","widths","columns","padding","fullWidth","borderColor","borderWidth","stackOnMobile","backgroundColor","backgroundImage"],"type":"object"},"type":"array"},"settings":{"properties":{"backdropColor":{"type":"string"},"backdropImage":{"type":"string"},"backdropImageStyle":{"properties":{"attachment":{"type":"string"},"blend":{"type":"string"},"gapX":{"type":"integer"},"gapY":{"type":"integer"},"repeat":{"type":"string"},"size":{"type":"string"},"sizeValue":{"type":"integer"},"x":{"type":"integer"},"y":{"type":"integer"}},"required":["x","y","gapX","gapY","size","blend","repeat","sizeValue","attachment"],"type":"object"},"contentColor":{"type":"string"},"contentCorners":{"type":"null"},"contentImage":{"type":"string"},"contentImageStyle":{"properties":{"attachment":{"type":"string"},"blend":{"type":"string"},"gapX":{"type":"integer"},"gapY":{"type":"integer"},"repeat":{"type":"string"},"size":{"type":"string"},"sizeValue":{"type":"integer"},"x":{"type":"integer"},"y":{"type":"integer"}},"required":["x","y","gapX","gapY","size","blend","repeat","sizeValue","attachment"],"type":"object"},"fontFamily":{"type":"string"},"fontSize":{"type":"integer"},"headingColor":{"type":"string"},"headingFontFamily":{"type":"string"},"lineHeight":{"type":"number"},"linkColor":{"type":"string"},"onPrimaryColor":{"type":"string"},"outerPadding":{"type":"integer"},"primaryColor":{"type":"string"},"radius":{"type":"integer"},"textColor":{"type":"string"},"width":{"type":"integer"}},"required":["width","radius","fontSize","linkColor","textColor","fontFamily","lineHeight","contentColor","contentImage","headingColor","outerPadding","primaryColor","backdropColor","backdropImage","contentCorners","onPrimaryColor","contentImageStyle","headingFontFamily","backdropImageStyle"],"type":"object"},"version":{"type":"integer"}},"required":["hero","rows","version","settings"],"type":"object"},"id":{"format":"uuid","type":"string"},"name":{"type":"string"},"showBranding":{"type":"boolean"},"slug":{"type":"string"},"title":{"type":"string"},"updatedAt":{"format":"date-time","type":"string"},"updatedBy":{"format":"uuid","type":"string"},"url":{"format":"uri","type":"string"},"views30":{"type":"integer"}},"required":["id","slug","name","title","description","document","showBranding","active","createdBy","updatedBy","createdAt","updatedAt","url","views30","clicks30"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/microsites/{id}":{"delete":{"operationId":"DELETE /v1/microsites/{id}","summary":"Deletes the microsite.","tags":["microsites"],"x-feature":"microsites","x-action":"delete","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"204":{"description":"Done, with no content."},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"get":{"operationId":"GET /v1/microsites/{id}","summary":"Returns the microsite with its document.","tags":["microsites"],"x-feature":"microsites","x-action":"read","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"patch":{"operationId":"PATCH /v1/microsites/{id}","summary":"Changes the microsite: blocks, header, look and address.","tags":["microsites"],"x-feature":"microsites","x-action":"update","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"name":{"type":"string","minLength":1,"maxLength":120},"slug":{"type":"string","pattern":"^[a-z0-9](?:[a-z0-9-]{1,38}[a-z0-9])$"},"title":{"type":"string","minLength":1,"maxLength":120},"description":{"anyOf":[{"type":"string","maxLength":300},{"type":"null"}]},"document":{"type":"object","properties":{"version":{"default":1,"type":"number","const":1},"settings":{"default":{"backdropColor":"#ffffff","contentColor":"#ffffff","width":720,"fontFamily":"Arial","headingFontFamily":"Arial","fontSize":16,"lineHeight":1.5,"textColor":"#1f2937","headingColor":"#111827","linkColor":"#2563eb","primaryColor":"#2563eb","onPrimaryColor":"#ffffff","radius":0,"outerPadding":0,"backdropImage":"","contentImage":"","backdropImageStyle":{"size":"cover","sizeValue":100,"x":50,"y":50,"repeat":"no-repeat","gapX":0,"gapY":0,"attachment":"scroll","blend":"normal"},"contentImageStyle":{"size":"cover","sizeValue":100,"x":50,"y":50,"repeat":"no-repeat","gapX":0,"gapY":0,"attachment":"scroll","blend":"normal"},"contentCorners":null},"type":"object","properties":{"backdropColor":{"default":"#ffffff","type":"string","maxLength":400},"contentColor":{"default":"#ffffff","type":"string","maxLength":400},"width":{"default":720,"type":"integer","minimum":320,"maximum":1200},"fontFamily":{"default":"Arial","type":"string","maxLength":60},"headingFontFamily":{"default":"Arial","type":"string","maxLength":60},"fontSize":{"default":16,"type":"integer","minimum":0,"maximum":40},"lineHeight":{"default":1.5,"type":"number","minimum":0.8,"maximum":3},"textColor":{"default":"#1f2937","type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"headingColor":{"default":"#111827","type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"linkColor":{"default":"#2563eb","type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"primaryColor":{"default":"#2563eb","type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"onPrimaryColor":{"default":"#ffffff","type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"radius":{"default":0,"type":"integer","minimum":0,"maximum":40},"outerPadding":{"default":0,"type":"integer","minimum":0,"maximum":120},"backdropImage":{"default":"","type":"string","maxLength":2000},"contentImage":{"default":"","type":"string","maxLength":2000},"backdropImageStyle":{"default":{"size":"cover","sizeValue":100,"x":50,"y":50,"repeat":"no-repeat","gapX":0,"gapY":0,"attachment":"scroll","blend":"normal"},"type":"object","properties":{"size":{"default":"cover","type":"string","enum":["cover","contain","auto","custom"]},"sizeValue":{"default":100,"type":"integer","minimum":1,"maximum":400},"x":{"default":50,"type":"integer","minimum":0,"maximum":100},"y":{"default":50,"type":"integer","minimum":0,"maximum":100},"repeat":{"default":"no-repeat","type":"string","enum":["no-repeat","repeat","repeat-x","repeat-y","space","round"]},"gapX":{"default":0,"type":"integer","minimum":0,"maximum":400},"gapY":{"default":0,"type":"integer","minimum":0,"maximum":400},"attachment":{"default":"scroll","type":"string","enum":["scroll","fixed"]},"blend":{"default":"normal","type":"string","enum":["normal","multiply","screen","overlay","darken","lighten","color-dodge","color-burn","soft-light","hard-light","difference","luminosity"]}}},"contentImageStyle":{"default":{"size":"cover","sizeValue":100,"x":50,"y":50,"repeat":"no-repeat","gapX":0,"gapY":0,"attachment":"scroll","blend":"normal"},"type":"object","properties":{"size":{"default":"cover","type":"string","enum":["cover","contain","auto","custom"]},"sizeValue":{"default":100,"type":"integer","minimum":1,"maximum":400},"x":{"default":50,"type":"integer","minimum":0,"maximum":100},"y":{"default":50,"type":"integer","minimum":0,"maximum":100},"repeat":{"default":"no-repeat","type":"string","enum":["no-repeat","repeat","repeat-x","repeat-y","space","round"]},"gapX":{"default":0,"type":"integer","minimum":0,"maximum":400},"gapY":{"default":0,"type":"integer","minimum":0,"maximum":400},"attachment":{"default":"scroll","type":"string","enum":["scroll","fixed"]},"blend":{"default":"normal","type":"string","enum":["normal","multiply","screen","overlay","darken","lighten","color-dodge","color-burn","soft-light","hard-light","difference","luminosity"]}}},"contentCorners":{"default":null,"anyOf":[{"type":"object","properties":{"topLeft":{"type":"integer","minimum":0,"maximum":120},"topRight":{"type":"integer","minimum":0,"maximum":120},"bottomRight":{"type":"integer","minimum":0,"maximum":120},"bottomLeft":{"type":"integer","minimum":0,"maximum":120}},"required":["topLeft","topRight","bottomRight","bottomLeft"]},{"type":"null"}]}}},"hero":{"default":null,"anyOf":[{"type":"object","properties":{"coverColor":{"default":null,"anyOf":[{"type":"string","maxLength":400},{"type":"null"}]},"coverImage":{"default":"","type":"string","maxLength":2000},"coverImageStyle":{"default":{"size":"cover","sizeValue":100,"x":50,"y":50,"repeat":"no-repeat","gapX":0,"gapY":0,"attachment":"scroll","blend":"normal"},"type":"object","properties":{"size":{"default":"cover","type":"string","enum":["cover","contain","auto","custom"]},"sizeValue":{"default":100,"type":"integer","minimum":1,"maximum":400},"x":{"default":50,"type":"integer","minimum":0,"maximum":100},"y":{"default":50,"type":"integer","minimum":0,"maximum":100},"repeat":{"default":"no-repeat","type":"string","enum":["no-repeat","repeat","repeat-x","repeat-y","space","round"]},"gapX":{"default":0,"type":"integer","minimum":0,"maximum":400},"gapY":{"default":0,"type":"integer","minimum":0,"maximum":400},"attachment":{"default":"scroll","type":"string","enum":["scroll","fixed"]},"blend":{"default":"normal","type":"string","enum":["normal","multiply","screen","overlay","darken","lighten","color-dodge","color-burn","soft-light","hard-light","difference","luminosity"]}}},"coverHeight":{"default":200,"type":"integer","minimum":40,"maximum":800},"radius":{"default":16,"type":"integer","minimum":0,"maximum":60},"radiusTop":{"default":null,"anyOf":[{"type":"integer","minimum":0,"maximum":60},{"type":"null"}]},"radiusBottom":{"default":null,"anyOf":[{"type":"integer","minimum":0,"maximum":60},{"type":"null"}]},"fade":{"default":false,"type":"boolean"},"fadeColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"fadeHeight":{"default":50,"type":"integer","minimum":5,"maximum":100},"avatar":{"default":"","type":"string","maxLength":2000},"avatarAlt":{"default":"","type":"string","maxLength":200},"avatarSize":{"default":112,"type":"integer","minimum":32,"maximum":320},"avatarShape":{"default":"circle","type":"string","enum":["circle","rounded","square"]},"avatarRadius":{"default":20,"type":"integer","minimum":0,"maximum":80},"avatarBorderWidth":{"default":4,"type":"integer","minimum":0,"maximum":16},"avatarBorderColor":{"default":"#ffffff","type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"avatarShadow":{"default":null,"anyOf":[{"type":"object","properties":{"x":{"default":0,"type":"integer","minimum":-100,"maximum":100},"y":{"default":4,"type":"integer","minimum":-100,"maximum":100},"blur":{"default":16,"type":"integer","minimum":0,"maximum":200},"spread":{"default":0,"type":"integer","minimum":-100,"maximum":100},"color":{"default":"#000000","type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"opacity":{"default":20,"type":"integer","minimum":0,"maximum":100}}},{"type":"null"}]},"avatarAlign":{"default":"center","type":"string","enum":["left","center","right"]},"avatarOverlap":{"default":50,"type":"integer","minimum":0,"maximum":100},"buttonTheme":{"default":"dark","type":"string","enum":["dark","light"]},"buttonSize":{"default":36,"type":"integer","minimum":24,"maximum":72},"buttonShape":{"default":"circle","type":"string","enum":["circle","rounded","square"]},"buttonInset":{"default":12,"type":"integer","minimum":0,"maximum":64},"buttonOpacity":{"default":85,"type":"integer","minimum":10,"maximum":100},"left":{"default":[],"maxItems":3,"type":"array","items":{"type":"object","properties":{"id":{"type":"string","pattern":"^[A-Za-z0-9_-]{1,40}$"},"icon":{"default":"link","type":"string","enum":["link","globe","instagram","whatsapp","tiktok","youtube","linkedin","facebook","x","telegram","spotify","email","phone","calendar","form","file","shop","star","map","gift","share","menu","heart","user-plus","bell","message","info"]},"action":{"default":"link","type":"string","enum":["link","share"]},"url":{"default":"","type":"string","maxLength":2000},"label":{"default":"","type":"string","maxLength":60}},"required":["id"]}},"right":{"default":[],"maxItems":3,"type":"array","items":{"type":"object","properties":{"id":{"type":"string","pattern":"^[A-Za-z0-9_-]{1,40}$"},"icon":{"default":"link","type":"string","enum":["link","globe","instagram","whatsapp","tiktok","youtube","linkedin","facebook","x","telegram","spotify","email","phone","calendar","form","file","shop","star","map","gift","share","menu","heart","user-plus","bell","message","info"]},"action":{"default":"link","type":"string","enum":["link","share"]},"url":{"default":"","type":"string","maxLength":2000},"label":{"default":"","type":"string","maxLength":60}},"required":["id"]}},"padding":{"default":{"top":0,"right":0,"bottom":16,"left":0},"type":"object","properties":{"top":{"type":"integer","minimum":0,"maximum":200},"right":{"type":"integer","minimum":0,"maximum":200},"bottom":{"type":"integer","minimum":0,"maximum":200},"left":{"type":"integer","minimum":0,"maximum":200}},"required":["top","right","bottom","left"]}}},{"type":"null"}]},"rows":{"maxItems":100,"type":"array","items":{"type":"object","properties":{"id":{"type":"string","minLength":1,"maxLength":40},"columns":{"minItems":1,"maxItems":4,"type":"array","items":{"type":"object","properties":{"id":{"type":"string","minLength":1,"maxLength":40},"blocks":{"maxItems":60,"type":"array","items":{"oneOf":[{"type":"object","properties":{"type":{"type":"string","const":"heading"},"id":{"type":"string","minLength":1,"maxLength":40},"padding":{"default":{"top":10,"right":25,"bottom":10,"left":25},"type":"object","properties":{"top":{"type":"integer","minimum":0,"maximum":200},"right":{"type":"integer","minimum":0,"maximum":200},"bottom":{"type":"integer","minimum":0,"maximum":200},"left":{"type":"integer","minimum":0,"maximum":200}},"required":["top","right","bottom","left"]},"backgroundColor":{"default":null,"anyOf":[{"type":"string","maxLength":400},{"type":"null"}]},"hideOn":{"default":null,"anyOf":[{"type":"string","enum":["mobile","desktop"]},{"type":"null"}]},"fontFamily":{"default":null,"anyOf":[{"type":"string","maxLength":60,"pattern":"^[\\p{L}\\p{N} '-]+$"},{"type":"null"}]},"fontSize":{"default":null,"anyOf":[{"type":"integer","minimum":0,"maximum":96},{"type":"null"}]},"color":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"lineHeight":{"default":null,"anyOf":[{"type":"number","minimum":0.8,"maximum":3},{"type":"null"}]},"letterSpacing":{"default":0,"type":"number","minimum":-5,"maximum":20},"align":{"default":"left","type":"string","enum":["left","center","right"]},"html":{"type":"string","maxLength":50000},"level":{"default":1,"anyOf":[{"type":"number","const":1},{"type":"number","const":2},{"type":"number","const":3}]},"fontWeight":{"default":700,"type":"integer","minimum":100,"maximum":900},"shadow":{"default":null,"anyOf":[{"type":"object","properties":{"x":{"default":0,"type":"integer","minimum":-100,"maximum":100},"y":{"default":4,"type":"integer","minimum":-100,"maximum":100},"blur":{"default":16,"type":"integer","minimum":0,"maximum":200},"spread":{"default":0,"type":"integer","minimum":-100,"maximum":100},"color":{"default":"#000000","type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"opacity":{"default":20,"type":"integer","minimum":0,"maximum":100}}},{"type":"null"}]}},"required":["type","id","html"]},{"type":"object","properties":{"type":{"type":"string","const":"text"},"id":{"type":"string","minLength":1,"maxLength":40},"padding":{"default":{"top":10,"right":25,"bottom":10,"left":25},"type":"object","properties":{"top":{"type":"integer","minimum":0,"maximum":200},"right":{"type":"integer","minimum":0,"maximum":200},"bottom":{"type":"integer","minimum":0,"maximum":200},"left":{"type":"integer","minimum":0,"maximum":200}},"required":["top","right","bottom","left"]},"backgroundColor":{"default":null,"anyOf":[{"type":"string","maxLength":400},{"type":"null"}]},"hideOn":{"default":null,"anyOf":[{"type":"string","enum":["mobile","desktop"]},{"type":"null"}]},"fontFamily":{"default":null,"anyOf":[{"type":"string","maxLength":60,"pattern":"^[\\p{L}\\p{N} '-]+$"},{"type":"null"}]},"fontSize":{"default":null,"anyOf":[{"type":"integer","minimum":0,"maximum":96},{"type":"null"}]},"color":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"lineHeight":{"default":null,"anyOf":[{"type":"number","minimum":0.8,"maximum":3},{"type":"null"}]},"letterSpacing":{"default":0,"type":"number","minimum":-5,"maximum":20},"align":{"default":"left","type":"string","enum":["left","center","right"]},"html":{"type":"string","maxLength":50000},"shadow":{"default":null,"anyOf":[{"type":"object","properties":{"x":{"default":0,"type":"integer","minimum":-100,"maximum":100},"y":{"default":4,"type":"integer","minimum":-100,"maximum":100},"blur":{"default":16,"type":"integer","minimum":0,"maximum":200},"spread":{"default":0,"type":"integer","minimum":-100,"maximum":100},"color":{"default":"#000000","type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"opacity":{"default":20,"type":"integer","minimum":0,"maximum":100}}},{"type":"null"}]}},"required":["type","id","html"]},{"type":"object","properties":{"type":{"type":"string","const":"button"},"id":{"type":"string","minLength":1,"maxLength":40},"padding":{"default":{"top":10,"right":25,"bottom":10,"left":25},"type":"object","properties":{"top":{"type":"integer","minimum":0,"maximum":200},"right":{"type":"integer","minimum":0,"maximum":200},"bottom":{"type":"integer","minimum":0,"maximum":200},"left":{"type":"integer","minimum":0,"maximum":200}},"required":["top","right","bottom","left"]},"backgroundColor":{"default":null,"anyOf":[{"type":"string","maxLength":400},{"type":"null"}]},"hideOn":{"default":null,"anyOf":[{"type":"string","enum":["mobile","desktop"]},{"type":"null"}]},"label":{"type":"string","maxLength":200},"url":{"type":"string","maxLength":2000},"align":{"default":"center","type":"string","enum":["left","center","right"]},"buttonColor":{"default":null,"anyOf":[{"type":"string","maxLength":400},{"type":"null"}]},"textColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"fontFamily":{"default":null,"anyOf":[{"type":"string","maxLength":60,"pattern":"^[\\p{L}\\p{N} '-]+$"},{"type":"null"}]},"fontSize":{"default":16,"type":"integer","minimum":0,"maximum":48},"fontWeight":{"default":600,"type":"integer","minimum":100,"maximum":900},"radius":{"default":6,"type":"integer","minimum":0,"maximum":100},"innerPadding":{"default":{"vertical":12,"horizontal":24},"type":"object","properties":{"vertical":{"type":"integer","minimum":0,"maximum":60},"horizontal":{"type":"integer","minimum":0,"maximum":120}},"required":["vertical","horizontal"]},"borderColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"borderWidth":{"default":0,"type":"integer","minimum":0,"maximum":10},"fullWidth":{"default":false,"type":"boolean"},"shadow":{"default":null,"anyOf":[{"type":"object","properties":{"x":{"default":0,"type":"integer","minimum":-100,"maximum":100},"y":{"default":4,"type":"integer","minimum":-100,"maximum":100},"blur":{"default":16,"type":"integer","minimum":0,"maximum":200},"spread":{"default":0,"type":"integer","minimum":-100,"maximum":100},"color":{"default":"#000000","type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"opacity":{"default":20,"type":"integer","minimum":0,"maximum":100}}},{"type":"null"}]},"hover":{"default":null,"anyOf":[{"type":"object","properties":{"duration":{"default":200,"type":"integer","minimum":0,"maximum":3000},"easing":{"default":"ease","type":"string","enum":["ease","ease-in","ease-out","ease-in-out","linear"]},"style":{"default":{},"type":"object","propertyNames":{"type":"string"},"additionalProperties":{}}}},{"type":"null"}]}},"required":["type","id","label","url"]},{"type":"object","properties":{"type":{"type":"string","const":"image"},"id":{"type":"string","minLength":1,"maxLength":40},"padding":{"default":{"top":10,"right":25,"bottom":10,"left":25},"type":"object","properties":{"top":{"type":"integer","minimum":0,"maximum":200},"right":{"type":"integer","minimum":0,"maximum":200},"bottom":{"type":"integer","minimum":0,"maximum":200},"left":{"type":"integer","minimum":0,"maximum":200}},"required":["top","right","bottom","left"]},"backgroundColor":{"default":null,"anyOf":[{"type":"string","maxLength":400},{"type":"null"}]},"hideOn":{"default":null,"anyOf":[{"type":"string","enum":["mobile","desktop"]},{"type":"null"}]},"src":{"type":"string","maxLength":2000},"alt":{"default":"","type":"string","maxLength":300},"url":{"default":"","type":"string","maxLength":2000},"width":{"default":100,"type":"integer","minimum":5,"maximum":100},"align":{"default":"center","type":"string","enum":["left","center","right"]},"radius":{"default":0,"type":"integer","minimum":0,"maximum":200},"shadow":{"default":null,"anyOf":[{"type":"object","properties":{"x":{"default":0,"type":"integer","minimum":-100,"maximum":100},"y":{"default":4,"type":"integer","minimum":-100,"maximum":100},"blur":{"default":16,"type":"integer","minimum":0,"maximum":200},"spread":{"default":0,"type":"integer","minimum":-100,"maximum":100},"color":{"default":"#000000","type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"opacity":{"default":20,"type":"integer","minimum":0,"maximum":100}}},{"type":"null"}]}},"required":["type","id","src"]},{"type":"object","properties":{"type":{"type":"string","const":"divider"},"id":{"type":"string","minLength":1,"maxLength":40},"padding":{"default":{"top":10,"right":25,"bottom":10,"left":25},"type":"object","properties":{"top":{"type":"integer","minimum":0,"maximum":200},"right":{"type":"integer","minimum":0,"maximum":200},"bottom":{"type":"integer","minimum":0,"maximum":200},"left":{"type":"integer","minimum":0,"maximum":200}},"required":["top","right","bottom","left"]},"backgroundColor":{"default":null,"anyOf":[{"type":"string","maxLength":400},{"type":"null"}]},"hideOn":{"default":null,"anyOf":[{"type":"string","enum":["mobile","desktop"]},{"type":"null"}]},"color":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"thickness":{"default":1,"type":"integer","minimum":0,"maximum":20},"style":{"default":"solid","type":"string","enum":["solid","dashed","dotted"]},"width":{"default":100,"type":"integer","minimum":5,"maximum":100},"align":{"default":"center","type":"string","enum":["left","center","right"]},"shadow":{"default":null,"anyOf":[{"type":"object","properties":{"x":{"default":0,"type":"integer","minimum":-100,"maximum":100},"y":{"default":4,"type":"integer","minimum":-100,"maximum":100},"blur":{"default":16,"type":"integer","minimum":0,"maximum":200},"spread":{"default":0,"type":"integer","minimum":-100,"maximum":100},"color":{"default":"#000000","type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"opacity":{"default":20,"type":"integer","minimum":0,"maximum":100}}},{"type":"null"}]}},"required":["type","id"]},{"type":"object","properties":{"type":{"type":"string","const":"spacer"},"id":{"type":"string","minLength":1,"maxLength":40},"padding":{"default":{"top":10,"right":25,"bottom":10,"left":25},"type":"object","properties":{"top":{"type":"integer","minimum":0,"maximum":200},"right":{"type":"integer","minimum":0,"maximum":200},"bottom":{"type":"integer","minimum":0,"maximum":200},"left":{"type":"integer","minimum":0,"maximum":200}},"required":["top","right","bottom","left"]},"backgroundColor":{"default":null,"anyOf":[{"type":"string","maxLength":400},{"type":"null"}]},"hideOn":{"default":null,"anyOf":[{"type":"string","enum":["mobile","desktop"]},{"type":"null"}]},"height":{"default":24,"type":"integer","minimum":0,"maximum":400},"shadow":{"default":null,"anyOf":[{"type":"object","properties":{"x":{"default":0,"type":"integer","minimum":-100,"maximum":100},"y":{"default":4,"type":"integer","minimum":-100,"maximum":100},"blur":{"default":16,"type":"integer","minimum":0,"maximum":200},"spread":{"default":0,"type":"integer","minimum":-100,"maximum":100},"color":{"default":"#000000","type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"opacity":{"default":20,"type":"integer","minimum":0,"maximum":100}}},{"type":"null"}]}},"required":["type","id"]},{"type":"object","properties":{"type":{"type":"string","const":"social"},"id":{"type":"string","minLength":1,"maxLength":40},"padding":{"default":{"top":10,"right":25,"bottom":10,"left":25},"type":"object","properties":{"top":{"type":"integer","minimum":0,"maximum":200},"right":{"type":"integer","minimum":0,"maximum":200},"bottom":{"type":"integer","minimum":0,"maximum":200},"left":{"type":"integer","minimum":0,"maximum":200}},"required":["top","right","bottom","left"]},"backgroundColor":{"default":null,"anyOf":[{"type":"string","maxLength":400},{"type":"null"}]},"hideOn":{"default":null,"anyOf":[{"type":"string","enum":["mobile","desktop"]},{"type":"null"}]},"links":{"maxItems":10,"type":"array","items":{"type":"object","properties":{"network":{"type":"string","enum":["facebook","instagram","linkedin","x","youtube","tiktok","whatsapp","threads","discord","pinterest","github","phone","web"]},"url":{"type":"string","maxLength":2000}},"required":["network","url"]}},"iconSize":{"default":28,"type":"integer","minimum":0,"maximum":64},"gap":{"default":8,"type":"integer","minimum":0,"maximum":40},"iconStyle":{"default":"filled","type":"string","enum":["filled","plain"]},"iconColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"iconRadius":{"default":4,"type":"integer","minimum":0,"maximum":32},"align":{"default":"center","type":"string","enum":["left","center","right"]},"shadow":{"default":null,"anyOf":[{"type":"object","properties":{"x":{"default":0,"type":"integer","minimum":-100,"maximum":100},"y":{"default":4,"type":"integer","minimum":-100,"maximum":100},"blur":{"default":16,"type":"integer","minimum":0,"maximum":200},"spread":{"default":0,"type":"integer","minimum":-100,"maximum":100},"color":{"default":"#000000","type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"opacity":{"default":20,"type":"integer","minimum":0,"maximum":100}}},{"type":"null"}]}},"required":["type","id","links"]},{"type":"object","properties":{"type":{"type":"string","const":"catalog"},"id":{"type":"string","minLength":1,"maxLength":40},"padding":{"default":{"top":10,"right":25,"bottom":10,"left":25},"type":"object","properties":{"top":{"type":"integer","minimum":0,"maximum":200},"right":{"type":"integer","minimum":0,"maximum":200},"bottom":{"type":"integer","minimum":0,"maximum":200},"left":{"type":"integer","minimum":0,"maximum":200}},"required":["top","right","bottom","left"]},"backgroundColor":{"default":null,"anyOf":[{"type":"string","maxLength":400},{"type":"null"}]},"hideOn":{"default":null,"anyOf":[{"type":"string","enum":["mobile","desktop"]},{"type":"null"}]},"items":{"maxItems":12,"type":"array","items":{"type":"object","properties":{"kind":{"type":"string","enum":["service","package"]},"id":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},"url":{"default":"","type":"string","maxLength":2000}},"required":["kind","id"]}},"layout":{"default":"grid","type":"string","enum":["grid","list"]},"columns":{"default":2,"anyOf":[{"type":"number","const":1},{"type":"number","const":2},{"type":"number","const":3}]},"gap":{"default":16,"type":"integer","minimum":0,"maximum":40},"currency":{"default":null,"anyOf":[{"type":"string","pattern":"^[A-Z]{3}$"},{"type":"null"}]},"textAlign":{"default":"left","type":"string","enum":["left","center","right"]},"fontFamily":{"default":null,"anyOf":[{"type":"string","maxLength":60,"pattern":"^[\\p{L}\\p{N} '-]+$"},{"type":"null"}]},"cardColor":{"default":null,"anyOf":[{"type":"string","maxLength":400},{"type":"null"}]},"cardBorderColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"cardBorderWidth":{"default":1,"type":"integer","minimum":0,"maximum":10},"cardRadius":{"default":8,"type":"integer","minimum":0,"maximum":40},"cardPadding":{"default":16,"type":"integer","minimum":0,"maximum":60},"showImage":{"default":true,"type":"boolean"},"imageRatio":{"default":"square","type":"string","enum":["square","landscape","portrait","original"]},"imageRadius":{"default":4,"type":"integer","minimum":0,"maximum":40},"nameFontFamily":{"default":null,"anyOf":[{"type":"string","maxLength":60,"pattern":"^[\\p{L}\\p{N} '-]+$"},{"type":"null"}]},"nameFontSize":{"default":18,"type":"integer","minimum":0,"maximum":48},"nameFontWeight":{"default":700,"type":"integer","minimum":100,"maximum":900},"nameColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"showDescription":{"default":true,"type":"boolean"},"descriptionLength":{"default":120,"type":"integer","minimum":20,"maximum":600},"descriptionFontSize":{"default":14,"type":"integer","minimum":0,"maximum":32},"descriptionColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"showPrice":{"default":true,"type":"boolean"},"showOriginalPrice":{"default":true,"type":"boolean"},"priceFontSize":{"default":18,"type":"integer","minimum":0,"maximum":48},"priceFontWeight":{"default":700,"type":"integer","minimum":100,"maximum":900},"priceColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"showButton":{"default":true,"type":"boolean"},"buttonLabel":{"default":"","type":"string","maxLength":80},"buttonUrl":{"default":"","type":"string","maxLength":2000},"linkTo":{"default":"item","type":"string","enum":["item","catalogPage"]},"catalogPageId":{"default":null,"anyOf":[{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},{"type":"null"}]},"buttonColor":{"default":null,"anyOf":[{"type":"string","maxLength":400},{"type":"null"}]},"buttonTextColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"buttonFontSize":{"default":14,"type":"integer","minimum":0,"maximum":32},"buttonRadius":{"default":6,"type":"integer","minimum":0,"maximum":40},"buttonFullWidth":{"default":true,"type":"boolean"},"shadow":{"default":null,"anyOf":[{"type":"object","properties":{"x":{"default":0,"type":"integer","minimum":-100,"maximum":100},"y":{"default":4,"type":"integer","minimum":-100,"maximum":100},"blur":{"default":16,"type":"integer","minimum":0,"maximum":200},"spread":{"default":0,"type":"integer","minimum":-100,"maximum":100},"color":{"default":"#000000","type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"opacity":{"default":20,"type":"integer","minimum":0,"maximum":100}}},{"type":"null"}]},"hover":{"default":null,"anyOf":[{"type":"object","properties":{"duration":{"default":200,"type":"integer","minimum":0,"maximum":3000},"easing":{"default":"ease","type":"string","enum":["ease","ease-in","ease-out","ease-in-out","linear"]},"style":{"default":{},"type":"object","propertyNames":{"type":"string"},"additionalProperties":{}}}},{"type":"null"}]}},"required":["type","id","items"]},{"type":"object","properties":{"type":{"type":"string","const":"video"},"id":{"type":"string","minLength":1,"maxLength":40},"padding":{"default":{"top":10,"right":25,"bottom":10,"left":25},"type":"object","properties":{"top":{"type":"integer","minimum":0,"maximum":200},"right":{"type":"integer","minimum":0,"maximum":200},"bottom":{"type":"integer","minimum":0,"maximum":200},"left":{"type":"integer","minimum":0,"maximum":200}},"required":["top","right","bottom","left"]},"backgroundColor":{"default":null,"anyOf":[{"type":"string","maxLength":400},{"type":"null"}]},"hideOn":{"default":null,"anyOf":[{"type":"string","enum":["mobile","desktop"]},{"type":"null"}]},"url":{"type":"string","maxLength":500},"title":{"default":"","type":"string","maxLength":200},"ratio":{"default":"16:9","type":"string","enum":["16:9","4:3","1:1","9:16"]},"width":{"default":100,"type":"integer","minimum":20,"maximum":100},"align":{"default":"center","type":"string","enum":["left","center","right"]},"radius":{"default":8,"type":"integer","minimum":0,"maximum":60},"shadow":{"default":null,"anyOf":[{"type":"object","properties":{"x":{"default":0,"type":"integer","minimum":-100,"maximum":100},"y":{"default":4,"type":"integer","minimum":-100,"maximum":100},"blur":{"default":16,"type":"integer","minimum":0,"maximum":200},"spread":{"default":0,"type":"integer","minimum":-100,"maximum":100},"color":{"default":"#000000","type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"opacity":{"default":20,"type":"integer","minimum":0,"maximum":100}}},{"type":"null"}]}},"required":["type","id","url"]},{"type":"object","properties":{"type":{"type":"string","const":"form"},"id":{"type":"string","minLength":1,"maxLength":40},"padding":{"default":{"top":10,"right":25,"bottom":10,"left":25},"type":"object","properties":{"top":{"type":"integer","minimum":0,"maximum":200},"right":{"type":"integer","minimum":0,"maximum":200},"bottom":{"type":"integer","minimum":0,"maximum":200},"left":{"type":"integer","minimum":0,"maximum":200}},"required":["top","right","bottom","left"]},"backgroundColor":{"default":null,"anyOf":[{"type":"string","maxLength":400},{"type":"null"}]},"hideOn":{"default":null,"anyOf":[{"type":"string","enum":["mobile","desktop"]},{"type":"null"}]},"formId":{"default":null,"anyOf":[{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},{"type":"null"}]},"fieldsOnly":{"default":false,"type":"boolean"},"pageTheme":{"default":false,"type":"boolean"},"shadow":{"default":null,"anyOf":[{"type":"object","properties":{"x":{"default":0,"type":"integer","minimum":-100,"maximum":100},"y":{"default":4,"type":"integer","minimum":-100,"maximum":100},"blur":{"default":16,"type":"integer","minimum":0,"maximum":200},"spread":{"default":0,"type":"integer","minimum":-100,"maximum":100},"color":{"default":"#000000","type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"opacity":{"default":20,"type":"integer","minimum":0,"maximum":100}}},{"type":"null"}]}},"required":["type","id"]},{"type":"object","properties":{"type":{"type":"string","const":"card"},"id":{"type":"string","minLength":1,"maxLength":40},"padding":{"default":{"top":10,"right":25,"bottom":10,"left":25},"type":"object","properties":{"top":{"type":"integer","minimum":0,"maximum":200},"right":{"type":"integer","minimum":0,"maximum":200},"bottom":{"type":"integer","minimum":0,"maximum":200},"left":{"type":"integer","minimum":0,"maximum":200}},"required":["top","right","bottom","left"]},"backgroundColor":{"default":null,"anyOf":[{"type":"string","maxLength":400},{"type":"null"}]},"hideOn":{"default":null,"anyOf":[{"type":"string","enum":["mobile","desktop"]},{"type":"null"}]},"src":{"type":"string","maxLength":2000},"alt":{"default":"","type":"string","maxLength":300},"imagePosition":{"default":"left","type":"string","enum":["top","left","right"]},"imageWidth":{"default":40,"type":"integer","minimum":20,"maximum":70},"imageRatio":{"default":"landscape","type":"string","enum":["original","square","landscape","portrait"]},"imageRadius":{"default":8,"type":"integer","minimum":0,"maximum":200},"imageBleed":{"default":false,"type":"boolean"},"title":{"default":"","type":"string","maxLength":200},"html":{"default":"","type":"string","maxLength":20000},"url":{"default":"","type":"string","maxLength":2000},"titleFontSize":{"default":20,"type":"integer","minimum":10,"maximum":72},"titleColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"textColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"fontFamily":{"default":null,"anyOf":[{"type":"string","maxLength":60,"pattern":"^[\\p{L}\\p{N} '-]+$"},{"type":"null"}]},"textAlign":{"default":"left","type":"string","enum":["left","center","right"]},"verticalAlign":{"default":"middle","type":"string","enum":["top","middle"]},"cardColor":{"default":null,"anyOf":[{"type":"string","maxLength":400},{"type":"null"}]},"borderColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"borderWidth":{"default":1,"type":"integer","minimum":0,"maximum":10},"radius":{"default":12,"type":"integer","minimum":0,"maximum":60},"cardPadding":{"default":16,"type":"integer","minimum":0,"maximum":80},"gap":{"default":16,"type":"integer","minimum":0,"maximum":80},"shadow":{"default":null,"anyOf":[{"type":"object","properties":{"x":{"default":0,"type":"integer","minimum":-100,"maximum":100},"y":{"default":4,"type":"integer","minimum":-100,"maximum":100},"blur":{"default":16,"type":"integer","minimum":0,"maximum":200},"spread":{"default":0,"type":"integer","minimum":-100,"maximum":100},"color":{"default":"#000000","type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"opacity":{"default":20,"type":"integer","minimum":0,"maximum":100}}},{"type":"null"}]},"hover":{"default":null,"anyOf":[{"type":"object","properties":{"duration":{"default":200,"type":"integer","minimum":0,"maximum":3000},"easing":{"default":"ease","type":"string","enum":["ease","ease-in","ease-out","ease-in-out","linear"]},"style":{"default":{},"type":"object","propertyNames":{"type":"string"},"additionalProperties":{}}}},{"type":"null"}]}},"required":["type","id","src"]}]}},"backgroundColor":{"default":null,"anyOf":[{"type":"string","maxLength":400},{"type":"null"}]},"padding":{"default":{"top":0,"right":0,"bottom":0,"left":0},"type":"object","properties":{"top":{"type":"integer","minimum":0,"maximum":200},"right":{"type":"integer","minimum":0,"maximum":200},"bottom":{"type":"integer","minimum":0,"maximum":200},"left":{"type":"integer","minimum":0,"maximum":200}},"required":["top","right","bottom","left"]},"radius":{"default":0,"type":"integer","minimum":0,"maximum":100},"verticalAlign":{"default":"top","type":"string","enum":["top","middle","bottom"]},"shadow":{"default":null,"anyOf":[{"type":"object","properties":{"x":{"default":0,"type":"integer","minimum":-100,"maximum":100},"y":{"default":4,"type":"integer","minimum":-100,"maximum":100},"blur":{"default":16,"type":"integer","minimum":0,"maximum":200},"spread":{"default":0,"type":"integer","minimum":-100,"maximum":100},"color":{"default":"#000000","type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"opacity":{"default":20,"type":"integer","minimum":0,"maximum":100}}},{"type":"null"}]}},"required":["id","blocks"]}},"widths":{"minItems":1,"maxItems":4,"type":"array","items":{"type":"number","minimum":10,"maximum":100}},"backgroundColor":{"default":null,"anyOf":[{"type":"string","maxLength":400},{"type":"null"}]},"backgroundImage":{"default":"","type":"string","maxLength":2000},"fullWidth":{"default":false,"type":"boolean"},"padding":{"default":{"top":10,"right":0,"bottom":10,"left":0},"type":"object","properties":{"top":{"type":"integer","minimum":0,"maximum":200},"right":{"type":"integer","minimum":0,"maximum":200},"bottom":{"type":"integer","minimum":0,"maximum":200},"left":{"type":"integer","minimum":0,"maximum":200}},"required":["top","right","bottom","left"]},"radius":{"default":0,"type":"integer","minimum":0,"maximum":100},"borderColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},{"type":"null"}]},"borderWidth":{"default":0,"type":"integer","minimum":0,"maximum":10},"stackOnMobile":{"default":true,"type":"boolean"},"hideOn":{"default":null,"anyOf":[{"type":"string","enum":["mobile","desktop"]},{"type":"null"}]},"shadow":{"default":null,"anyOf":[{"type":"object","properties":{"x":{"default":0,"type":"integer","minimum":-100,"maximum":100},"y":{"default":4,"type":"integer","minimum":-100,"maximum":100},"blur":{"default":16,"type":"integer","minimum":0,"maximum":200},"spread":{"default":0,"type":"integer","minimum":-100,"maximum":100},"color":{"default":"#000000","type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"opacity":{"default":20,"type":"integer","minimum":0,"maximum":100}}},{"type":"null"}]}},"required":["id","columns","widths"]}}},"required":["rows"]},"showBranding":{"type":"boolean"},"active":{"type":"boolean"}}}}}},"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"active":{"type":"boolean"},"clicks30":{"type":"integer"},"createdAt":{"format":"date-time","type":"string"},"createdBy":{"format":"uuid","type":"string"},"description":{"type":["null","string"]},"document":{"properties":{"hero":{"properties":{"avatar":{"format":"uri","type":"string"},"avatarAlign":{"type":"string"},"avatarAlt":{"type":"string"},"avatarBorderColor":{"type":"string"},"avatarBorderWidth":{"type":"integer"},"avatarOverlap":{"type":"integer"},"avatarRadius":{"type":"integer"},"avatarShadow":{"type":"null"},"avatarShape":{"type":"string"},"avatarSize":{"type":"integer"},"buttonInset":{"type":"integer"},"buttonOpacity":{"type":"integer"},"buttonShape":{"type":"string"},"buttonSize":{"type":"integer"},"buttonTheme":{"type":"string"},"coverColor":{"type":"string"},"coverHeight":{"type":"integer"},"coverImage":{"format":"uri","type":"string"},"coverImageStyle":{"properties":{"attachment":{"type":"string"},"blend":{"type":"string"},"gapX":{"type":"integer"},"gapY":{"type":"integer"},"repeat":{"type":"string"},"size":{"type":"string"},"sizeValue":{"type":"integer"},"x":{"type":"integer"},"y":{"type":"integer"}},"required":["x","y","gapX","gapY","size","blend","repeat","sizeValue","attachment"],"type":"object"},"fade":{"type":"boolean"},"fadeColor":{"type":"string"},"fadeHeight":{"type":"integer"},"left":{"items":{"properties":{"action":{"type":"string"},"icon":{"type":"string"},"id":{"type":"string"},"label":{"type":"string"},"url":{"format":"uri","type":"string"}},"required":["id","url","icon","label","action"],"type":"object"},"type":"array"},"padding":{"properties":{"bottom":{"type":"integer"},"left":{"type":"integer"},"right":{"type":"integer"},"top":{"type":"integer"}},"required":["top","left","right","bottom"],"type":"object"},"radius":{"type":"integer"},"radiusBottom":{"type":"integer"},"radiusTop":{"type":"integer"},"right":{"items":{"properties":{"action":{"type":"string"},"icon":{"type":"string"},"id":{"type":"string"},"label":{"type":"string"},"url":{"type":"string"}},"required":["id","url","icon","label","action"],"type":"object"},"type":"array"}},"required":["fade","left","right","avatar","radius","padding","avatarAlt","fadeColor","radiusTop","avatarSize","buttonSize","coverColor","coverImage","fadeHeight","avatarAlign","avatarShape","buttonInset","buttonShape","buttonTheme","coverHeight","avatarRadius","avatarShadow","radiusBottom","avatarOverlap","buttonOpacity","coverImageStyle","avatarBorderColor","avatarBorderWidth"],"type":["null","object"]},"rows":{"items":{"properties":{"backgroundColor":{"type":["null","string"]},"backgroundImage":{"type":"string"},"borderColor":{"type":"null"},"borderWidth":{"type":"integer"},"columns":{"items":{"properties":{"backgroundColor":{"type":["null","string"]},"blocks":{"items":{"properties":{"align":{"type":"string"},"alt":{"type":"string"},"backgroundColor":{"type":"null"},"borderColor":{"type":"null"},"borderWidth":{"type":"integer"},"buttonColor":{"type":["null","string"]},"cardColor":{"type":"null"},"cardPadding":{"type":"integer"},"color":{"type":["null","string"]},"fieldsOnly":{"type":"boolean"},"fontFamily":{"type":"null"},"fontSize":{"type":["integer","null"]},"fontWeight":{"type":"integer"},"formId":{"format":"uuid","type":["null","string"]},"fullWidth":{"type":"boolean"},"gap":{"type":"integer"},"hideOn":{"type":"null"},"hover":{"properties":{"duration":{"type":"integer"},"easing":{"type":"string"},"style":{}},"required":["style","easing","duration"],"type":["null","object"]},"html":{"type":"string"},"iconColor":{"type":"string"},"iconRadius":{"type":"integer"},"iconSize":{"type":"integer"},"iconStyle":{"type":"string"},"id":{"type":"string"},"imageBleed":{"type":"boolean"},"imagePosition":{"type":"string"},"imageRadius":{"type":"integer"},"imageRatio":{"type":"string"},"imageWidth":{"type":"integer"},"innerPadding":{"properties":{"horizontal":{"type":"integer"},"vertical":{"type":"integer"}},"required":["vertical","horizontal"],"type":"object"},"label":{"type":"string"},"letterSpacing":{"type":"integer"},"level":{"type":"integer"},"lineHeight":{"type":"null"},"links":{"type":"array"},"padding":{"properties":{"bottom":{"type":"integer"},"left":{"type":"integer"},"right":{"type":"integer"},"top":{"type":"integer"}},"required":["top","left","right","bottom"],"type":"object"},"pageTheme":{"type":"boolean"},"radius":{"type":"integer"},"ratio":{"type":"string"},"shadow":{"properties":{"blur":{"type":"integer"},"color":{"type":"string"},"opacity":{"type":"integer"},"spread":{"type":"integer"},"x":{"type":"integer"},"y":{"type":"integer"}},"required":["x","y","blur","color","spread","opacity"],"type":["null","object"]},"src":{"format":"uri","type":"string"},"textAlign":{"type":"string"},"textColor":{"type":["null","string"]},"title":{"type":"string"},"titleColor":{"type":"null"},"titleFontSize":{"type":"integer"},"type":{"type":"string"},"url":{"format":"uri","type":"string"},"verticalAlign":{"type":"string"},"width":{"type":"integer"}},"required":["id","type","hideOn","shadow","padding","backgroundColor"],"type":"object"},"type":"array"},"id":{"type":"string"},"padding":{"properties":{"bottom":{"type":"integer"},"left":{"type":"integer"},"right":{"type":"integer"},"top":{"type":"integer"}},"required":["top","left","right","bottom"],"type":"object"},"radius":{"type":"integer"},"shadow":{"properties":{"blur":{"type":"integer"},"color":{"type":"string"},"opacity":{"type":"integer"},"spread":{"type":"integer"},"x":{"type":"integer"},"y":{"type":"integer"}},"required":["x","y","blur","color","spread","opacity"],"type":["null","object"]},"verticalAlign":{"type":"string"}},"required":["id","blocks","radius","shadow","padding","verticalAlign","backgroundColor"],"type":"object"},"type":"array"},"fullWidth":{"type":"boolean"},"hideOn":{"type":"null"},"id":{"type":"string"},"padding":{"properties":{"bottom":{"type":"integer"},"left":{"type":"integer"},"right":{"type":"integer"},"top":{"type":"integer"}},"required":["top","left","right","bottom"],"type":"object"},"radius":{"type":"integer"},"shadow":{"properties":{"blur":{"type":"integer"},"color":{"type":"string"},"opacity":{"type":"integer"},"spread":{"type":"integer"},"x":{"type":"integer"},"y":{"type":"integer"}},"required":["x","y","blur","color","spread","opacity"],"type":["null","object"]},"stackOnMobile":{"type":"boolean"},"widths":{"items":{"type":"integer"},"type":"array"}},"required":["id","hideOn","radius","shadow","widths","columns","padding","fullWidth","borderColor","borderWidth","stackOnMobile","backgroundColor","backgroundImage"],"type":"object"},"type":"array"},"settings":{"properties":{"backdropColor":{"type":"string"},"backdropImage":{"type":"string"},"backdropImageStyle":{"properties":{"attachment":{"type":"string"},"blend":{"type":"string"},"gapX":{"type":"integer"},"gapY":{"type":"integer"},"repeat":{"type":"string"},"size":{"type":"string"},"sizeValue":{"type":"integer"},"x":{"type":"integer"},"y":{"type":"integer"}},"required":["x","y","gapX","gapY","size","blend","repeat","sizeValue","attachment"],"type":"object"},"contentColor":{"type":"string"},"contentCorners":{"properties":{"bottomLeft":{"type":"integer"},"bottomRight":{"type":"integer"},"topLeft":{"type":"integer"},"topRight":{"type":"integer"}},"required":["topLeft","topRight","bottomLeft","bottomRight"],"type":["null","object"]},"contentImage":{"type":"string"},"contentImageStyle":{"properties":{"attachment":{"type":"string"},"blend":{"type":"string"},"gapX":{"type":"integer"},"gapY":{"type":"integer"},"repeat":{"type":"string"},"size":{"type":"string"},"sizeValue":{"type":"integer"},"x":{"type":"integer"},"y":{"type":"integer"}},"required":["x","y","gapX","gapY","size","blend","repeat","sizeValue","attachment"],"type":"object"},"fontFamily":{"type":"string"},"fontSize":{"type":"integer"},"headingColor":{"type":"string"},"headingFontFamily":{"type":"string"},"lineHeight":{"type":"number"},"linkColor":{"type":"string"},"onPrimaryColor":{"type":"string"},"outerPadding":{"type":"integer"},"primaryColor":{"type":"string"},"radius":{"type":"integer"},"textColor":{"type":"string"},"width":{"type":"integer"}},"required":["width","radius","fontSize","linkColor","textColor","fontFamily","lineHeight","contentColor","contentImage","headingColor","outerPadding","primaryColor","backdropColor","backdropImage","contentCorners","onPrimaryColor","contentImageStyle","headingFontFamily","backdropImageStyle"],"type":"object"},"version":{"type":"integer"}},"required":["hero","rows","version","settings"],"type":"object"},"id":{"format":"uuid","type":"string"},"name":{"type":"string"},"showBranding":{"type":"boolean"},"slug":{"type":"string"},"title":{"type":"string"},"updatedAt":{"format":"date-time","type":"string"},"updatedBy":{"format":"uuid","type":"string"},"url":{"format":"uri","type":"string"},"views30":{"type":"integer"}},"required":["id","slug","name","title","description","document","showBranding","active","createdBy","updatedBy","createdAt","updatedAt","url","views30","clicks30"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/microsites/{id}/stats":{"get":{"operationId":"GET /v1/microsites/{id}/stats","summary":"Views of the microsite and clicks, per day.","tags":["microsites"],"x-feature":"microsites","x-action":"read","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}},{"name":"days","in":"query","required":false,"schema":{"default":30,"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"blocks":{"items":{"properties":{"clicks":{"type":"integer"},"id":{"type":"string"},"label":{"type":"string"},"type":{"type":"string"}},"required":["id","type","label","clicks"],"type":"object"},"type":"array"},"days":{"type":"integer"},"series":{"items":{"properties":{"clicks":{"type":"integer"},"day":{"format":"date","type":"string"},"views":{"type":"integer"}},"required":["day","views","clicks"],"type":"object"},"type":"array"},"sources":{"items":{"properties":{"source":{"type":"string"},"views":{"type":"integer"}},"required":["source","views"],"type":"object"},"type":"array"},"totals":{"properties":{"clickRate":{"type":["integer","null"]},"clicks":{"type":"integer"},"views":{"type":"integer"}},"required":["views","clicks","clickRate"],"type":"object"}},"required":["days","totals","series","blocks","sources"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/microsites/slug-check":{"get":{"operationId":"GET /v1/microsites/slug-check","summary":"Whether an address is free for the microsite.","tags":["microsites"],"x-feature":"microsites","x-action":"read","parameters":[{"name":"slug","in":"query","required":true,"schema":{"type":"string","maxLength":60}},{"name":"exclude","in":"query","required":false,"schema":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/organization":{"get":{"operationId":"GET /v1/organization","summary":"The organization: name, plan, settings and look.","tags":["organization"],"x-feature":"organization","x-action":"read","responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"billing":{"properties":{"billingConfigured":{"type":"boolean"},"limits":{"properties":{"ads":{"type":"boolean"},"apiKeys":{"type":"integer"},"apiRateAddons":{"type":"boolean"},"apiRequestsPerMinute":{"type":"integer"},"appointmentsPerMonth":{"type":["integer","null"]},"approvalsPerMonth":{"type":"integer"},"bookingPagesPerMember":{"type":"integer"},"calendarEvents":{"type":"integer"},"catalogCurrencies":{"type":"boolean"},"catalogImagesPerItem":{"type":"integer"},"catalogPages":{"type":"integer"},"catalogRequestNotes":{"type":"boolean"},"catalogRequestsPerMonth":{"type":"integer"},"clientPortal":{"type":"boolean"},"companies":{"type":"integer"},"contactEventsPerMonth":{"type":"integer"},"contacts":{"type":"integer"},"contactsPerList":{"type":"integer"},"contractSignaturesPerMonth":{"type":"integer"},"contracts":{"type":"integer"},"customDealTheme":{"type":"boolean"},"customFavicon":{"type":"boolean"},"customPropertiesPerEntity":{"type":"integer"},"dealsPerMonth":{"type":"integer"},"documentLanguages":{"type":"boolean"},"duplicateDetection":{"type":"boolean"},"emailBranding":{"type":"string"},"emailDomains":{"type":"integer"},"emailPacks":{"type":"boolean"},"emailSavedBlocks":{"type":"integer"},"emailSignatures":{"type":"integer"},"emailsPerMonth":{"type":"integer"},"externalAi":{"type":"boolean"},"firmadoAi":{"type":"boolean"},"formActions":{"type":"boolean"},"formSubmissionsPerMonth":{"type":"integer"},"formWebhooks":{"type":"boolean"},"forms":{"type":"integer"},"formsApi":{"type":"boolean"},"googleBusinessLocations":{"type":"integer"},"googleCalendarBusy":{"type":"boolean"},"googleCalendarPush":{"type":"boolean"},"includedSeats":{"type":"integer"},"invoiceReminders":{"type":"boolean"},"invoicesPerMonth":{"type":"integer"},"linkButtonStyles":{"type":"boolean"},"linkIcons":{"type":"boolean"},"linkPageBranding":{"type":"boolean"},"linkPages":{"type":"integer"},"linksPerPage":{"type":"integer"},"lists":{"type":"integer"},"loyaltyRewards":{"type":"integer"},"marketingPosts":{"type":"integer"},"maxSeats":{"type":"integer"},"mcp":{"type":"boolean"},"messagingAccountsPerChannel":{"type":"integer"},"messagingConversationsPerMonth":{"type":"integer"},"messagingMessagesPerMonth":{"type":"integer"},"microsites":{"type":"integer"},"notificationEmails":{"type":"boolean"},"packages":{"type":"integer"},"paymentFeePercent":{"type":"integer"},"projects":{"type":"integer"},"propertyHistory":{"type":"integer"},"publicDomains":{"type":"integer"},"qrCodes":{"type":"integer"},"services":{"type":"integer"},"shareImages":{"type":"string"},"sharedFiles":{"type":"integer"},"shortLinks":{"type":"integer"},"signerEmailVerification":{"type":"boolean"},"smartLists":{"type":"boolean"},"socialPostsPerMonth":{"type":"integer"},"storageBytes":{"type":"integer"},"stripePayments":{"type":"boolean"},"surveyInvitesPerMonth":{"type":"integer"},"surveys":{"type":"integer"},"tags":{"type":"integer"},"tagsPerContact":{"type":"integer"},"teamBookingPages":{"type":"boolean"},"webhooks":{"type":"integer"}},"required":["ads","apiKeys","apiRateAddons","apiRequestsPerMinute","appointmentsPerMonth","approvalsPerMonth","bookingPagesPerMember","calendarEvents","catalogCurrencies","catalogImagesPerItem","catalogPages","catalogRequestNotes","catalogRequestsPerMonth","clientPortal","companies","contactEventsPerMonth","contacts","contactsPerList","contractSignaturesPerMonth","contracts","customDealTheme","customFavicon","customPropertiesPerEntity","dealsPerMonth","documentLanguages","duplicateDetection","emailBranding","emailDomains","emailPacks","emailSavedBlocks","emailSignatures","emailsPerMonth","externalAi","firmadoAi","formActions","formSubmissionsPerMonth","formWebhooks","forms","formsApi","googleBusinessLocations","googleCalendarBusy","googleCalendarPush","includedSeats","invoiceReminders","invoicesPerMonth","linkButtonStyles","linkIcons","linkPageBranding","linkPages","linksPerPage","lists","loyaltyRewards","marketingPosts","maxSeats","mcp","messagingAccountsPerChannel","messagingConversationsPerMonth","messagingMessagesPerMonth","microsites","notificationEmails","packages","paymentFeePercent","projects","propertyHistory","publicDomains","qrCodes","services","shareImages","sharedFiles","shortLinks","signerEmailVerification","smartLists","socialPostsPerMonth","storageBytes","stripePayments","surveyInvitesPerMonth","surveys","tags","tagsPerContact","teamBookingPages","webhooks"],"type":"object"},"plan":{"type":"string"},"seats":{"properties":{"limit":{"type":"integer"},"pendingInvitations":{"type":"integer"},"used":{"type":"integer"}},"required":["limit","pendingInvitations","used"],"type":"object"},"status":{"type":"string"},"subscription":{"properties":{"cancelAtPeriodEnd":{"type":"boolean"},"currency":{"type":"null"},"currentPeriodEnd":{"type":"null"},"seats":{"type":["integer","null"]},"status":{"type":"string"}},"required":["cancelAtPeriodEnd","currency","currentPeriodEnd","seats","status"],"type":["null","object"]}},"required":["billingConfigured","limits","plan","seats","status","subscription"],"type":"object"},"blockedAt":{"type":"null"},"blockedReason":{"type":"null"},"createdAt":{"format":"date-time","type":"string"},"dataRegion":{"type":"string"},"defaultLanguage":{"type":"string"},"deleteAfter":{"type":"null"},"deletedAt":{"type":"null"},"id":{"format":"uuid","type":"string"},"logo":{"format":"uri","type":["null","string"]},"name":{"type":"string"},"plan":{"type":"string"},"role":{"type":"string"},"settings":{"properties":{"autoMergeContacts":{"type":"boolean"},"bookingTemplate":{"type":["null","string"]},"bookingTheme":{"properties":{"primaryColor":{"type":"string"}},"required":["primaryColor"],"type":["null","object"]},"catalogTemplate":{"type":"null"},"catalogTheme":{"type":"null"},"dealLogoUrl":{"type":"null"},"defaultCurrency":{"type":"string"},"defaultDealTemplate":{"type":["null","string"]},"defaultDealTheme":{"properties":{"primaryColor":{"type":"string"}},"required":["primaryColor"],"type":["null","object"]},"emailTemplate":{"type":"null"},"emailTheme":{"type":"null"},"faviconUrl":{"type":"null"},"formTemplate":{"type":"null"},"formTheme":{"type":"null"},"invoiceTemplate":{"type":"null"},"invoiceTheme":{"type":"null"},"linkTemplate":{"type":"null"},"linkTheme":{"type":"null"},"portalTemplate":{"type":"null"},"portalTheme":{"type":"null"},"surveyTemplate":{"type":"null"},"surveyTheme":{"type":"null"},"theme":{"properties":{},"required":[],"type":"object"},"themeTemplate":{"type":"string"}},"required":["autoMergeContacts","bookingTemplate","bookingTheme","catalogTemplate","catalogTheme","dealLogoUrl","defaultCurrency","defaultDealTemplate","defaultDealTheme","emailTemplate","emailTheme","faviconUrl","formTemplate","formTheme","invoiceTemplate","invoiceTheme","linkTemplate","linkTheme","portalTemplate","portalTheme","surveyTemplate","surveyTheme","theme","themeTemplate"],"type":"object"},"slug":{"type":"string"},"status":{"type":"string"},"timezone":{"type":"string"}},"required":["billing","blockedAt","blockedReason","createdAt","dataRegion","defaultLanguage","deleteAfter","deletedAt","id","logo","name","plan","role","settings","slug","status","timezone"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/organization/deletion":{"post":{"operationId":"POST /v1/organization/deletion","summary":"Asks to delete the organization; the owner confirms by a link sent by email.","tags":["organization"],"x-feature":"organization","x-action":"create","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"confirm":{"type":"string","minLength":1,"maxLength":200}},"required":["confirm"]}}}},"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"email":{"format":"email","type":"string"},"expiresInHours":{"type":"integer"}},"required":["email","expiresInHours"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/organization/deletion/restore":{"post":{"operationId":"POST /v1/organization/deletion/restore","summary":"Brings a deleted organization back during its grace period (on Free).","tags":["organization"],"x-feature":"organization","x-action":"create","responses":{"204":{"description":"Done, with no content."},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/organization/email-preview":{"post":{"operationId":"POST /v1/organization/email-preview","summary":"A sample email to contacts with the organization’s look, or an unsaved one.","tags":["organization"],"x-feature":"organization","x-action":"create","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"emailTemplate":{"anyOf":[{"type":"string","enum":["classic","modern","minimal","bold"]},{"type":"null"}]},"emailTheme":{"anyOf":[{"type":"object","properties":{"primaryColor":{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"accentColor":{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"backgroundColor":{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"textColor":{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"headingFont":{"type":"string","pattern":"^[A-Za-z0-9 ]{1,60}$"},"bodyFont":{"type":"string","pattern":"^[A-Za-z0-9 ]{1,60}$"},"coverImageUrl":{"type":"string","maxLength":2000,"format":"uri"},"cornerRadius":{"type":"string","enum":["none","small","medium","large"]}},"additionalProperties":false},{"type":"null"}]},"template":{"type":"string","enum":["verify-email","reset-password","organization-invitation","notification","admin-sign-in","confirm-deletion","appointment.requested","appointment.rescheduled","appointment.confirmed","appointment.declined","deal.signature_verification","deal.acceptance_copy","deal.question_answer","invoice.sent","invoice.receipt","invoice.reminder","approval.request","approval.verification","approval.copy","contract.request","contract.verification","contract.copy","survey.invite","survey.reminder","file.download","client-portal.link","loyalty.card"]}}}}}},"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"html":{"type":"string"},"subject":{"type":"string"},"text":{"type":"string"}},"required":["subject","html","text"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/organization/favicon":{"delete":{"operationId":"DELETE /v1/organization/favicon","summary":"Removes the public pages’ browser tab icon.","tags":["organization"],"x-feature":"organization","x-action":"delete","responses":{"204":{"description":"Done, with no content."},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"post":{"operationId":"POST /v1/organization/favicon","summary":"Uploads the browser tab icon of the public pages.","tags":["organization"],"x-feature":"organization","x-action":"create","requestBody":{"required":true,"content":{"multipart/form-data":{"schema":{"type":"object","required":["file"],"properties":{"file":{"type":"string","format":"binary"}}}}}},"responses":{"201":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"autoMergeContacts":{"type":"boolean"},"bookingTemplate":{"type":"null"},"bookingTheme":{"type":"null"},"catalogTemplate":{"type":"null"},"catalogTheme":{"type":"null"},"dealLogoUrl":{"type":"null"},"defaultCurrency":{"type":"string"},"defaultDealTemplate":{"type":"null"},"defaultDealTheme":{"type":"null"},"emailTemplate":{"type":"null"},"emailTheme":{"type":"null"},"faviconUrl":{"format":"uri","type":"string"},"formTemplate":{"type":"null"},"formTheme":{"type":"null"},"invoiceTemplate":{"type":"null"},"invoiceTheme":{"type":"null"},"linkTemplate":{"type":"null"},"linkTheme":{"type":"null"},"portalTemplate":{"type":"null"},"portalTheme":{"type":"null"},"surveyTemplate":{"type":"null"},"surveyTheme":{"type":"null"},"theme":{"properties":{},"required":[],"type":"object"},"themeTemplate":{"type":"string"}},"required":["themeTemplate","theme","defaultDealTemplate","defaultDealTheme","defaultCurrency","bookingTemplate","bookingTheme","dealLogoUrl","faviconUrl","autoMergeContacts","invoiceTemplate","invoiceTheme","formTemplate","formTheme","surveyTemplate","surveyTheme","linkTemplate","linkTheme","catalogTemplate","catalogTheme","portalTemplate","portalTheme","emailTemplate","emailTheme"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/organization/icon":{"delete":{"operationId":"DELETE /v1/organization/icon","summary":"Removes the organization’s icon.","tags":["organization"],"x-feature":"organization","x-action":"delete","responses":{"204":{"description":"Done, with no content."},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"post":{"operationId":"POST /v1/organization/icon","summary":"Uploads the organization’s icon.","tags":["organization"],"x-feature":"organization","x-action":"create","requestBody":{"required":true,"content":{"multipart/form-data":{"schema":{"type":"object","required":["file"],"properties":{"file":{"type":"string","format":"binary"}}}}}},"responses":{"201":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"logo":{"format":"uri","type":"string"}},"required":["logo"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/organization/logo":{"delete":{"operationId":"DELETE /v1/organization/logo","summary":"Removes the public pages’ logo.","tags":["organization"],"x-feature":"organization","x-action":"delete","responses":{"204":{"description":"Done, with no content."},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"post":{"operationId":"POST /v1/organization/logo","summary":"Uploads the logo of the public pages.","tags":["organization"],"x-feature":"organization","x-action":"create","requestBody":{"required":true,"content":{"multipart/form-data":{"schema":{"type":"object","required":["file"],"properties":{"file":{"type":"string","format":"binary"}}}}}},"responses":{"201":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"autoMergeContacts":{"type":"boolean"},"bookingTemplate":{"type":"null"},"bookingTheme":{"type":"null"},"catalogTemplate":{"type":"null"},"catalogTheme":{"type":"null"},"dealLogoUrl":{"format":"uri","type":"string"},"defaultCurrency":{"type":"string"},"defaultDealTemplate":{"type":"null"},"defaultDealTheme":{"type":"null"},"emailTemplate":{"type":"null"},"emailTheme":{"type":"null"},"faviconUrl":{"type":"null"},"formTemplate":{"type":"null"},"formTheme":{"type":"null"},"invoiceTemplate":{"type":"null"},"invoiceTheme":{"type":"null"},"linkTemplate":{"type":"null"},"linkTheme":{"type":"null"},"portalTemplate":{"type":"null"},"portalTheme":{"type":"null"},"surveyTemplate":{"type":"null"},"surveyTheme":{"type":"null"},"theme":{"properties":{},"required":[],"type":"object"},"themeTemplate":{"type":"string"}},"required":["autoMergeContacts","bookingTemplate","bookingTheme","catalogTemplate","catalogTheme","dealLogoUrl","defaultCurrency","defaultDealTemplate","defaultDealTheme","emailTemplate","emailTheme","faviconUrl","formTemplate","formTheme","invoiceTemplate","invoiceTheme","linkTemplate","linkTheme","portalTemplate","portalTheme","surveyTemplate","surveyTheme","theme","themeTemplate"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/organization/members":{"get":{"operationId":"GET /v1/organization/members","summary":"Lists the members with their role and status.","tags":["organization"],"x-feature":"organization","x-action":"read","responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"items":{"properties":{"accountDeleted":{"type":"boolean"},"createdAt":{"format":"date-time","type":"string"},"email":{"format":"email","type":"string"},"id":{"format":"uuid","type":"string"},"image":{"type":"null"},"name":{"type":"string"},"role":{"type":"string"},"suspended":{"type":"boolean"},"suspendedUntil":{"format":"date-time","type":["null","string"]},"userId":{"format":"uuid","type":"string"}},"required":["accountDeleted","createdAt","email","id","image","name","role","suspended","suspendedUntil","userId"],"type":"object"},"type":"array"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/organization/members/{id}/reactivate":{"post":{"operationId":"POST /v1/organization/members/{id}/reactivate","summary":"Ends a member’s suspension.","tags":["organization"],"x-feature":"organization","x-action":"create","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"accountCreatedAt":{"format":"date-time","type":"string"},"activity":{"items":{"properties":{"actor":{"properties":{"id":{"format":"uuid","type":"string"},"name":{"type":"string"}},"required":["id","name"],"type":"object"},"actorName":{"type":"string"},"createdAt":{"format":"date-time","type":"string"},"data":{"additionalProperties":{},"type":"object"},"id":{"format":"uuid","type":"string"},"ipAddress":{"type":"string"},"organizationId":{"format":"uuid","type":"string"},"type":{"type":"string"},"userAgent":{"type":"null"}},"required":["id","type","ipAddress","userAgent","data","createdAt","organizationId","actorName","actor"],"type":"object"},"type":"array"},"emailVerified":{"type":"boolean"},"member":{"properties":{"createdAt":{"format":"date-time","type":"string"},"email":{"format":"email","type":"string"},"id":{"format":"uuid","type":"string"},"image":{"type":"null"},"name":{"type":"string"},"role":{"type":"string"},"suspension":{"type":"null"},"userId":{"format":"uuid","type":"string"}},"required":["id","userId","role","createdAt","name","email","image","suspension"],"type":"object"},"password":{"properties":{"set":{"type":"boolean"},"updatedAt":{"format":"date-time","type":"string"}},"required":["set","updatedAt"],"type":"object"},"sessions":{"items":{"properties":{"createdAt":{"format":"date-time","type":"string"},"current":{"type":"boolean"},"expiresAt":{"format":"date-time","type":"string"},"id":{"format":"uuid","type":"string"},"ipAddress":{"type":"string"},"lastActiveAt":{"format":"date-time","type":"string"},"userAgent":{"type":"string"}},"required":["id","ipAddress","userAgent","createdAt","lastActiveAt","expiresAt","current"],"type":"object"},"type":"array"}},"required":["member","accountCreatedAt","emailVerified","password","sessions","activity"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/organization/members/{id}/security":{"get":{"operationId":"GET /v1/organization/members/{id}/security","summary":"A member’s password state, sessions and security activity (administrators).","tags":["organization"],"x-feature":"organization","x-action":"read","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"accountCreatedAt":{"format":"date-time","type":"string"},"activity":{"items":{"properties":{"actor":{"properties":{"id":{"format":"uuid","type":"string"},"name":{"type":"string"}},"required":["id","name"],"type":["null","object"]},"actorName":{"type":["null","string"]},"createdAt":{"format":"date-time","type":"string"},"data":{"additionalProperties":{},"type":"object"},"id":{"format":"uuid","type":"string"},"ipAddress":{"type":["null","string"]},"organizationId":{"format":"uuid","type":["null","string"]},"type":{"type":"string"},"userAgent":{"type":["null","string"]}},"required":["id","type","ipAddress","userAgent","data","createdAt","organizationId","actorName","actor"],"type":"object"},"type":"array"},"emailVerified":{"type":"boolean"},"member":{"properties":{"createdAt":{"format":"date-time","type":"string"},"email":{"format":"email","type":"string"},"id":{"format":"uuid","type":"string"},"image":{"type":"null"},"name":{"type":"string"},"role":{"type":"string"},"suspension":{"type":"null"},"userId":{"format":"uuid","type":"string"}},"required":["id","userId","role","createdAt","name","email","image","suspension"],"type":"object"},"password":{"properties":{"set":{"type":"boolean"},"updatedAt":{"format":"date-time","type":"string"}},"required":["set","updatedAt"],"type":"object"},"sessions":{"items":{"properties":{"createdAt":{"format":"date-time","type":"string"},"current":{"type":"boolean"},"expiresAt":{"format":"date-time","type":"string"},"id":{"format":"uuid","type":"string"},"ipAddress":{"type":"string"},"lastActiveAt":{"format":"date-time","type":"string"},"userAgent":{"type":"string"}},"required":["id","ipAddress","userAgent","createdAt","lastActiveAt","expiresAt","current"],"type":"object"},"type":"array"}},"required":["member","accountCreatedAt","emailVerified","password","sessions","activity"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/organization/members/{id}/sessions/{sessionId}":{"delete":{"operationId":"DELETE /v1/organization/members/{id}/sessions/{sessionId}","summary":"Signs a member out of one session.","tags":["organization"],"x-feature":"organization","x-action":"delete","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}},{"name":"sessionId","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"204":{"description":"Done, with no content."},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/organization/members/{id}/sessions/revoke-all":{"post":{"operationId":"POST /v1/organization/members/{id}/sessions/revoke-all","summary":"Signs a member out everywhere.","tags":["organization"],"x-feature":"organization","x-action":"create","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"revoked":{"type":"integer"}},"required":["revoked"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/organization/members/{id}/suspend":{"post":{"operationId":"POST /v1/organization/members/{id}/suspend","summary":"Blocks a member from this organization until a date, or until reactivated.","tags":["organization"],"x-feature":"organization","x-action":"create","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"until":{"anyOf":[{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"},{"type":"null"}]}},"required":["until"]}}}},"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"accountCreatedAt":{"format":"date-time","type":"string"},"activity":{"items":{"properties":{"actor":{"properties":{"id":{"format":"uuid","type":"string"},"name":{"type":"string"}},"required":["id","name"],"type":"object"},"actorName":{"type":"string"},"createdAt":{"format":"date-time","type":"string"},"data":{"additionalProperties":{},"type":"object"},"id":{"format":"uuid","type":"string"},"ipAddress":{"type":"string"},"organizationId":{"format":"uuid","type":"string"},"type":{"type":"string"},"userAgent":{"type":"null"}},"required":["id","type","ipAddress","userAgent","data","createdAt","organizationId","actorName","actor"],"type":"object"},"type":"array"},"emailVerified":{"type":"boolean"},"member":{"properties":{"createdAt":{"format":"date-time","type":"string"},"email":{"format":"email","type":"string"},"id":{"format":"uuid","type":"string"},"image":{"type":"null"},"name":{"type":"string"},"role":{"type":"string"},"suspension":{"properties":{"since":{"format":"date-time","type":"string"},"until":{"format":"date-time","type":["null","string"]}},"required":["since","until"],"type":"object"},"userId":{"format":"uuid","type":"string"}},"required":["id","userId","role","createdAt","name","email","image","suspension"],"type":"object"},"password":{"properties":{"set":{"type":"boolean"},"updatedAt":{"format":"date-time","type":"string"}},"required":["set","updatedAt"],"type":"object"},"sessions":{"items":{"properties":{"createdAt":{"format":"date-time","type":"string"},"current":{"type":"boolean"},"expiresAt":{"format":"date-time","type":"string"},"id":{"format":"uuid","type":"string"},"ipAddress":{"type":"string"},"lastActiveAt":{"format":"date-time","type":"string"},"userAgent":{"type":"string"}},"required":["id","ipAddress","userAgent","createdAt","lastActiveAt","expiresAt","current"],"type":"object"},"type":"array"}},"required":["member","accountCreatedAt","emailVerified","password","sessions","activity"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/organization/settings":{"patch":{"operationId":"PATCH /v1/organization/settings","summary":"Changes the organization’s settings.","tags":["organization"],"x-feature":"organization","x-action":"update","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"themeTemplate":{"type":"string","enum":["classic","modern","minimal","bold"]},"theme":{"type":"object","properties":{"primaryColor":{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"accentColor":{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"backgroundColor":{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"textColor":{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"headingFont":{"type":"string","pattern":"^[A-Za-z0-9 ]{1,60}$"},"bodyFont":{"type":"string","pattern":"^[A-Za-z0-9 ]{1,60}$"},"coverImageUrl":{"type":"string","maxLength":2000,"format":"uri"},"cornerRadius":{"type":"string","enum":["none","small","medium","large"]}},"additionalProperties":false},"defaultDealTemplate":{"anyOf":[{"type":"string","enum":["classic","modern","minimal","bold"]},{"type":"null"}]},"defaultDealTheme":{"anyOf":[{"type":"object","properties":{"primaryColor":{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"accentColor":{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"backgroundColor":{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"textColor":{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"headingFont":{"type":"string","pattern":"^[A-Za-z0-9 ]{1,60}$"},"bodyFont":{"type":"string","pattern":"^[A-Za-z0-9 ]{1,60}$"},"coverImageUrl":{"type":"string","maxLength":2000,"format":"uri"},"cornerRadius":{"type":"string","enum":["none","small","medium","large"]}},"additionalProperties":false},{"type":"null"}]},"defaultCurrency":{"type":"string","pattern":"^[A-Z]{3}$"},"bookingTemplate":{"anyOf":[{"type":"string","enum":["classic","modern","minimal","bold"]},{"type":"null"}]},"bookingTheme":{"anyOf":[{"type":"object","properties":{"primaryColor":{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"accentColor":{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"backgroundColor":{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"textColor":{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"headingFont":{"type":"string","pattern":"^[A-Za-z0-9 ]{1,60}$"},"bodyFont":{"type":"string","pattern":"^[A-Za-z0-9 ]{1,60}$"},"coverImageUrl":{"type":"string","maxLength":2000,"format":"uri"},"cornerRadius":{"type":"string","enum":["none","small","medium","large"]}},"additionalProperties":false},{"type":"null"}]},"autoMergeContacts":{"type":"boolean"},"invoiceTemplate":{"anyOf":[{"type":"string","enum":["classic","modern","minimal","bold"]},{"type":"null"}]},"invoiceTheme":{"anyOf":[{"type":"object","properties":{"primaryColor":{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"accentColor":{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"backgroundColor":{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"textColor":{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"headingFont":{"type":"string","pattern":"^[A-Za-z0-9 ]{1,60}$"},"bodyFont":{"type":"string","pattern":"^[A-Za-z0-9 ]{1,60}$"},"coverImageUrl":{"type":"string","maxLength":2000,"format":"uri"},"cornerRadius":{"type":"string","enum":["none","small","medium","large"]}},"additionalProperties":false},{"type":"null"}]},"formTemplate":{"anyOf":[{"type":"string","enum":["classic","modern","minimal","bold"]},{"type":"null"}]},"formTheme":{"anyOf":[{"type":"object","properties":{"primaryColor":{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"accentColor":{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"backgroundColor":{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"textColor":{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"headingFont":{"type":"string","pattern":"^[A-Za-z0-9 ]{1,60}$"},"bodyFont":{"type":"string","pattern":"^[A-Za-z0-9 ]{1,60}$"},"coverImageUrl":{"type":"string","maxLength":2000,"format":"uri"},"cornerRadius":{"type":"string","enum":["none","small","medium","large"]}},"additionalProperties":false},{"type":"null"}]},"surveyTemplate":{"anyOf":[{"type":"string","enum":["classic","modern","minimal","bold"]},{"type":"null"}]},"surveyTheme":{"anyOf":[{"type":"object","properties":{"primaryColor":{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"accentColor":{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"backgroundColor":{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"textColor":{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"headingFont":{"type":"string","pattern":"^[A-Za-z0-9 ]{1,60}$"},"bodyFont":{"type":"string","pattern":"^[A-Za-z0-9 ]{1,60}$"},"coverImageUrl":{"type":"string","maxLength":2000,"format":"uri"},"cornerRadius":{"type":"string","enum":["none","small","medium","large"]}},"additionalProperties":false},{"type":"null"}]},"linkTemplate":{"anyOf":[{"type":"string","enum":["classic","modern","minimal","bold"]},{"type":"null"}]},"linkTheme":{"anyOf":[{"type":"object","properties":{"primaryColor":{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"accentColor":{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"backgroundColor":{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"textColor":{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"headingFont":{"type":"string","pattern":"^[A-Za-z0-9 ]{1,60}$"},"bodyFont":{"type":"string","pattern":"^[A-Za-z0-9 ]{1,60}$"},"coverImageUrl":{"type":"string","maxLength":2000,"format":"uri"},"cornerRadius":{"type":"string","enum":["none","small","medium","large"]}},"additionalProperties":false},{"type":"null"}]},"catalogTemplate":{"anyOf":[{"type":"string","enum":["classic","modern","minimal","bold"]},{"type":"null"}]},"catalogTheme":{"anyOf":[{"type":"object","properties":{"primaryColor":{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"accentColor":{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"backgroundColor":{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"textColor":{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"headingFont":{"type":"string","pattern":"^[A-Za-z0-9 ]{1,60}$"},"bodyFont":{"type":"string","pattern":"^[A-Za-z0-9 ]{1,60}$"},"coverImageUrl":{"type":"string","maxLength":2000,"format":"uri"},"cornerRadius":{"type":"string","enum":["none","small","medium","large"]}},"additionalProperties":false},{"type":"null"}]},"portalTemplate":{"anyOf":[{"type":"string","enum":["classic","modern","minimal","bold"]},{"type":"null"}]},"portalTheme":{"anyOf":[{"type":"object","properties":{"primaryColor":{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"accentColor":{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"backgroundColor":{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"textColor":{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"headingFont":{"type":"string","pattern":"^[A-Za-z0-9 ]{1,60}$"},"bodyFont":{"type":"string","pattern":"^[A-Za-z0-9 ]{1,60}$"},"coverImageUrl":{"type":"string","maxLength":2000,"format":"uri"},"cornerRadius":{"type":"string","enum":["none","small","medium","large"]}},"additionalProperties":false},{"type":"null"}]},"emailTemplate":{"anyOf":[{"type":"string","enum":["classic","modern","minimal","bold"]},{"type":"null"}]},"emailTheme":{"anyOf":[{"type":"object","properties":{"primaryColor":{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"accentColor":{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"backgroundColor":{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"textColor":{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"headingFont":{"type":"string","pattern":"^[A-Za-z0-9 ]{1,60}$"},"bodyFont":{"type":"string","pattern":"^[A-Za-z0-9 ]{1,60}$"},"coverImageUrl":{"type":"string","maxLength":2000,"format":"uri"},"cornerRadius":{"type":"string","enum":["none","small","medium","large"]}},"additionalProperties":false},{"type":"null"}]}}}}}},"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"autoMergeContacts":{"type":"boolean"},"bookingTemplate":{"type":["null","string"]},"bookingTheme":{"properties":{"primaryColor":{"type":"string"}},"required":["primaryColor"],"type":["null","object"]},"catalogTemplate":{"type":["null","string"]},"catalogTheme":{"properties":{"primaryColor":{"type":"string"}},"required":["primaryColor"],"type":["null","object"]},"dealLogoUrl":{"type":"null"},"defaultCurrency":{"type":"string"},"defaultDealTemplate":{"type":["null","string"]},"defaultDealTheme":{"properties":{"accentColor":{"type":"string"},"bodyFont":{"type":"string"},"headingFont":{"type":"string"},"primaryColor":{"type":"string"}},"required":["primaryColor"],"type":["null","object"]},"emailTemplate":{"type":["null","string"]},"emailTheme":{"properties":{"primaryColor":{"type":"string"}},"required":["primaryColor"],"type":["null","object"]},"faviconUrl":{"type":"null"},"formTemplate":{"type":["null","string"]},"formTheme":{"properties":{"primaryColor":{"type":"string"}},"required":["primaryColor"],"type":["null","object"]},"invoiceTemplate":{"type":["null","string"]},"invoiceTheme":{"properties":{"primaryColor":{"type":"string"}},"required":["primaryColor"],"type":["null","object"]},"linkTemplate":{"type":"null"},"linkTheme":{"type":"null"},"portalTemplate":{"type":["null","string"]},"portalTheme":{"properties":{"primaryColor":{"type":"string"}},"required":["primaryColor"],"type":["null","object"]},"surveyTemplate":{"type":["null","string"]},"surveyTheme":{"properties":{},"required":[],"type":["null","object"]},"theme":{"properties":{"primaryColor":{"type":"string"}},"required":[],"type":"object"},"themeTemplate":{"type":"string"}},"required":["autoMergeContacts","bookingTemplate","bookingTheme","catalogTemplate","catalogTheme","dealLogoUrl","defaultCurrency","defaultDealTemplate","defaultDealTheme","emailTemplate","emailTheme","faviconUrl","formTemplate","formTheme","invoiceTemplate","invoiceTheme","linkTemplate","linkTheme","portalTemplate","portalTheme","surveyTemplate","surveyTheme","theme","themeTemplate"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/organization/transfer-ownership":{"post":{"operationId":"POST /v1/organization/transfer-ownership","summary":"Makes another member the owner (owner only).","tags":["organization"],"x-feature":"organization","x-action":"create","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"memberId":{"type":"string","minLength":1}},"required":["memberId"]}}}},"responses":{"204":{"description":"Done, with no content."},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/packages":{"get":{"operationId":"GET /v1/packages","summary":"Lists the catalog packages.","tags":["packages"],"x-feature":"packages","x-action":"read","parameters":[{"name":"page","in":"query","required":false,"schema":{"default":1,"type":"integer","minimum":1,"maximum":9007199254740991}},{"name":"pageSize","in":"query","required":false,"schema":{"default":25,"type":"integer","minimum":1,"maximum":100}},{"name":"q","in":"query","required":false,"schema":{"type":"string","minLength":1,"maxLength":200}},{"name":"archived","in":"query","required":false,"schema":{"type":"string"}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"items":{"properties":{"archived":{"type":"boolean"},"createdAt":{"format":"date-time","type":"string"},"createdBy":{"format":"uuid","type":"string"},"currency":{"type":"string"},"description":{"type":"null"},"discount":{"type":"null"},"discountAmount":{"type":"integer"},"discountPrices":{"properties":{},"required":[],"type":"object"},"id":{"format":"uuid","type":"string"},"images":{"items":{"properties":{"id":{"format":"uuid","type":"string"},"url":{"format":"uri","type":"string"}},"required":["id","url"],"type":"object"},"type":"array"},"items":{"items":{"properties":{"catalogPrice":{"type":"integer"},"description":{"type":"null"},"kind":{"type":"string"},"name":{"type":"string"},"prices":{"properties":{},"required":[],"type":"object"},"quantity":{"type":"integer"},"serviceId":{"format":"uuid","type":"string"},"sku":{"type":"null"},"unitPrice":{"type":"integer"}},"required":["catalogPrice","description","kind","name","prices","quantity","serviceId","sku","unitPrice"],"type":"object"},"type":"array"},"name":{"type":"string"},"organizationId":{"format":"uuid","type":"string"},"publicVisible":{"type":"boolean"},"subtotal":{"type":"integer"},"total":{"type":"integer"},"totals":{"properties":{},"required":[],"type":"object"},"updatedAt":{"format":"date-time","type":"string"},"updatedBy":{"format":"uuid","type":"string"}},"required":["archived","createdAt","createdBy","currency","description","discount","discountAmount","discountPrices","id","images","items","name","organizationId","publicVisible","subtotal","total","totals","updatedAt","updatedBy"],"type":"object"},"type":"array"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"post":{"operationId":"POST /v1/packages","summary":"Creates a package of services and products.","tags":["packages"],"x-feature":"packages","x-action":"create","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"name":{"type":"string","minLength":1,"maxLength":100},"description":{"anyOf":[{"type":"string","maxLength":2000},{"type":"null"}]},"currency":{"type":"string","pattern":"^[A-Z]{3}$"},"items":{"minItems":1,"maxItems":50,"type":"array","items":{"type":"object","properties":{"serviceId":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},"quantity":{"default":1,"type":"integer","minimum":1,"maximum":100000},"unitPrice":{"type":"integer","minimum":0,"maximum":10000000000000},"prices":{"type":"object","propertyNames":{"type":"string","pattern":"^[A-Z]{3}$"},"additionalProperties":{"type":"integer","minimum":0,"maximum":10000000000000}}},"required":["serviceId"]}},"discount":{"anyOf":[{"oneOf":[{"type":"object","properties":{"type":{"type":"string","const":"percent"},"value":{"type":"number","exclusiveMinimum":0,"maximum":100,"multipleOf":0.01}},"required":["type","value"]},{"type":"object","properties":{"type":{"type":"string","const":"amount"},"value":{"type":"integer","exclusiveMinimum":0,"maximum":10000000000000}},"required":["type","value"]}]},{"type":"null"}]},"discountPrices":{"type":"object","propertyNames":{"type":"string","pattern":"^[A-Z]{3}$"},"additionalProperties":{"type":"integer","minimum":0,"maximum":10000000000000}},"publicVisible":{"type":"boolean"},"archived":{"type":"boolean"}},"required":["name","items"]}}}},"responses":{"201":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"archived":{"type":"boolean"},"createdAt":{"format":"date-time","type":"string"},"createdBy":{"format":"uuid","type":"string"},"currency":{"type":"string"},"description":{"type":"null"},"discount":{"properties":{"type":{"type":"string"},"value":{"type":"number"}},"required":["type","value"],"type":["null","object"]},"discountAmount":{"type":"integer"},"discountPrices":{"properties":{"USD":{"type":"integer"}},"required":[],"type":"object"},"id":{"format":"uuid","type":"string"},"images":{"type":"array"},"items":{"items":{"properties":{"catalogPrice":{"type":"integer"},"description":{"type":["null","string"]},"kind":{"type":"string"},"name":{"type":"string"},"prices":{"properties":{"BRL":{"type":"integer"},"USD":{"type":"integer"}},"required":[],"type":"object"},"quantity":{"type":"integer"},"serviceId":{"format":"uuid","type":"string"},"sku":{"type":["null","string"]},"unitPrice":{"type":"integer"}},"required":["catalogPrice","description","kind","name","prices","quantity","serviceId","sku","unitPrice"],"type":"object"},"type":"array"},"name":{"type":"string"},"organizationId":{"format":"uuid","type":"string"},"publicVisible":{"type":"boolean"},"subtotal":{"type":"integer"},"total":{"type":"integer"},"totals":{"properties":{"USD":{"properties":{"discountAmount":{"type":"integer"},"subtotal":{"type":"integer"},"total":{"type":"integer"}},"required":["subtotal","discountAmount","total"],"type":"object"}},"required":[],"type":"object"},"updatedAt":{"format":"date-time","type":"string"},"updatedBy":{"format":"uuid","type":"string"}},"required":["archived","createdAt","createdBy","currency","description","discount","discountAmount","discountPrices","id","images","items","name","organizationId","publicVisible","subtotal","total","totals","updatedAt","updatedBy"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/packages/{id}":{"delete":{"operationId":"DELETE /v1/packages/{id}","summary":"Deletes a package; proposals and invoices keep their copies.","tags":["packages"],"x-feature":"packages","x-action":"delete","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"204":{"description":"Done, with no content."},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"get":{"operationId":"GET /v1/packages/{id}","summary":"Returns a package with its items and prices.","tags":["packages"],"x-feature":"packages","x-action":"read","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"archived":{"type":"boolean"},"createdAt":{"format":"date-time","type":"string"},"createdBy":{"format":"uuid","type":"string"},"currency":{"type":"string"},"description":{"type":"null"},"discount":{"properties":{"type":{"type":"string"},"value":{"type":"integer"}},"required":["type","value"],"type":["null","object"]},"discountAmount":{"type":"integer"},"discountPrices":{"properties":{},"required":[],"type":"object"},"id":{"format":"uuid","type":"string"},"images":{"type":"array"},"items":{"items":{"properties":{"catalogPrice":{"type":"integer"},"description":{"type":"null"},"kind":{"type":"string"},"name":{"type":"string"},"prices":{"properties":{},"required":[],"type":"object"},"quantity":{"type":"integer"},"serviceId":{"format":"uuid","type":"string"},"sku":{"type":"null"},"unitPrice":{"type":"integer"}},"required":["serviceId","quantity","unitPrice","prices","kind","sku","name","description","catalogPrice"],"type":"object"},"type":"array"},"name":{"type":"string"},"organizationId":{"format":"uuid","type":"string"},"publicVisible":{"type":"boolean"},"subtotal":{"type":"integer"},"total":{"type":"integer"},"totals":{"properties":{},"required":[],"type":"object"},"updatedAt":{"format":"date-time","type":"string"},"updatedBy":{"format":"uuid","type":"string"}},"required":["archived","createdAt","createdBy","currency","description","discount","discountAmount","discountPrices","id","images","items","name","organizationId","publicVisible","subtotal","total","totals","updatedAt","updatedBy"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"patch":{"operationId":"PATCH /v1/packages/{id}","summary":"Changes a package: items, prices and visibility.","tags":["packages"],"x-feature":"packages","x-action":"update","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"name":{"type":"string","minLength":1,"maxLength":100},"description":{"anyOf":[{"type":"string","maxLength":2000},{"type":"null"}]},"currency":{"type":"string","pattern":"^[A-Z]{3}$"},"items":{"minItems":1,"maxItems":50,"type":"array","items":{"type":"object","properties":{"serviceId":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},"quantity":{"default":1,"type":"integer","minimum":1,"maximum":100000},"unitPrice":{"type":"integer","minimum":0,"maximum":10000000000000},"prices":{"type":"object","propertyNames":{"type":"string","pattern":"^[A-Z]{3}$"},"additionalProperties":{"type":"integer","minimum":0,"maximum":10000000000000}}},"required":["serviceId"]}},"discount":{"anyOf":[{"oneOf":[{"type":"object","properties":{"type":{"type":"string","const":"percent"},"value":{"type":"number","exclusiveMinimum":0,"maximum":100,"multipleOf":0.01}},"required":["type","value"]},{"type":"object","properties":{"type":{"type":"string","const":"amount"},"value":{"type":"integer","exclusiveMinimum":0,"maximum":10000000000000}},"required":["type","value"]}]},{"type":"null"}]},"discountPrices":{"type":"object","propertyNames":{"type":"string","pattern":"^[A-Z]{3}$"},"additionalProperties":{"type":"integer","minimum":0,"maximum":10000000000000}},"publicVisible":{"type":"boolean"},"archived":{"type":"boolean"}}}}}},"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"archived":{"type":"boolean"},"createdAt":{"format":"date-time","type":"string"},"createdBy":{"format":"uuid","type":"string"},"currency":{"type":"string"},"description":{"type":"null"},"discount":{"properties":{"type":{"type":"string"},"value":{"type":"integer"}},"required":["type","value"],"type":["null","object"]},"discountAmount":{"type":"integer"},"discountPrices":{"properties":{"USD":{"type":"integer"}},"required":[],"type":"object"},"id":{"format":"uuid","type":"string"},"images":{"type":"array"},"items":{"items":{"properties":{"catalogPrice":{"type":"integer"},"description":{"type":"null"},"kind":{"type":"string"},"name":{"type":"string"},"prices":{"properties":{"BRL":{"type":"integer"},"USD":{"type":"integer"}},"required":[],"type":"object"},"quantity":{"type":"integer"},"serviceId":{"format":"uuid","type":"string"},"sku":{"type":"null"},"unitPrice":{"type":"integer"}},"required":["catalogPrice","description","kind","name","prices","quantity","serviceId","sku","unitPrice"],"type":"object"},"type":"array"},"name":{"type":"string"},"organizationId":{"format":"uuid","type":"string"},"publicVisible":{"type":"boolean"},"subtotal":{"type":"integer"},"total":{"type":"integer"},"totals":{"properties":{"USD":{"properties":{"discountAmount":{"type":"integer"},"subtotal":{"type":"integer"},"total":{"type":"integer"}},"required":["subtotal","discountAmount","total"],"type":"object"}},"required":[],"type":"object"},"updatedAt":{"format":"date-time","type":"string"},"updatedBy":{"format":"uuid","type":"string"}},"required":["archived","createdAt","createdBy","currency","description","discount","discountAmount","discountPrices","id","images","items","name","organizationId","publicVisible","subtotal","total","totals","updatedAt","updatedBy"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/packages/{id}/images":{"post":{"operationId":"POST /v1/packages/{id}/images","summary":"Uploads a photo for a package.","tags":["packages"],"x-feature":"packages","x-action":"update","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"multipart/form-data":{"schema":{"type":"object","required":["file"],"properties":{"file":{"type":"string","format":"binary"}}}}}},"responses":{"201":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"images":{"items":{"properties":{"id":{"format":"uuid","type":"string"},"url":{"format":"uri","type":"string"}},"required":["id","url"],"type":"object"},"type":"array"}},"required":["images"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/packages/{id}/images/{imageId}":{"delete":{"operationId":"DELETE /v1/packages/{id}/images/{imageId}","summary":"Removes a package’s photo.","tags":["packages"],"x-feature":"packages","x-action":"delete","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}},{"name":"imageId","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/payments":{"get":{"operationId":"GET /v1/payments","summary":"Lists the Stripe payments received and the sales made outside Firmado.","tags":["payments"],"x-feature":"payments","x-action":"read","parameters":[{"name":"page","in":"query","required":false,"schema":{"default":1,"type":"integer","minimum":1,"maximum":9007199254740991}},{"name":"pageSize","in":"query","required":false,"schema":{"default":50,"type":"integer","minimum":1,"maximum":50}},{"name":"q","in":"query","required":false,"schema":{"type":"string","minLength":1,"maxLength":200}},{"name":"status","in":"query","required":false,"schema":{"type":"string","enum":["open","processing","paid","failed","expired","refunded"]}},{"name":"source","in":"query","required":false,"schema":{"type":"string","enum":["deal","appointment","invoice","file"]}},{"name":"contactId","in":"query","required":false,"schema":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"}},{"name":"createdFrom","in":"query","required":false,"schema":{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"}},{"name":"createdBefore","in":"query","required":false,"schema":{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"data":{"items":{"properties":{"amount":{"type":"integer"},"applicationFee":{"type":"integer"},"appointment":{"properties":{"id":{"format":"uuid","type":"string"},"startsAt":{"format":"date-time","type":"string"},"title":{"type":"string"}},"required":["id","startsAt","title"],"type":["null","object"]},"contact":{"properties":{"id":{"format":"uuid","type":"string"},"name":{"type":"string"}},"required":["id","name"],"type":["null","object"]},"createdAt":{"format":"date-time","type":"string"},"currency":{"type":"string"},"deal":{"properties":{"id":{"format":"uuid","type":"string"},"reference":{"type":"null"},"title":{"type":"string"}},"required":["id","reference","title"],"type":["null","object"]},"file":{"properties":{"id":{"format":"uuid","type":"string"},"title":{"type":"string"}},"required":["id","title"],"type":["null","object"]},"id":{"format":"uuid","type":"string"},"invoice":{"properties":{"id":{"format":"uuid","type":"string"},"number":{"type":"string"}},"required":["id","number"],"type":["null","object"]},"paidAt":{"format":"date-time","type":"string"},"payerEmail":{"format":"email","type":"string"},"payerName":{"type":"string"},"refundReason":{"type":["null","string"]},"refundedAt":{"format":"date-time","type":["null","string"]},"source":{"type":"string"},"status":{"type":"string"}},"required":["amount","applicationFee","appointment","contact","createdAt","currency","deal","file","id","invoice","paidAt","payerEmail","payerName","refundReason","refundedAt","source","status"],"type":"object"},"type":"array"},"page":{"type":"integer"},"pageSize":{"type":"integer"},"paidTotals":{"items":{"properties":{"amount":{"type":"integer"},"currency":{"type":"string"}},"required":["amount","currency"],"type":"object"},"type":"array"},"total":{"type":"integer"}},"required":["data","page","pageSize","paidTotals","total"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/payments/{id}/refund":{"post":{"operationId":"POST /v1/payments/{id}/refund","summary":"Refunds a Stripe payment in full (administrators).","tags":["payments"],"x-feature":"payments","x-action":"update","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"default":{},"type":"object","properties":{"reason":{"anyOf":[{"type":"string","maxLength":1000},{"type":"null"}]}}}}}},"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"amount":{"type":"integer"},"applicationFee":{"type":"integer"},"appointment":{"type":"null"},"contact":{"type":"null"},"createdAt":{"format":"date-time","type":"string"},"currency":{"type":"string"},"deal":{"type":"null"},"file":{"type":"null"},"id":{"format":"uuid","type":"string"},"invoice":{"properties":{"id":{"format":"uuid","type":"string"},"number":{"type":"string"}},"required":["id","number"],"type":"object"},"paidAt":{"format":"date-time","type":"string"},"payerEmail":{"format":"email","type":"string"},"payerName":{"type":"string"},"refundReason":{"type":"string"},"refundedAt":{"format":"date-time","type":"string"},"source":{"type":"string"},"status":{"type":"string"}},"required":["id","source","status","amount","currency","applicationFee","payerName","payerEmail","paidAt","refundedAt","refundReason","createdAt","contact","deal","appointment","invoice","file"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/projects":{"get":{"operationId":"GET /v1/projects","summary":"Lists the projects, by status or owner.","tags":["projects"],"x-feature":"projects","x-action":"read","responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"type":"array"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"post":{"operationId":"POST /v1/projects","summary":"Creates a project.","tags":["projects"],"x-feature":"projects","x-action":"create","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"name":{"type":"string","minLength":1,"maxLength":120},"description":{"anyOf":[{"type":"string","maxLength":2000},{"type":"null"}]},"startDate":{"anyOf":[{"type":"string","format":"date","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))$"},{"type":"null"}]},"endDate":{"anyOf":[{"type":"string","format":"date","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))$"},{"type":"null"}]},"ownerIds":{"maxItems":100,"type":"array","items":{"type":"string","minLength":1}}},"required":["name"]}}}},"responses":{"201":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"createdAt":{"format":"date-time","type":"string"},"createdBy":{"format":"uuid","type":"string"},"description":{"type":["null","string"]},"endDate":{"format":"date","type":["null","string"]},"endingNotifiedFor":{"type":"null"},"id":{"format":"uuid","type":"string"},"itemCount":{"type":"integer"},"name":{"type":"string"},"owners":{"items":{"properties":{"id":{"format":"uuid","type":"string"},"image":{"type":"null"},"name":{"type":"string"}},"required":["id","name","image"],"type":"object"},"type":"array"},"startDate":{"format":"date","type":["null","string"]},"status":{"type":"string"},"updatedAt":{"format":"date-time","type":"string"},"updatedBy":{"format":"uuid","type":"string"}},"required":["createdAt","createdBy","description","endDate","endingNotifiedFor","id","itemCount","name","owners","startDate","status","updatedAt","updatedBy"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/projects/{id}":{"delete":{"operationId":"DELETE /v1/projects/{id}","summary":"Deletes a project; its records stay.","tags":["projects"],"x-feature":"projects","x-action":"delete","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"204":{"description":"Done, with no content."},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"get":{"operationId":"GET /v1/projects/{id}","summary":"Returns a project with its numbers.","tags":["projects"],"x-feature":"projects","x-action":"read","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"createdAt":{"format":"date-time","type":"string"},"createdBy":{"format":"uuid","type":"string"},"description":{"type":"null"},"endDate":{"type":"null"},"endingNotifiedFor":{"type":"null"},"id":{"format":"uuid","type":"string"},"itemCount":{"type":"integer"},"name":{"type":"string"},"owners":{"type":"array"},"startDate":{"type":"null"},"status":{"type":"string"},"updatedAt":{"format":"date-time","type":"string"},"updatedBy":{"format":"uuid","type":"string"}},"required":["createdAt","createdBy","description","endDate","endingNotifiedFor","id","itemCount","name","owners","startDate","status","updatedAt","updatedBy"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"patch":{"operationId":"PATCH /v1/projects/{id}","summary":"Changes a project: name, dates, owners and status.","tags":["projects"],"x-feature":"projects","x-action":"update","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"name":{"type":"string","minLength":1,"maxLength":120},"description":{"anyOf":[{"type":"string","maxLength":2000},{"type":"null"}]},"startDate":{"anyOf":[{"type":"string","format":"date","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))$"},{"type":"null"}]},"endDate":{"anyOf":[{"type":"string","format":"date","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))$"},{"type":"null"}]},"ownerIds":{"maxItems":100,"type":"array","items":{"type":"string","minLength":1}},"status":{"type":"string","enum":["active","paused","completed","archived"]}}}}}},"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"createdAt":{"format":"date-time","type":"string"},"createdBy":{"format":"uuid","type":"string"},"description":{"type":"null"},"endDate":{"format":"date","type":["null","string"]},"endingNotifiedFor":{"format":"date","type":["null","string"]},"id":{"format":"uuid","type":"string"},"itemCount":{"type":"integer"},"name":{"type":"string"},"owners":{"items":{"properties":{"id":{"format":"uuid","type":"string"},"image":{"type":"null"},"name":{"type":"string"}},"required":["id","name","image"],"type":"object"},"type":"array"},"startDate":{"format":"date","type":["null","string"]},"status":{"type":"string"},"updatedAt":{"format":"date-time","type":"string"},"updatedBy":{"format":"uuid","type":"string"}},"required":["id","name","description","status","startDate","endDate","endingNotifiedFor","createdBy","updatedBy","createdAt","updatedAt","owners","itemCount"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/projects/{id}/activity":{"get":{"operationId":"GET /v1/projects/{id}/activity","summary":"What happened in a project’s records.","tags":["projects"],"x-feature":"projects","x-action":"read","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}},{"name":"scope","in":"query","required":false,"schema":{"default":"period","type":"string","enum":["period","all"]}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"from":{"format":"date","type":"string"},"series":{"items":{"properties":{"clicks":{"type":"integer"},"date":{"format":"date","type":"string"},"downloads":{"type":"integer"},"responses":{"type":"integer"},"submissions":{"type":"integer"},"views":{"type":"integer"}},"required":["date","views","clicks","submissions","responses","downloads"],"type":"object"},"type":"array"},"to":{"format":"date","type":"string"}},"required":["from","to","series"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/projects/{id}/candidates":{"get":{"operationId":"GET /v1/projects/{id}/candidates","summary":"Records of one kind that can be added to a project.","tags":["projects"],"x-feature":"projects","x-action":"read","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}},{"name":"kind","in":"query","required":true,"schema":{"type":"string","enum":["contact","company","list","deal","invoice","approval","contract","catalogPage","task","bookingPage","form","survey","linkPage","shortLink","sharedFile","postAutomation","socialPost"]}},{"name":"q","in":"query","required":false,"schema":{"type":"string","maxLength":100}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"items":{"properties":{"amount":{"type":"null"},"closedAt":{"type":"null"},"currency":{"type":"null"},"detail":{"type":"null"},"dueAt":{"type":"null"},"id":{"format":"uuid","type":"string"},"kind":{"type":"string"},"metrics":{"properties":{"accounts":{"type":"integer"},"comments":{"type":"integer"},"reactions":{"type":"integer"},"shares":{"type":"integer"}},"required":[],"type":"object"},"name":{"type":"string"},"status":{"type":["null","string"]}},"required":["amount","closedAt","currency","detail","dueAt","id","kind","metrics","name","status"],"type":"object"},"type":"array"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/projects/{id}/items":{"get":{"operationId":"GET /v1/projects/{id}/items","summary":"A project’s records, by kind, with their numbers.","tags":["projects"],"x-feature":"projects","x-action":"read","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}},{"name":"scope","in":"query","required":false,"schema":{"default":"period","type":"string","enum":["period","all"]}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"groups":{"items":{"properties":{"items":{"items":{"properties":{"amount":{"type":["integer","null"]},"closedAt":{"format":"date-time","type":["null","string"]},"currency":{"type":["null","string"]},"detail":{"type":"null"},"dueAt":{"type":"null"},"id":{"format":"uuid","type":"string"},"kind":{"type":"string"},"metrics":{"properties":{"accounts":{"type":"integer"},"appointments":{"type":"integer"},"clicks":{"type":"integer"},"comments":{"type":"integer"},"contacts":{"type":"integer"},"reactions":{"type":"integer"},"shares":{"type":"integer"},"submissions":{"type":"integer"},"views":{"type":"integer"}},"required":[],"type":"object"},"name":{"type":"string"},"status":{"type":["null","string"]}},"required":["amount","closedAt","currency","detail","dueAt","id","kind","metrics","name","status"],"type":"object"},"type":"array"},"kind":{"type":"string"}},"required":["items","kind"],"type":"object"},"type":"array"},"range":{"properties":{"from":{"format":"date","type":"string"},"to":{"format":"date","type":"string"}},"required":["from","to"],"type":["null","object"]},"summary":{"properties":{"appointments":{"type":"integer"},"clicks":{"type":"integer"},"dealsAccepted":{"items":{"properties":{"amount":{"type":"integer"},"currency":{"type":"string"}},"required":["currency","amount"],"type":"object"},"type":"array"},"dealsOpen":{"type":"array"},"downloads":{"type":"integer"},"invoicesOpen":{"type":"array"},"invoicesPaid":{"type":"array"},"items":{"type":"integer"},"leads":{"type":"integer"},"postComments":{"type":"integer"},"postReactions":{"type":"integer"},"requests":{"type":"integer"},"responses":{"type":"integer"},"submissions":{"type":"integer"},"tasksDone":{"type":"integer"},"tasksTotal":{"type":"integer"},"views":{"type":"integer"}},"required":["appointments","clicks","dealsAccepted","dealsOpen","downloads","invoicesOpen","invoicesPaid","items","leads","postComments","postReactions","requests","responses","submissions","tasksDone","tasksTotal","views"],"type":"object"}},"required":["groups","range","summary"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"post":{"operationId":"POST /v1/projects/{id}/items","summary":"Adds records to a project.","tags":["projects"],"x-feature":"projects","x-action":"create","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"kind":{"type":"string","enum":["contact","company","list","deal","invoice","approval","contract","catalogPage","task","bookingPage","form","survey","linkPage","shortLink","sharedFile","postAutomation","socialPost"]},"ids":{"minItems":1,"maxItems":100,"type":"array","items":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"}}},"required":["kind","ids"]}}}},"responses":{"201":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"groups":{"items":{"properties":{"items":{"items":{"properties":{"amount":{"type":["integer","null"]},"closedAt":{"format":"date-time","type":["null","string"]},"currency":{"type":["null","string"]},"detail":{"type":["null","string"]},"dueAt":{"format":"date-time","type":["null","string"]},"id":{"format":"uuid","type":"string"},"kind":{"type":"string"},"metrics":{"properties":{"accounts":{"type":"integer"},"appointments":{"type":"integer"},"approved":{"type":"integer"},"approvers":{"type":"integer"},"clicks":{"type":"integer"},"comments":{"type":"integer"},"contacts":{"type":"integer"},"downloads":{"type":"integer"},"handled":{"type":"integer"},"invited":{"type":"integer"},"leads":{"type":"integer"},"reactions":{"type":"integer"},"requests":{"type":"integer"},"responses":{"type":"integer"},"sales":{"type":"integer"},"shares":{"type":"integer"},"signed":{"type":"integer"},"signers":{"type":"integer"},"submissions":{"type":"integer"},"views":{"type":"integer"}},"required":[],"type":"object"},"name":{"type":"string"},"status":{"type":["null","string"]}},"required":["amount","closedAt","currency","detail","dueAt","id","kind","metrics","name","status"],"type":"object"},"type":"array"},"kind":{"type":"string"}},"required":["items","kind"],"type":"object"},"type":"array"},"range":{"properties":{"from":{"format":"date","type":"string"},"to":{"format":"date","type":"string"}},"required":["from","to"],"type":["null","object"]},"summary":{"properties":{"appointments":{"type":"integer"},"clicks":{"type":"integer"},"dealsAccepted":{"items":{"properties":{"amount":{"type":"integer"},"currency":{"type":"string"}},"required":["currency","amount"],"type":"object"},"type":"array"},"dealsOpen":{"items":{"properties":{"amount":{"type":"integer"},"currency":{"type":"string"}},"required":["currency","amount"],"type":"object"},"type":"array"},"downloads":{"type":"integer"},"invoicesOpen":{"type":"array"},"invoicesPaid":{"items":{"properties":{"amount":{"type":"integer"},"currency":{"type":"string"}},"required":["currency","amount"],"type":"object"},"type":"array"},"items":{"type":"integer"},"leads":{"type":"integer"},"postComments":{"type":"integer"},"postReactions":{"type":"integer"},"requests":{"type":"integer"},"responses":{"type":"integer"},"submissions":{"type":"integer"},"tasksDone":{"type":"integer"},"tasksTotal":{"type":"integer"},"views":{"type":"integer"}},"required":["appointments","clicks","dealsAccepted","dealsOpen","downloads","invoicesOpen","invoicesPaid","items","leads","postComments","postReactions","requests","responses","submissions","tasksDone","tasksTotal","views"],"type":"object"}},"required":["groups","range","summary"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/projects/{id}/items/{kind}/{itemId}":{"delete":{"operationId":"DELETE /v1/projects/{id}/items/{kind}/{itemId}","summary":"Removes a record from a project.","tags":["projects"],"x-feature":"projects","x-action":"delete","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}},{"name":"kind","in":"path","required":true,"schema":{"type":"string"}},{"name":"itemId","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"204":{"description":"Done, with no content."},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/projects/{id}/notes":{"get":{"operationId":"GET /v1/projects/{id}/notes","summary":"A project’s notes.","tags":["projects"],"x-feature":"projects","x-action":"read","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"items":{"properties":{"authorId":{"format":"uuid","type":"string"},"authorImage":{"type":"null"},"authorName":{"type":"string"},"body":{"type":"string"},"createdAt":{"format":"date-time","type":"string"},"id":{"format":"uuid","type":"string"},"updatedAt":{"format":"date-time","type":"string"}},"required":["id","body","authorId","authorName","authorImage","createdAt","updatedAt"],"type":"object"},"type":"array"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"post":{"operationId":"POST /v1/projects/{id}/notes","summary":"Writes a note on a project (any member).","tags":["projects"],"x-feature":"projects","x-action":"create","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"body":{"type":"string","minLength":1,"maxLength":5000}},"required":["body"]}}}},"responses":{"201":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"authorId":{"format":"uuid","type":"string"},"authorImage":{"type":"null"},"authorName":{"type":"string"},"body":{"type":"string"},"createdAt":{"format":"date-time","type":"string"},"id":{"format":"uuid","type":"string"},"updatedAt":{"format":"date-time","type":"string"}},"required":["id","body","authorId","authorName","authorImage","createdAt","updatedAt"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/projects/{id}/notes/{noteId}":{"delete":{"operationId":"DELETE /v1/projects/{id}/notes/{noteId}","summary":"Deletes a note.","tags":["projects"],"x-feature":"projects","x-action":"delete","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}},{"name":"noteId","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"204":{"description":"Done, with no content."},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"patch":{"operationId":"PATCH /v1/projects/{id}/notes/{noteId}","summary":"Changes a note.","tags":["projects"],"x-feature":"projects","x-action":"update","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}},{"name":"noteId","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"body":{"type":"string","minLength":1,"maxLength":5000}},"required":["body"]}}}},"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"authorId":{"format":"uuid","type":"string"},"authorImage":{"type":"null"},"authorName":{"type":"string"},"body":{"type":"string"},"createdAt":{"format":"date-time","type":"string"},"id":{"format":"uuid","type":"string"},"updatedAt":{"format":"date-time","type":"string"}},"required":["id","body","authorId","authorName","authorImage","createdAt","updatedAt"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/projects/for-item":{"get":{"operationId":"GET /v1/projects/for-item","summary":"The projects a record is in.","tags":["projects"],"x-feature":"projects","x-action":"read","parameters":[{"name":"kind","in":"query","required":true,"schema":{"type":"string","enum":["contact","company","list","deal","invoice","approval","contract","catalogPage","task","bookingPage","form","survey","linkPage","shortLink","sharedFile","postAutomation","socialPost"]}},{"name":"itemId","in":"query","required":true,"schema":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"items":{"format":"uuid","type":"string"},"type":"array"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/qr-codes":{"get":{"operationId":"GET /v1/qr-codes","summary":"Lists the saved QR codes.","tags":["qrCodes"],"x-feature":"qrCodes","x-action":"read","responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"post":{"operationId":"POST /v1/qr-codes","summary":"Saves a QR code: what it holds and its look.","tags":["qrCodes"],"x-feature":"qrCodes","x-action":"create","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"name":{"type":"string","minLength":1,"maxLength":120},"content":{"oneOf":[{"type":"object","properties":{"kind":{"type":"string","const":"url"},"url":{"type":"string","maxLength":2000},"shortLinkId":{"default":null,"anyOf":[{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},{"type":"null"}]}},"required":["kind","url"]},{"type":"object","properties":{"kind":{"type":"string","const":"text"},"text":{"type":"string","minLength":1,"maxLength":2000}},"required":["kind","text"]},{"type":"object","properties":{"kind":{"type":"string","const":"email"},"to":{"type":"string","maxLength":200,"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,}$"},"subject":{"default":"","type":"string","maxLength":200},"body":{"default":"","type":"string","maxLength":1000}},"required":["kind","to"]},{"type":"object","properties":{"kind":{"type":"string","const":"phone"},"number":{"default":"","type":"string","maxLength":30,"pattern":"^\\+?[0-9 ().-]*$"}},"required":["kind"]},{"type":"object","properties":{"kind":{"type":"string","const":"sms"},"number":{"default":"","type":"string","maxLength":30,"pattern":"^\\+?[0-9 ().-]*$"},"message":{"default":"","type":"string","maxLength":500}},"required":["kind"]},{"type":"object","properties":{"kind":{"type":"string","const":"whatsapp"},"number":{"default":"","type":"string","maxLength":30,"pattern":"^\\+?[0-9 ().-]*$"},"message":{"default":"","type":"string","maxLength":500}},"required":["kind"]},{"type":"object","properties":{"kind":{"type":"string","const":"wifi"},"ssid":{"type":"string","minLength":1,"maxLength":32},"password":{"default":"","type":"string","maxLength":63},"encryption":{"default":"WPA","type":"string","enum":["WPA","WEP","nopass"]},"hidden":{"default":false,"type":"boolean"}},"required":["kind","ssid"]},{"type":"object","properties":{"kind":{"type":"string","const":"vcard"},"firstName":{"default":"","type":"string","maxLength":100},"lastName":{"default":"","type":"string","maxLength":100},"organization":{"default":"","type":"string","maxLength":150},"title":{"default":"","type":"string","maxLength":100},"phone":{"default":"","type":"string","maxLength":30,"pattern":"^\\+?[0-9 ().-]*$"},"mobile":{"default":"","type":"string","maxLength":30,"pattern":"^\\+?[0-9 ().-]*$"},"email":{"default":"","anyOf":[{"type":"string","const":""},{"type":"string","maxLength":200,"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,}$"}]},"website":{"default":"","anyOf":[{"type":"string","const":""},{"type":"string","maxLength":2000}]},"street":{"default":"","type":"string","maxLength":200},"city":{"default":"","type":"string","maxLength":100},"region":{"default":"","type":"string","maxLength":100},"postalCode":{"default":"","type":"string","maxLength":20},"country":{"default":"","type":"string","maxLength":100},"note":{"default":"","type":"string","maxLength":500}},"required":["kind"]},{"type":"object","properties":{"kind":{"type":"string","const":"location"},"latitude":{"type":"number","minimum":-90,"maximum":90},"longitude":{"type":"number","minimum":-180,"maximum":180},"label":{"default":"","type":"string","maxLength":200}},"required":["kind","latitude","longitude"]},{"type":"object","properties":{"kind":{"type":"string","const":"event"},"title":{"type":"string","minLength":1,"maxLength":200},"location":{"default":"","type":"string","maxLength":200},"description":{"default":"","type":"string","maxLength":1000},"start":{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"},"end":{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"},"allDay":{"default":false,"type":"boolean"}},"required":["kind","title","start","end"]}]},"design":{"default":{"margin":2,"errorCorrection":"M","dotStyle":"square","frameStyle":"square","eyeStyle":"square","foreground":"#000000","gradient":null,"frameColor":null,"eyeColor":null,"background":"#ffffff","logo":"","logoSize":22,"logoClear":true,"logoMargin":1,"logoRadius":0,"caption":"","captionColor":"#000000"},"type":"object","properties":{"margin":{"default":2,"type":"integer","minimum":0,"maximum":10},"errorCorrection":{"default":"M","type":"string","enum":["L","M","Q","H"]},"dotStyle":{"default":"square","type":"string","enum":["square","rounded","dots","fluid","diamond","vertical","horizontal"]},"frameStyle":{"default":"square","type":"string","enum":["square","rounded","circle"]},"eyeStyle":{"default":"square","type":"string","enum":["square","rounded","circle"]},"foreground":{"default":"#000000","type":"string","pattern":"^#[0-9a-fA-F]{6}(?:[0-9a-fA-F]{2})?$"},"gradient":{"default":null,"anyOf":[{"type":"object","properties":{"kind":{"default":"linear","type":"string","enum":["linear","radial"]},"angle":{"default":45,"type":"integer","minimum":0,"maximum":360},"from":{"type":"string","pattern":"^#[0-9a-fA-F]{6}(?:[0-9a-fA-F]{2})?$"},"to":{"type":"string","pattern":"^#[0-9a-fA-F]{6}(?:[0-9a-fA-F]{2})?$"}},"required":["from","to"]},{"type":"null"}]},"frameColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}(?:[0-9a-fA-F]{2})?$"},{"type":"null"}]},"eyeColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}(?:[0-9a-fA-F]{2})?$"},{"type":"null"}]},"background":{"default":"#ffffff","type":"string","pattern":"^#[0-9a-fA-F]{6}(?:[0-9a-fA-F]{2})?$"},"logo":{"default":"","type":"string","maxLength":2000},"logoSize":{"default":22,"type":"integer","minimum":10,"maximum":35},"logoClear":{"default":true,"type":"boolean"},"logoMargin":{"default":1,"type":"integer","minimum":0,"maximum":4},"logoRadius":{"default":0,"type":"integer","minimum":0,"maximum":50},"caption":{"default":"","type":"string","maxLength":60},"captionColor":{"default":"#000000","type":"string","pattern":"^#[0-9a-fA-F]{6}(?:[0-9a-fA-F]{2})?$"}}}},"required":["name","content"]}}}},"responses":{"201":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"content":{"properties":{"kind":{"type":"string"},"shortLinkId":{"format":"uuid","type":["null","string"]},"url":{"format":"uri","type":"string"}},"required":["url","kind","shortLinkId"],"type":"object"},"createdAt":{"format":"date-time","type":"string"},"createdBy":{"format":"uuid","type":"string"},"design":{"properties":{"background":{"type":"string"},"caption":{"type":"string"},"captionColor":{"type":"string"},"dotStyle":{"type":"string"},"errorCorrection":{"type":"string"},"eyeColor":{"type":"null"},"eyeStyle":{"type":"string"},"foreground":{"type":"string"},"frameColor":{"type":"null"},"frameStyle":{"type":"string"},"gradient":{"properties":{"angle":{"type":"integer"},"from":{"type":"string"},"kind":{"type":"string"},"to":{"type":"string"}},"required":["to","from","kind","angle"],"type":["null","object"]},"logo":{"type":"string"},"logoClear":{"type":"boolean"},"logoMargin":{"type":"integer"},"logoRadius":{"type":"integer"},"logoSize":{"type":"integer"},"margin":{"type":"integer"}},"required":["logo","margin","caption","dotStyle","eyeColor","eyeStyle","gradient","logoSize","logoClear","background","foreground","frameColor","frameStyle","logoMargin","logoRadius","captionColor","errorCorrection"],"type":"object"},"id":{"format":"uuid","type":"string"},"name":{"type":"string"},"shortLink":{"properties":{"active":{"type":"boolean"},"code":{"type":"string"},"id":{"format":"uuid","type":"string"},"shortUrl":{"format":"uri","type":"string"},"url":{"format":"uri","type":"string"}},"required":["id","code","url","active","shortUrl"],"type":["null","object"]},"shortLinkId":{"format":"uuid","type":["null","string"]},"updatedAt":{"format":"date-time","type":"string"},"updatedBy":{"format":"uuid","type":"string"}},"required":["id","name","content","design","shortLinkId","createdBy","updatedBy","createdAt","updatedAt","shortLink"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/qr-codes/{id}":{"delete":{"operationId":"DELETE /v1/qr-codes/{id}","summary":"Deletes a saved QR code.","tags":["qrCodes"],"x-feature":"qrCodes","x-action":"delete","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"204":{"description":"Done, with no content."},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"get":{"operationId":"GET /v1/qr-codes/{id}","summary":"Returns a saved QR code.","tags":["qrCodes"],"x-feature":"qrCodes","x-action":"read","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"content":{"properties":{"kind":{"type":"string"},"shortLinkId":{"format":"uuid","type":"string"},"url":{"format":"uri","type":"string"}},"required":["url","kind","shortLinkId"],"type":"object"},"createdAt":{"format":"date-time","type":"string"},"createdBy":{"format":"uuid","type":"string"},"design":{"properties":{"background":{"type":"string"},"caption":{"type":"string"},"captionColor":{"type":"string"},"dotStyle":{"type":"string"},"errorCorrection":{"type":"string"},"eyeColor":{"type":"null"},"eyeStyle":{"type":"string"},"foreground":{"type":"string"},"frameColor":{"type":"null"},"frameStyle":{"type":"string"},"gradient":{"type":"null"},"logo":{"type":"string"},"logoClear":{"type":"boolean"},"logoMargin":{"type":"integer"},"logoRadius":{"type":"integer"},"logoSize":{"type":"integer"},"margin":{"type":"integer"}},"required":["logo","margin","caption","dotStyle","eyeColor","eyeStyle","gradient","logoSize","logoClear","background","foreground","frameColor","frameStyle","logoMargin","logoRadius","captionColor","errorCorrection"],"type":"object"},"id":{"format":"uuid","type":"string"},"name":{"type":"string"},"shortLink":{"type":"null"},"shortLinkId":{"type":"null"},"updatedAt":{"format":"date-time","type":"string"},"updatedBy":{"format":"uuid","type":"string"}},"required":["id","name","content","design","shortLinkId","createdBy","updatedBy","createdAt","updatedAt","shortLink"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"patch":{"operationId":"PATCH /v1/qr-codes/{id}","summary":"Changes a saved QR code.","tags":["qrCodes"],"x-feature":"qrCodes","x-action":"update","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"name":{"type":"string","minLength":1,"maxLength":120},"content":{"oneOf":[{"type":"object","properties":{"kind":{"type":"string","const":"url"},"url":{"type":"string","maxLength":2000},"shortLinkId":{"default":null,"anyOf":[{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},{"type":"null"}]}},"required":["kind","url"]},{"type":"object","properties":{"kind":{"type":"string","const":"text"},"text":{"type":"string","minLength":1,"maxLength":2000}},"required":["kind","text"]},{"type":"object","properties":{"kind":{"type":"string","const":"email"},"to":{"type":"string","maxLength":200,"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,}$"},"subject":{"default":"","type":"string","maxLength":200},"body":{"default":"","type":"string","maxLength":1000}},"required":["kind","to"]},{"type":"object","properties":{"kind":{"type":"string","const":"phone"},"number":{"default":"","type":"string","maxLength":30,"pattern":"^\\+?[0-9 ().-]*$"}},"required":["kind"]},{"type":"object","properties":{"kind":{"type":"string","const":"sms"},"number":{"default":"","type":"string","maxLength":30,"pattern":"^\\+?[0-9 ().-]*$"},"message":{"default":"","type":"string","maxLength":500}},"required":["kind"]},{"type":"object","properties":{"kind":{"type":"string","const":"whatsapp"},"number":{"default":"","type":"string","maxLength":30,"pattern":"^\\+?[0-9 ().-]*$"},"message":{"default":"","type":"string","maxLength":500}},"required":["kind"]},{"type":"object","properties":{"kind":{"type":"string","const":"wifi"},"ssid":{"type":"string","minLength":1,"maxLength":32},"password":{"default":"","type":"string","maxLength":63},"encryption":{"default":"WPA","type":"string","enum":["WPA","WEP","nopass"]},"hidden":{"default":false,"type":"boolean"}},"required":["kind","ssid"]},{"type":"object","properties":{"kind":{"type":"string","const":"vcard"},"firstName":{"default":"","type":"string","maxLength":100},"lastName":{"default":"","type":"string","maxLength":100},"organization":{"default":"","type":"string","maxLength":150},"title":{"default":"","type":"string","maxLength":100},"phone":{"default":"","type":"string","maxLength":30,"pattern":"^\\+?[0-9 ().-]*$"},"mobile":{"default":"","type":"string","maxLength":30,"pattern":"^\\+?[0-9 ().-]*$"},"email":{"default":"","anyOf":[{"type":"string","const":""},{"type":"string","maxLength":200,"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,}$"}]},"website":{"default":"","anyOf":[{"type":"string","const":""},{"type":"string","maxLength":2000}]},"street":{"default":"","type":"string","maxLength":200},"city":{"default":"","type":"string","maxLength":100},"region":{"default":"","type":"string","maxLength":100},"postalCode":{"default":"","type":"string","maxLength":20},"country":{"default":"","type":"string","maxLength":100},"note":{"default":"","type":"string","maxLength":500}},"required":["kind"]},{"type":"object","properties":{"kind":{"type":"string","const":"location"},"latitude":{"type":"number","minimum":-90,"maximum":90},"longitude":{"type":"number","minimum":-180,"maximum":180},"label":{"default":"","type":"string","maxLength":200}},"required":["kind","latitude","longitude"]},{"type":"object","properties":{"kind":{"type":"string","const":"event"},"title":{"type":"string","minLength":1,"maxLength":200},"location":{"default":"","type":"string","maxLength":200},"description":{"default":"","type":"string","maxLength":1000},"start":{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"},"end":{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"},"allDay":{"default":false,"type":"boolean"}},"required":["kind","title","start","end"]}]},"design":{"type":"object","properties":{"margin":{"default":2,"type":"integer","minimum":0,"maximum":10},"errorCorrection":{"default":"M","type":"string","enum":["L","M","Q","H"]},"dotStyle":{"default":"square","type":"string","enum":["square","rounded","dots","fluid","diamond","vertical","horizontal"]},"frameStyle":{"default":"square","type":"string","enum":["square","rounded","circle"]},"eyeStyle":{"default":"square","type":"string","enum":["square","rounded","circle"]},"foreground":{"default":"#000000","type":"string","pattern":"^#[0-9a-fA-F]{6}(?:[0-9a-fA-F]{2})?$"},"gradient":{"default":null,"anyOf":[{"type":"object","properties":{"kind":{"default":"linear","type":"string","enum":["linear","radial"]},"angle":{"default":45,"type":"integer","minimum":0,"maximum":360},"from":{"type":"string","pattern":"^#[0-9a-fA-F]{6}(?:[0-9a-fA-F]{2})?$"},"to":{"type":"string","pattern":"^#[0-9a-fA-F]{6}(?:[0-9a-fA-F]{2})?$"}},"required":["from","to"]},{"type":"null"}]},"frameColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}(?:[0-9a-fA-F]{2})?$"},{"type":"null"}]},"eyeColor":{"default":null,"anyOf":[{"type":"string","pattern":"^#[0-9a-fA-F]{6}(?:[0-9a-fA-F]{2})?$"},{"type":"null"}]},"background":{"default":"#ffffff","type":"string","pattern":"^#[0-9a-fA-F]{6}(?:[0-9a-fA-F]{2})?$"},"logo":{"default":"","type":"string","maxLength":2000},"logoSize":{"default":22,"type":"integer","minimum":10,"maximum":35},"logoClear":{"default":true,"type":"boolean"},"logoMargin":{"default":1,"type":"integer","minimum":0,"maximum":4},"logoRadius":{"default":0,"type":"integer","minimum":0,"maximum":50},"caption":{"default":"","type":"string","maxLength":60},"captionColor":{"default":"#000000","type":"string","pattern":"^#[0-9a-fA-F]{6}(?:[0-9a-fA-F]{2})?$"}}}}}}}},"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"content":{"properties":{"encryption":{"type":"string"},"hidden":{"type":"boolean"},"kind":{"type":"string"},"password":{"type":"string"},"ssid":{"type":"string"}},"required":["kind","ssid","hidden","password","encryption"],"type":"object"},"createdAt":{"format":"date-time","type":"string"},"createdBy":{"format":"uuid","type":"string"},"design":{"properties":{"background":{"type":"string"},"caption":{"type":"string"},"captionColor":{"type":"string"},"dotStyle":{"type":"string"},"errorCorrection":{"type":"string"},"eyeColor":{"type":"null"},"eyeStyle":{"type":"string"},"foreground":{"type":"string"},"frameColor":{"type":"null"},"frameStyle":{"type":"string"},"gradient":{"properties":{"angle":{"type":"integer"},"from":{"type":"string"},"kind":{"type":"string"},"to":{"type":"string"}},"required":["to","from","kind","angle"],"type":"object"},"logo":{"type":"string"},"logoClear":{"type":"boolean"},"logoMargin":{"type":"integer"},"logoRadius":{"type":"integer"},"logoSize":{"type":"integer"},"margin":{"type":"integer"}},"required":["logo","margin","caption","dotStyle","eyeColor","eyeStyle","gradient","logoSize","logoClear","background","foreground","frameColor","frameStyle","logoMargin","logoRadius","captionColor","errorCorrection"],"type":"object"},"id":{"format":"uuid","type":"string"},"name":{"type":"string"},"shortLink":{"type":"null"},"shortLinkId":{"type":"null"},"updatedAt":{"format":"date-time","type":"string"},"updatedBy":{"format":"uuid","type":"string"}},"required":["id","name","content","design","shortLinkId","createdBy","updatedBy","createdAt","updatedAt","shortLink"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/qr-codes/logo":{"get":{"operationId":"GET /v1/qr-codes/logo","summary":"One of the organization’s pictures, for the middle of a code.","tags":["qrCodes"],"x-feature":"qrCodes","x-action":"read","parameters":[{"name":"url","in":"query","required":true,"schema":{"type":"string","maxLength":2000}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/services":{"get":{"operationId":"GET /v1/services","summary":"Lists the catalog services and products.","tags":["services"],"x-feature":"services","x-action":"read","parameters":[{"name":"page","in":"query","required":false,"schema":{"default":1,"type":"integer","minimum":1,"maximum":9007199254740991}},{"name":"pageSize","in":"query","required":false,"schema":{"default":25,"type":"integer","minimum":1,"maximum":100}},{"name":"q","in":"query","required":false,"schema":{"type":"string","minLength":1,"maxLength":200}},{"name":"archived","in":"query","required":false,"schema":{"type":"string"}},{"name":"kind","in":"query","required":false,"schema":{"type":"string","enum":["service","product"]}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"data":{"items":{"properties":{"archived":{"type":"boolean"},"availability":{"type":"string"},"brand":{"type":["null","string"]},"category":{"type":"null"},"condition":{"type":"string"},"createdAt":{"format":"date-time","type":"string"},"createdBy":{"format":"uuid","type":"string"},"currency":{"type":"string"},"description":{"type":"null"},"gtin":{"type":"null"},"id":{"format":"uuid","type":"string"},"images":{"type":"array"},"kind":{"type":"string"},"mpn":{"type":"null"},"name":{"type":"string"},"organizationId":{"format":"uuid","type":"string"},"prices":{"properties":{},"required":[],"type":"object"},"productGroup":{"type":["null","string"]},"productUrl":{"type":"null"},"publicVisible":{"type":"boolean"},"sku":{"type":["null","string"]},"unitPrice":{"type":"integer"},"updatedAt":{"format":"date-time","type":"string"},"updatedBy":{"format":"uuid","type":"string"}},"required":["id","organizationId","kind","sku","productGroup","brand","gtin","mpn","category","productUrl","condition","availability","images","name","description","currency","unitPrice","prices","publicVisible","archived","createdBy","updatedBy","createdAt","updatedAt"],"type":"object"},"type":"array"},"page":{"type":"integer"},"pageSize":{"type":"integer"},"total":{"type":"integer"}},"required":["data","page","pageSize","total"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"post":{"operationId":"POST /v1/services","summary":"Creates a service or a product.","tags":["services"],"x-feature":"services","x-action":"create","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"kind":{"default":"service","type":"string","enum":["service","product"]},"sku":{"anyOf":[{"type":"string","minLength":1,"maxLength":100},{"type":"null"}]},"productGroup":{"anyOf":[{"type":"string","maxLength":100},{"type":"null"}]},"brand":{"anyOf":[{"type":"string","maxLength":100},{"type":"null"}]},"gtin":{"anyOf":[{"type":"string","pattern":"^(?:[0-9]{8}|[0-9]{12}|[0-9]{13}|[0-9]{14})$"},{"type":"null"}]},"mpn":{"anyOf":[{"type":"string","maxLength":100},{"type":"null"}]},"category":{"anyOf":[{"type":"string","maxLength":250},{"type":"null"}]},"productUrl":{"anyOf":[{"type":"string","maxLength":2000,"format":"uri"},{"type":"null"}]},"condition":{"type":"string","enum":["new","refurbished","used"]},"availability":{"type":"string","enum":["in_stock","out_of_stock","preorder"]},"name":{"type":"string","minLength":1,"maxLength":200},"description":{"anyOf":[{"type":"string","maxLength":2000},{"type":"null"}]},"currency":{"type":"string","pattern":"^[A-Z]{3}$"},"unitPrice":{"type":"integer","minimum":0,"maximum":10000000000000},"prices":{"type":"object","propertyNames":{"type":"string","pattern":"^[A-Z]{3}$"},"additionalProperties":{"type":"integer","minimum":0,"maximum":10000000000000}},"publicVisible":{"type":"boolean"},"archived":{"type":"boolean"}},"required":["name","unitPrice"]}}}},"responses":{"201":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"archived":{"type":"boolean"},"availability":{"type":"string"},"brand":{"type":["null","string"]},"category":{"type":"null"},"condition":{"type":"string"},"createdAt":{"format":"date-time","type":"string"},"createdBy":{"format":"uuid","type":"string"},"currency":{"type":"string"},"description":{"type":["null","string"]},"gtin":{"type":"null"},"id":{"format":"uuid","type":"string"},"images":{"type":"array"},"kind":{"type":"string"},"mpn":{"type":"null"},"name":{"type":"string"},"organizationId":{"format":"uuid","type":"string"},"prices":{"properties":{},"required":[],"type":"object"},"productGroup":{"type":["null","string"]},"productUrl":{"format":"uri","type":["null","string"]},"publicVisible":{"type":"boolean"},"sku":{"type":["null","string"]},"unitPrice":{"type":"integer"},"updatedAt":{"format":"date-time","type":"string"},"updatedBy":{"format":"uuid","type":"string"}},"required":["archived","availability","brand","category","condition","createdAt","createdBy","currency","description","gtin","id","images","kind","mpn","name","organizationId","prices","productGroup","productUrl","publicVisible","sku","unitPrice","updatedAt","updatedBy"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/services/{id}":{"delete":{"operationId":"DELETE /v1/services/{id}","summary":"Deletes a service or product; proposals and invoices keep their copies.","tags":["services"],"x-feature":"services","x-action":"delete","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"204":{"description":"Done, with no content."},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"patch":{"operationId":"PATCH /v1/services/{id}","summary":"Changes a service or product: prices, description and visibility.","tags":["services"],"x-feature":"services","x-action":"update","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"sku":{"anyOf":[{"type":"string","minLength":1,"maxLength":100},{"type":"null"}]},"productGroup":{"anyOf":[{"type":"string","maxLength":100},{"type":"null"}]},"brand":{"anyOf":[{"type":"string","maxLength":100},{"type":"null"}]},"gtin":{"anyOf":[{"type":"string","pattern":"^(?:[0-9]{8}|[0-9]{12}|[0-9]{13}|[0-9]{14})$"},{"type":"null"}]},"mpn":{"anyOf":[{"type":"string","maxLength":100},{"type":"null"}]},"category":{"anyOf":[{"type":"string","maxLength":250},{"type":"null"}]},"productUrl":{"anyOf":[{"type":"string","maxLength":2000,"format":"uri"},{"type":"null"}]},"condition":{"type":"string","enum":["new","refurbished","used"]},"availability":{"type":"string","enum":["in_stock","out_of_stock","preorder"]},"name":{"type":"string","minLength":1,"maxLength":200},"description":{"anyOf":[{"type":"string","maxLength":2000},{"type":"null"}]},"currency":{"type":"string","pattern":"^[A-Z]{3}$"},"unitPrice":{"type":"integer","minimum":0,"maximum":10000000000000},"prices":{"type":"object","propertyNames":{"type":"string","pattern":"^[A-Z]{3}$"},"additionalProperties":{"type":"integer","minimum":0,"maximum":10000000000000}},"publicVisible":{"type":"boolean"},"archived":{"type":"boolean"}}}}}},"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"archived":{"type":"boolean"},"availability":{"type":"string"},"brand":{"type":"null"},"category":{"type":"null"},"condition":{"type":"string"},"createdAt":{"format":"date-time","type":"string"},"createdBy":{"format":"uuid","type":"string"},"currency":{"type":"string"},"description":{"type":["null","string"]},"gtin":{"type":"null"},"id":{"format":"uuid","type":"string"},"images":{"items":{"properties":{"id":{"format":"uuid","type":"string"},"url":{"format":"uri","type":"string"}},"required":["id","url"],"type":"object"},"type":"array"},"kind":{"type":"string"},"mpn":{"type":"null"},"name":{"type":"string"},"organizationId":{"format":"uuid","type":"string"},"prices":{"properties":{"BRL":{"type":"integer"},"USD":{"type":"integer"}},"required":[],"type":"object"},"productGroup":{"type":"null"},"productUrl":{"type":"null"},"publicVisible":{"type":"boolean"},"sku":{"type":["null","string"]},"unitPrice":{"type":"integer"},"updatedAt":{"format":"date-time","type":"string"},"updatedBy":{"format":"uuid","type":"string"}},"required":["archived","availability","brand","category","condition","createdAt","createdBy","currency","description","gtin","id","images","kind","mpn","name","organizationId","prices","productGroup","productUrl","publicVisible","sku","unitPrice","updatedAt","updatedBy"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/services/{id}/images":{"post":{"operationId":"POST /v1/services/{id}/images","summary":"Uploads a photo for a service or product.","tags":["services"],"x-feature":"services","x-action":"update","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"multipart/form-data":{"schema":{"type":"object","required":["file"],"properties":{"file":{"type":"string","format":"binary"}}}}}},"responses":{"201":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"images":{"items":{"properties":{"id":{"format":"uuid","type":"string"},"url":{"format":"uri","type":"string"}},"required":["id","url"],"type":"object"},"type":"array"}},"required":["images"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/services/{id}/images/{imageId}":{"delete":{"operationId":"DELETE /v1/services/{id}/images/{imageId}","summary":"Removes a service’s or product’s photo.","tags":["services"],"x-feature":"services","x-action":"delete","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}},{"name":"imageId","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"images":{"items":{"properties":{"id":{"format":"uuid","type":"string"},"url":{"format":"uri","type":"string"}},"required":["id","url"],"type":"object"},"type":"array"}},"required":["images"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/shared-files":{"get":{"operationId":"GET /v1/shared-files","summary":"Lists the shared files.","tags":["sharedFiles"],"x-feature":"sharedFiles","x-action":"read","responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"post":{"operationId":"POST /v1/shared-files","summary":"Shares a file from a public page: open, behind a form or a payment.","tags":["sharedFiles"],"x-feature":"sharedFiles","x-action":"create","requestBody":{"required":true,"content":{"multipart/form-data":{"schema":{"type":"object","required":["file"],"properties":{"file":{"type":"string","format":"binary"}}}}}},"responses":{"201":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"access":{"type":"string"},"active":{"type":"boolean"},"createdAt":{"format":"date-time","type":"string"},"createdBy":{"format":"uuid","type":"string"},"description":{"type":"null"},"downloads":{"type":"integer"},"downloads30":{"type":"integer"},"fileBytes":{"type":"integer"},"fileKind":{"type":"string"},"fileName":{"type":"string"},"form":{"type":"null"},"formId":{"type":"null"},"id":{"format":"uuid","type":"string"},"issue":{"type":"null"},"leads":{"type":"integer"},"priceAmount":{"type":"null"},"priceCurrency":{"type":"null"},"publicId":{"type":"string"},"sales":{"type":"integer"},"templateId":{"type":"null"},"theme":{"properties":{},"required":[],"type":"object"},"title":{"type":"string"},"updatedAt":{"format":"date-time","type":"string"},"updatedBy":{"format":"uuid","type":"string"},"url":{"format":"uri","type":"string"},"views":{"type":"integer"},"views30":{"type":"integer"}},"required":["access","active","createdAt","createdBy","description","downloads","downloads30","fileBytes","fileKind","fileName","form","formId","id","issue","leads","priceAmount","priceCurrency","publicId","sales","templateId","theme","title","updatedAt","updatedBy","url","views","views30"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/shared-files/{id}":{"delete":{"operationId":"DELETE /v1/shared-files/{id}","summary":"Deletes a shared file and its page.","tags":["sharedFiles"],"x-feature":"sharedFiles","x-action":"delete","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"204":{"description":"Done, with no content."},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"get":{"operationId":"GET /v1/shared-files/{id}","summary":"Returns a shared file with its settings.","tags":["sharedFiles"],"x-feature":"sharedFiles","x-action":"read","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"access":{"type":"string"},"active":{"type":"boolean"},"createdAt":{"format":"date-time","type":"string"},"createdBy":{"format":"uuid","type":"string"},"description":{"type":"null"},"downloads":{"type":"integer"},"downloads30":{"type":"integer"},"fileBytes":{"type":"integer"},"fileKind":{"type":"string"},"fileName":{"type":"string"},"form":{"type":"null"},"formId":{"type":"null"},"id":{"format":"uuid","type":"string"},"issue":{"type":"string"},"leads":{"type":"integer"},"priceAmount":{"type":"null"},"priceCurrency":{"type":"null"},"publicId":{"type":"string"},"sales":{"type":"integer"},"templateId":{"type":"null"},"theme":{"properties":{},"required":[],"type":"object"},"title":{"type":"string"},"updatedAt":{"format":"date-time","type":"string"},"updatedBy":{"format":"uuid","type":"string"},"url":{"format":"uri","type":"string"},"views":{"type":"integer"},"views30":{"type":"integer"}},"required":["id","publicId","title","description","fileName","fileBytes","fileKind","access","formId","priceAmount","priceCurrency","active","templateId","theme","createdBy","updatedBy","createdAt","updatedAt","url","form","issue","views","views30","downloads","downloads30","leads","sales"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"patch":{"operationId":"PATCH /v1/shared-files/{id}","summary":"Changes a shared file’s page and what it asks for.","tags":["sharedFiles"],"x-feature":"sharedFiles","x-action":"update","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"title":{"type":"string","minLength":1,"maxLength":200},"description":{"anyOf":[{"type":"string","maxLength":2000},{"type":"null"}]},"access":{"type":"string","enum":["link","form","form_email"]},"formId":{"anyOf":[{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},{"type":"null"}]},"priceAmount":{"anyOf":[{"type":"integer","minimum":1,"maximum":100000000},{"type":"null"}]},"priceCurrency":{"anyOf":[{"type":"string","pattern":"^[A-Z]{3}$"},{"type":"null"}]},"active":{"type":"boolean"},"templateId":{"anyOf":[{"type":"string","enum":["classic","modern","minimal","bold"]},{"type":"null"}]},"theme":{"type":"object","properties":{"primaryColor":{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"accentColor":{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"backgroundColor":{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"textColor":{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"headingFont":{"type":"string","pattern":"^[A-Za-z0-9 ]{1,60}$"},"bodyFont":{"type":"string","pattern":"^[A-Za-z0-9 ]{1,60}$"},"coverImageUrl":{"type":"string","maxLength":2000,"format":"uri"},"cornerRadius":{"type":"string","enum":["none","small","medium","large"]}},"additionalProperties":false}}}}}},"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"access":{"type":"string"},"active":{"type":"boolean"},"createdAt":{"format":"date-time","type":"string"},"createdBy":{"format":"uuid","type":"string"},"description":{"type":"null"},"downloads":{"type":"integer"},"downloads30":{"type":"integer"},"fileBytes":{"type":"integer"},"fileKind":{"type":"string"},"fileName":{"type":"string"},"form":{"properties":{"active":{"type":"boolean"},"id":{"format":"uuid","type":"string"},"name":{"type":"string"}},"required":["id","name","active"],"type":["null","object"]},"formId":{"format":"uuid","type":["null","string"]},"id":{"format":"uuid","type":"string"},"issue":{"type":"null"},"leads":{"type":"integer"},"priceAmount":{"type":["integer","null"]},"priceCurrency":{"type":["null","string"]},"publicId":{"type":"string"},"sales":{"type":"integer"},"templateId":{"type":["null","string"]},"theme":{"properties":{"primaryColor":{"type":"string"}},"required":[],"type":"object"},"title":{"type":"string"},"updatedAt":{"format":"date-time","type":"string"},"updatedBy":{"format":"uuid","type":"string"},"url":{"format":"uri","type":"string"},"views":{"type":"integer"},"views30":{"type":"integer"}},"required":["id","publicId","title","description","fileName","fileBytes","fileKind","access","formId","priceAmount","priceCurrency","active","templateId","theme","createdBy","updatedBy","createdAt","updatedAt","url","form","issue","views","views30","downloads","downloads30","leads","sales"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/shared-files/{id}/file":{"put":{"operationId":"PUT /v1/shared-files/{id}/file","summary":"Replaces the file; the page keeps its address.","tags":["sharedFiles"],"x-feature":"sharedFiles","x-action":"update","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"multipart/form-data":{"schema":{"type":"object","required":["file"],"properties":{"file":{"type":"string","format":"binary"}}}}}},"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/shared-files/{id}/leads":{"get":{"operationId":"GET /v1/shared-files/{id}/leads","summary":"Who got the file, and how.","tags":["sharedFiles"],"x-feature":"sharedFiles","x-action":"read","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"items":{"properties":{"contact":{"properties":{"id":{"format":"uuid","type":"string"},"name":{"type":"string"}},"required":["id","name"],"type":"object"},"createdAt":{"format":"date-time","type":"string"},"delivery":{"type":"string"},"downloads":{"type":"integer"},"email":{"format":"email","type":"string"},"emailedAt":{"type":"null"},"expiresAt":{"format":"date-time","type":"string"},"id":{"format":"uuid","type":"string"},"lastDownloadAt":{"format":"date-time","type":"string"},"status":{"type":"string"}},"required":["id","status","delivery","email","contact","downloads","lastDownloadAt","expiresAt","emailedAt","createdAt"],"type":"object"},"type":"array"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/shared-files/{id}/leads/{accessId}/resend":{"post":{"operationId":"POST /v1/shared-files/{id}/leads/{accessId}/resend","summary":"Emails someone their download link again.","tags":["sharedFiles"],"x-feature":"sharedFiles","x-action":"update","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}},{"name":"accessId","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"204":{"description":"Done, with no content."},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/shared-files/{id}/stats":{"get":{"operationId":"GET /v1/shared-files/{id}/stats","summary":"Views and downloads of a shared file, per day.","tags":["sharedFiles"],"x-feature":"sharedFiles","x-action":"read","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}},{"name":"days","in":"query","required":false,"schema":{"default":30,"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"countries":{"type":"array"},"days":{"type":"integer"},"devices":{"items":{"properties":{"key":{"type":"string"},"views":{"type":"integer"}},"required":["key","views"],"type":"object"},"type":"array"},"downloads":{"type":"integer"},"leads":{"type":"integer"},"revenue":{"items":{"properties":{"amount":{"type":"integer"},"currency":{"type":"string"}},"required":["currency","amount"],"type":"object"},"type":"array"},"sales":{"type":"integer"},"series":{"items":{"properties":{"day":{"format":"date","type":"string"},"downloads":{"type":"integer"},"views":{"type":"integer"}},"required":["day","views","downloads"],"type":"object"},"type":"array"},"sources":{"items":{"properties":{"key":{"type":"string"},"views":{"type":"integer"}},"required":["key","views"],"type":"object"},"type":"array"},"views":{"type":"integer"}},"required":["days","views","downloads","leads","sales","revenue","series","sources","countries","devices"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/shared-files/look":{"get":{"operationId":"GET /v1/shared-files/look","summary":"The look a shared file’s page preview starts from; saves nothing.","tags":["sharedFiles"],"x-feature":"sharedFiles","x-action":"read","parameters":[{"name":"templateId","in":"query","required":false,"schema":{"type":"string","enum":["classic","modern","minimal","bold"]}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"organization":{"properties":{"language":{"type":"string"},"name":{"type":"string"}},"required":["name","language"],"type":"object"},"templateId":{"type":"string"},"theme":{"properties":{"accentColor":{"type":"string"},"backgroundColor":{"type":"string"},"bodyFont":{"type":"string"},"cornerRadius":{"type":"string"},"headingFont":{"type":"string"},"primaryColor":{"type":"string"},"textColor":{"type":"string"}},"required":["primaryColor","accentColor","backgroundColor","textColor","headingFont","bodyFont","cornerRadius"],"type":"object"}},"required":["organization","templateId","theme"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/short-links":{"get":{"operationId":"GET /v1/short-links","summary":"Lists the short links.","tags":["shortLinks"],"x-feature":"shortLinks","x-action":"read","responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"type":"array"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"post":{"operationId":"POST /v1/short-links","summary":"Creates a short link on the organization’s domain.","tags":["shortLinks"],"x-feature":"shortLinks","x-action":"create","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"name":{"type":"string","minLength":1,"maxLength":100},"url":{"type":"string","maxLength":2000},"code":{"type":"string","pattern":"^[a-z0-9](?:[a-z0-9-]{1,38}[a-z0-9])$"}},"required":["name","url"]}}}},"responses":{"201":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"active":{"type":"boolean"},"clicks":{"type":"integer"},"clicks30":{"type":"integer"},"code":{"type":"string"},"createdAt":{"format":"date-time","type":"string"},"createdBy":{"format":"uuid","type":"string"},"id":{"format":"uuid","type":"string"},"name":{"type":"string"},"shortUrl":{"format":"uri","type":"string"},"updatedAt":{"format":"date-time","type":"string"},"updatedBy":{"format":"uuid","type":"string"},"url":{"format":"uri","type":"string"}},"required":["active","clicks","clicks30","code","createdAt","createdBy","id","name","shortUrl","updatedAt","updatedBy","url"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/short-links/{id}":{"delete":{"operationId":"DELETE /v1/short-links/{id}","summary":"Deletes a short link.","tags":["shortLinks"],"x-feature":"shortLinks","x-action":"delete","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"204":{"description":"Done, with no content."},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"get":{"operationId":"GET /v1/short-links/{id}","summary":"Returns a short link.","tags":["shortLinks"],"x-feature":"shortLinks","x-action":"read","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"active":{"type":"boolean"},"clicks":{"type":"integer"},"clicks30":{"type":"integer"},"code":{"type":"string"},"createdAt":{"format":"date-time","type":"string"},"createdBy":{"format":"uuid","type":"string"},"id":{"format":"uuid","type":"string"},"name":{"type":"string"},"shortUrl":{"format":"uri","type":["null","string"]},"updatedAt":{"format":"date-time","type":"string"},"updatedBy":{"format":"uuid","type":"string"},"url":{"format":"uri","type":"string"}},"required":["id","code","name","url","active","createdBy","updatedBy","createdAt","updatedAt","shortUrl","clicks","clicks30"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"patch":{"operationId":"PATCH /v1/short-links/{id}","summary":"Changes where a short link goes.","tags":["shortLinks"],"x-feature":"shortLinks","x-action":"update","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"name":{"type":"string","minLength":1,"maxLength":100},"url":{"type":"string","maxLength":2000},"code":{"type":"string","pattern":"^[a-z0-9](?:[a-z0-9-]{1,38}[a-z0-9])$"},"active":{"type":"boolean"}}}}}},"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"active":{"type":"boolean"},"clicks":{"type":"integer"},"clicks30":{"type":"integer"},"code":{"type":"string"},"createdAt":{"format":"date-time","type":"string"},"createdBy":{"format":"uuid","type":"string"},"id":{"format":"uuid","type":"string"},"name":{"type":"string"},"shortUrl":{"format":"uri","type":"string"},"updatedAt":{"format":"date-time","type":"string"},"updatedBy":{"format":"uuid","type":"string"},"url":{"format":"uri","type":"string"}},"required":["id","code","name","url","active","createdBy","updatedBy","createdAt","updatedAt","shortUrl","clicks","clicks30"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/short-links/{id}/stats":{"get":{"operationId":"GET /v1/short-links/{id}/stats","summary":"Clicks of a short link, per day.","tags":["shortLinks"],"x-feature":"shortLinks","x-action":"read","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}},{"name":"days","in":"query","required":false,"schema":{"default":30,"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"clicks":{"type":"integer"},"countries":{"items":{"properties":{"clicks":{"type":"integer"},"key":{"type":"string"}},"required":["key","clicks"],"type":"object"},"type":"array"},"days":{"type":"integer"},"devices":{"items":{"properties":{"clicks":{"type":"integer"},"key":{"type":"string"}},"required":["key","clicks"],"type":"object"},"type":"array"},"series":{"items":{"properties":{"clicks":{"type":"integer"},"day":{"format":"date","type":"string"}},"required":["day","clicks"],"type":"object"},"type":"array"},"sources":{"items":{"properties":{"clicks":{"type":"integer"},"key":{"type":"string"}},"required":["key","clicks"],"type":"object"},"type":"array"}},"required":["days","clicks","series","sources","countries","devices"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/short-links/domain":{"get":{"operationId":"GET /v1/short-links/domain","summary":"The domain short links use, and whether it works.","tags":["shortLinks"],"x-feature":"shortLinks","x-action":"read","responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"hostname":{"type":["null","string"]}},"required":["hostname"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/social-posts":{"get":{"operationId":"GET /v1/social-posts","summary":"Lists the posts of the social calendar between two dates.","tags":["socialPosts"],"x-feature":"socialPosts","x-action":"read","parameters":[{"name":"from","in":"query","required":false,"schema":{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"}},{"name":"to","in":"query","required":false,"schema":{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"}},{"name":"status","in":"query","required":false,"schema":{"type":"string","enum":["draft","pending","changes_requested","scheduled","publishing","published","failed"]}},{"name":"unscheduled","in":"query","required":false,"schema":{"type":"string"}},{"name":"connectionId","in":"query","required":false,"schema":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"items":{"properties":{"approvedAt":{"format":"date-time","type":["null","string"]},"approvedBy":{"format":"uuid","type":["null","string"]},"approvedByName":{"type":["null","string"]},"automation":{"type":"null"},"caption":{"type":"string"},"countedAt":{"type":"null"},"createdAt":{"format":"date-time","type":"string"},"createdBy":{"format":"uuid","type":"string"},"createdByName":{"type":"string"},"firstComment":{"type":"null"},"id":{"format":"uuid","type":"string"},"media":{"items":{"properties":{"alt":{"type":"null"},"height":{"type":"integer"},"id":{"format":"uuid","type":"string"},"url":{"format":"uri","type":"string"},"width":{"type":"integer"}},"required":["id","alt","url","width","height"],"type":"object"},"type":"array"},"notes":{"type":"null"},"organizationId":{"format":"uuid","type":"string"},"publishedAt":{"type":"null"},"scheduledAt":{"format":"date-time","type":"string"},"status":{"type":"string"},"submittedAt":{"format":"date-time","type":["null","string"]},"submittedBy":{"format":"uuid","type":["null","string"]},"targets":{"items":{"properties":{"automationError":{"type":"null"},"automationId":{"type":"null"},"caption":{"type":"null"},"connectionId":{"format":"uuid","type":"string"},"error":{"type":"null"},"errorDetail":{"type":"null"},"externalId":{"type":"null"},"id":{"format":"uuid","type":"string"},"label":{"type":"string"},"metrics":{"type":"null"},"network":{"type":"string"},"permalink":{"type":"null"},"publishedAt":{"type":"null"},"status":{"type":"string"}},"required":["id","connectionId","network","label","caption","status","externalId","permalink","error","errorDetail","publishedAt","automationId","automationError","metrics"],"type":"object"},"type":"array"},"title":{"type":"null"},"updatedAt":{"format":"date-time","type":"string"},"updatedBy":{"format":"uuid","type":"string"}},"required":["id","organizationId","title","caption","firstComment","media","automation","notes","status","scheduledAt","createdBy","updatedBy","submittedBy","submittedAt","approvedBy","approvedAt","publishedAt","countedAt","createdAt","updatedAt","createdByName","approvedByName","targets"],"type":"object"},"type":"array"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"post":{"operationId":"POST /v1/social-posts","summary":"Creates a post draft for the connected accounts.","tags":["socialPosts"],"x-feature":"socialPosts","x-action":"create","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"title":{"anyOf":[{"type":"string","maxLength":200},{"type":"null"}]},"caption":{"default":"","type":"string","maxLength":63206},"firstComment":{"anyOf":[{"type":"string","maxLength":2200},{"type":"null"}]},"media":{"default":[],"maxItems":10,"type":"array","items":{"type":"object","properties":{"id":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},"alt":{"anyOf":[{"type":"string","maxLength":1000},{"type":"null"}]}},"required":["id"]}},"notes":{"anyOf":[{"type":"string","maxLength":5000},{"type":"null"}]},"scheduledAt":{"anyOf":[{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"},{"type":"null"}]},"targets":{"default":[],"maxItems":10,"type":"array","items":{"type":"object","properties":{"connectionId":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},"caption":{"anyOf":[{"type":"string","maxLength":63206},{"type":"null"}]}},"required":["connectionId"]}},"automation":{"anyOf":[{"type":"object","properties":{"days":{"default":7,"type":"integer","minimum":1,"maximum":90},"like":{"default":false,"type":"boolean"},"publicReply":{"default":null,"anyOf":[{"type":"string","maxLength":1000},{"type":"null"}]},"privateReply":{"default":null,"anyOf":[{"type":"string","maxLength":1000},{"type":"null"}]},"keywords":{"default":[],"maxItems":30,"type":"array","items":{"type":"string","minLength":1,"maxLength":80}},"createContacts":{"default":false,"type":"boolean"},"oncePerUser":{"default":true,"type":"boolean"}}},{"type":"null"}]}}}}}},"responses":{"201":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"approvedAt":{"type":"null"},"approvedBy":{"type":"null"},"approvedByName":{"type":"null"},"automation":{"properties":{"createContacts":{"type":"boolean"},"days":{"type":"integer"},"keywords":{"items":{"type":"string"},"type":"array"},"like":{"type":"boolean"},"oncePerUser":{"type":"boolean"},"privateReply":{"type":"string"},"publicReply":{"type":"null"}},"required":["days","like","keywords","oncePerUser","publicReply","privateReply","createContacts"],"type":["null","object"]},"caption":{"type":"string"},"countedAt":{"type":"null"},"createdAt":{"format":"date-time","type":"string"},"createdBy":{"format":"uuid","type":"string"},"createdByName":{"type":"string"},"firstComment":{"type":["null","string"]},"history":{"items":{"properties":{"createdAt":{"format":"date-time","type":"string"},"id":{"format":"uuid","type":"string"},"note":{"type":"null"},"type":{"type":"string"},"userId":{"format":"uuid","type":"string"},"userName":{"type":"string"}},"required":["id","type","note","createdAt","userId","userName"],"type":"object"},"type":"array"},"id":{"format":"uuid","type":"string"},"media":{"items":{"properties":{"alt":{"type":["null","string"]},"height":{"type":"integer"},"id":{"format":"uuid","type":"string"},"url":{"format":"uri","type":"string"},"width":{"type":"integer"}},"required":["id","alt","url","width","height"],"type":"object"},"type":"array"},"notes":{"type":"null"},"organizationId":{"format":"uuid","type":"string"},"publishedAt":{"type":"null"},"scheduledAt":{"format":"date-time","type":["null","string"]},"status":{"type":"string"},"submittedAt":{"type":"null"},"submittedBy":{"type":"null"},"targets":{"items":{"properties":{"automationError":{"type":"null"},"automationId":{"type":"null"},"caption":{"type":["null","string"]},"connectionId":{"format":"uuid","type":"string"},"error":{"type":"null"},"errorDetail":{"type":"null"},"externalId":{"type":"null"},"id":{"format":"uuid","type":"string"},"label":{"type":"string"},"metrics":{"type":"null"},"network":{"type":"string"},"permalink":{"type":"null"},"publishedAt":{"type":"null"},"status":{"type":"string"}},"required":["id","connectionId","network","label","caption","status","externalId","permalink","error","errorDetail","publishedAt","automationId","automationError","metrics"],"type":"object"},"type":"array"},"title":{"type":["null","string"]},"updatedAt":{"format":"date-time","type":"string"},"updatedBy":{"format":"uuid","type":"string"}},"required":["id","organizationId","title","caption","firstComment","media","automation","notes","status","scheduledAt","createdBy","updatedBy","submittedBy","submittedAt","approvedBy","approvedAt","publishedAt","countedAt","createdAt","updatedAt","createdByName","approvedByName","targets","history"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/social-posts/{id}":{"delete":{"operationId":"DELETE /v1/social-posts/{id}","summary":"Deletes a post that has not gone out.","tags":["socialPosts"],"x-feature":"socialPosts","x-action":"delete","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"204":{"description":"Done, with no content."},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"get":{"operationId":"GET /v1/social-posts/{id}","summary":"Returns a post with each account’s result and its history.","tags":["socialPosts"],"x-feature":"socialPosts","x-action":"read","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"approvedAt":{"format":"date-time","type":"string"},"approvedBy":{"format":"uuid","type":"string"},"approvedByName":{"type":"string"},"automation":{"properties":{"createContacts":{"type":"boolean"},"days":{"type":"integer"},"keywords":{"items":{"type":"string"},"type":"array"},"like":{"type":"boolean"},"oncePerUser":{"type":"boolean"},"privateReply":{"type":"string"},"publicReply":{"type":"null"}},"required":["days","like","keywords","oncePerUser","publicReply","privateReply","createContacts"],"type":["null","object"]},"caption":{"type":"string"},"countedAt":{"format":"date-time","type":"string"},"createdAt":{"format":"date-time","type":"string"},"createdBy":{"format":"uuid","type":"string"},"createdByName":{"type":"string"},"firstComment":{"type":["null","string"]},"history":{"items":{"properties":{"createdAt":{"format":"date-time","type":"string"},"id":{"format":"uuid","type":"string"},"note":{"type":["null","string"]},"type":{"type":"string"},"userId":{"format":"uuid","type":["null","string"]},"userName":{"type":["null","string"]}},"required":["id","type","note","createdAt","userId","userName"],"type":"object"},"type":"array"},"id":{"format":"uuid","type":"string"},"media":{"items":{"properties":{"alt":{"type":["null","string"]},"height":{"type":"integer"},"id":{"format":"uuid","type":"string"},"url":{"format":"uri","type":"string"},"width":{"type":"integer"}},"required":["id","alt","url","width","height"],"type":"object"},"type":"array"},"notes":{"type":"null"},"organizationId":{"format":"uuid","type":"string"},"publishedAt":{"format":"date-time","type":["null","string"]},"scheduledAt":{"format":"date-time","type":"string"},"status":{"type":"string"},"submittedAt":{"format":"date-time","type":"string"},"submittedBy":{"format":"uuid","type":"string"},"targets":{"items":{"properties":{"automationError":{"type":"null"},"automationId":{"format":"uuid","type":["null","string"]},"caption":{"type":["null","string"]},"connectionId":{"format":"uuid","type":"string"},"error":{"type":["null","string"]},"errorDetail":{"type":["null","string"]},"externalId":{"type":["null","string"]},"id":{"format":"uuid","type":"string"},"label":{"type":"string"},"metrics":{"properties":{"error":{"type":"null"},"fetchedAt":{"type":"null"},"metrics":{"type":"null"},"nextFetchAt":{"format":"date-time","type":"string"}},"required":["metrics","fetchedAt","nextFetchAt","error"],"type":["null","object"]},"network":{"type":"string"},"permalink":{"format":"uri","type":["null","string"]},"publishedAt":{"format":"date-time","type":["null","string"]},"status":{"type":"string"}},"required":["id","connectionId","network","label","caption","status","externalId","permalink","error","errorDetail","publishedAt","automationId","automationError","metrics"],"type":"object"},"type":"array"},"title":{"type":["null","string"]},"updatedAt":{"format":"date-time","type":"string"},"updatedBy":{"format":"uuid","type":"string"}},"required":["id","organizationId","title","caption","firstComment","media","automation","notes","status","scheduledAt","createdBy","updatedBy","submittedBy","submittedAt","approvedBy","approvedAt","publishedAt","countedAt","createdAt","updatedAt","createdByName","approvedByName","targets","history"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"patch":{"operationId":"PATCH /v1/social-posts/{id}","summary":"Changes a post that has not gone out.","tags":["socialPosts"],"x-feature":"socialPosts","x-action":"update","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"title":{"anyOf":[{"type":"string","maxLength":200},{"type":"null"}]},"caption":{"type":"string","maxLength":63206},"firstComment":{"anyOf":[{"type":"string","maxLength":2200},{"type":"null"}]},"media":{"maxItems":10,"type":"array","items":{"type":"object","properties":{"id":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},"alt":{"anyOf":[{"type":"string","maxLength":1000},{"type":"null"}]}},"required":["id"]}},"notes":{"anyOf":[{"type":"string","maxLength":5000},{"type":"null"}]},"scheduledAt":{"anyOf":[{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"},{"type":"null"}]},"targets":{"maxItems":10,"type":"array","items":{"type":"object","properties":{"connectionId":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},"caption":{"anyOf":[{"type":"string","maxLength":63206},{"type":"null"}]}},"required":["connectionId"]}},"automation":{"anyOf":[{"type":"object","properties":{"days":{"default":7,"type":"integer","minimum":1,"maximum":90},"like":{"default":false,"type":"boolean"},"publicReply":{"default":null,"anyOf":[{"type":"string","maxLength":1000},{"type":"null"}]},"privateReply":{"default":null,"anyOf":[{"type":"string","maxLength":1000},{"type":"null"}]},"keywords":{"default":[],"maxItems":30,"type":"array","items":{"type":"string","minLength":1,"maxLength":80}},"createContacts":{"default":false,"type":"boolean"},"oncePerUser":{"default":true,"type":"boolean"}}},{"type":"null"}]}}}}}},"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"approvedAt":{"type":"null"},"approvedBy":{"type":"null"},"approvedByName":{"type":"null"},"automation":{"type":"null"},"caption":{"type":"string"},"countedAt":{"type":"null"},"createdAt":{"format":"date-time","type":"string"},"createdBy":{"format":"uuid","type":"string"},"createdByName":{"type":"string"},"firstComment":{"type":["null","string"]},"history":{"items":{"properties":{"createdAt":{"format":"date-time","type":"string"},"id":{"format":"uuid","type":"string"},"note":{"type":["null","string"]},"type":{"type":"string"},"userId":{"format":"uuid","type":"string"},"userName":{"type":"string"}},"required":["id","type","note","createdAt","userId","userName"],"type":"object"},"type":"array"},"id":{"format":"uuid","type":"string"},"media":{"items":{"properties":{"alt":{"type":"string"},"height":{"type":"integer"},"id":{"format":"uuid","type":"string"},"url":{"format":"uri","type":"string"},"width":{"type":"integer"}},"required":["id","alt","url","width","height"],"type":"object"},"type":"array"},"notes":{"type":"null"},"organizationId":{"format":"uuid","type":"string"},"publishedAt":{"type":"null"},"scheduledAt":{"format":"date-time","type":"string"},"status":{"type":"string"},"submittedAt":{"format":"date-time","type":["null","string"]},"submittedBy":{"format":"uuid","type":["null","string"]},"targets":{"items":{"properties":{"automationError":{"type":"null"},"automationId":{"type":"null"},"caption":{"type":["null","string"]},"connectionId":{"format":"uuid","type":"string"},"error":{"type":"null"},"errorDetail":{"type":"null"},"externalId":{"type":"null"},"id":{"format":"uuid","type":"string"},"label":{"type":"string"},"metrics":{"type":"null"},"network":{"type":"string"},"permalink":{"type":"null"},"publishedAt":{"type":"null"},"status":{"type":"string"}},"required":["id","connectionId","network","label","caption","status","externalId","permalink","error","errorDetail","publishedAt","automationId","automationError","metrics"],"type":"object"},"type":"array"},"title":{"type":["null","string"]},"updatedAt":{"format":"date-time","type":"string"},"updatedBy":{"format":"uuid","type":"string"}},"required":["id","organizationId","title","caption","firstComment","media","automation","notes","status","scheduledAt","createdBy","updatedBy","submittedBy","submittedAt","approvedBy","approvedAt","publishedAt","countedAt","createdAt","updatedAt","createdByName","approvedByName","targets","history"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/social-posts/{id}/approve":{"post":{"operationId":"POST /v1/social-posts/{id}/approve","summary":"Approves a post waiting for approval, scheduling it.","tags":["socialPosts"],"x-feature":"socialPosts","x-action":"update","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"approvedAt":{"format":"date-time","type":"string"},"approvedBy":{"format":"uuid","type":"string"},"approvedByName":{"type":"string"},"automation":{"type":"null"},"caption":{"type":"string"},"countedAt":{"type":"null"},"createdAt":{"format":"date-time","type":"string"},"createdBy":{"format":"uuid","type":"string"},"createdByName":{"type":"string"},"firstComment":{"type":"string"},"history":{"items":{"properties":{"createdAt":{"format":"date-time","type":"string"},"id":{"format":"uuid","type":"string"},"note":{"type":["null","string"]},"type":{"type":"string"},"userId":{"format":"uuid","type":"string"},"userName":{"type":"string"}},"required":["id","type","note","createdAt","userId","userName"],"type":"object"},"type":"array"},"id":{"format":"uuid","type":"string"},"media":{"items":{"properties":{"alt":{"type":"string"},"height":{"type":"integer"},"id":{"format":"uuid","type":"string"},"url":{"format":"uri","type":"string"},"width":{"type":"integer"}},"required":["id","alt","url","width","height"],"type":"object"},"type":"array"},"notes":{"type":"null"},"organizationId":{"format":"uuid","type":"string"},"publishedAt":{"type":"null"},"scheduledAt":{"format":"date-time","type":"string"},"status":{"type":"string"},"submittedAt":{"format":"date-time","type":"string"},"submittedBy":{"format":"uuid","type":"string"},"targets":{"items":{"properties":{"automationError":{"type":"null"},"automationId":{"type":"null"},"caption":{"type":["null","string"]},"connectionId":{"format":"uuid","type":"string"},"error":{"type":"null"},"errorDetail":{"type":"null"},"externalId":{"type":"null"},"id":{"format":"uuid","type":"string"},"label":{"type":"string"},"metrics":{"type":"null"},"network":{"type":"string"},"permalink":{"type":"null"},"publishedAt":{"type":"null"},"status":{"type":"string"}},"required":["id","connectionId","network","label","caption","status","externalId","permalink","error","errorDetail","publishedAt","automationId","automationError","metrics"],"type":"object"},"type":"array"},"title":{"type":"string"},"updatedAt":{"format":"date-time","type":"string"},"updatedBy":{"format":"uuid","type":"string"}},"required":["id","organizationId","title","caption","firstComment","media","automation","notes","status","scheduledAt","createdBy","updatedBy","submittedBy","submittedAt","approvedBy","approvedAt","publishedAt","countedAt","createdAt","updatedAt","createdByName","approvedByName","targets","history"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/social-posts/{id}/comments":{"post":{"operationId":"POST /v1/social-posts/{id}/comments","summary":"Writes a note in the post’s history, for the team.","tags":["socialPosts"],"x-feature":"socialPosts","x-action":"update","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"note":{"type":"string","minLength":1,"maxLength":2000}},"required":["note"]}}}},"responses":{"201":{"description":"Success.","content":{"application/json":{"schema":{}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/social-posts/{id}/duplicate":{"post":{"operationId":"POST /v1/social-posts/{id}/duplicate","summary":"A new draft with the same content.","tags":["socialPosts"],"x-feature":"socialPosts","x-action":"create","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"201":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"approvedAt":{"type":"null"},"approvedBy":{"type":"null"},"approvedByName":{"type":"null"},"automation":{"type":"null"},"caption":{"type":"string"},"countedAt":{"type":"null"},"createdAt":{"format":"date-time","type":"string"},"createdBy":{"format":"uuid","type":"string"},"createdByName":{"type":"string"},"firstComment":{"type":"null"},"history":{"items":{"properties":{"createdAt":{"format":"date-time","type":"string"},"id":{"format":"uuid","type":"string"},"note":{"type":"null"},"type":{"type":"string"},"userId":{"format":"uuid","type":"string"},"userName":{"type":"string"}},"required":["id","type","note","createdAt","userId","userName"],"type":"object"},"type":"array"},"id":{"format":"uuid","type":"string"},"media":{"type":"array"},"notes":{"type":"null"},"organizationId":{"format":"uuid","type":"string"},"publishedAt":{"type":"null"},"scheduledAt":{"type":"null"},"status":{"type":"string"},"submittedAt":{"type":"null"},"submittedBy":{"type":"null"},"targets":{"items":{"properties":{"automationError":{"type":"null"},"automationId":{"type":"null"},"caption":{"type":"null"},"connectionId":{"format":"uuid","type":"string"},"error":{"type":"null"},"errorDetail":{"type":"null"},"externalId":{"type":"null"},"id":{"format":"uuid","type":"string"},"label":{"type":"string"},"metrics":{"type":"null"},"network":{"type":"string"},"permalink":{"type":"null"},"publishedAt":{"type":"null"},"status":{"type":"string"}},"required":["id","connectionId","network","label","caption","status","externalId","permalink","error","errorDetail","publishedAt","automationId","automationError","metrics"],"type":"object"},"type":"array"},"title":{"type":"null"},"updatedAt":{"format":"date-time","type":"string"},"updatedBy":{"format":"uuid","type":"string"}},"required":["id","organizationId","title","caption","firstComment","media","automation","notes","status","scheduledAt","createdBy","updatedBy","submittedBy","submittedAt","approvedBy","approvedAt","publishedAt","countedAt","createdAt","updatedAt","createdByName","approvedByName","targets","history"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/social-posts/{id}/request-changes":{"post":{"operationId":"POST /v1/social-posts/{id}/request-changes","summary":"Sends a post back to its author with what to change.","tags":["socialPosts"],"x-feature":"socialPosts","x-action":"update","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"note":{"type":"string","minLength":3,"maxLength":2000}},"required":["note"]}}}},"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"approvedAt":{"type":"null"},"approvedBy":{"type":"null"},"approvedByName":{"type":"null"},"automation":{"type":"null"},"caption":{"type":"string"},"countedAt":{"type":"null"},"createdAt":{"format":"date-time","type":"string"},"createdBy":{"format":"uuid","type":"string"},"createdByName":{"type":"string"},"firstComment":{"type":"string"},"history":{"items":{"properties":{"createdAt":{"format":"date-time","type":"string"},"id":{"format":"uuid","type":"string"},"note":{"type":["null","string"]},"type":{"type":"string"},"userId":{"format":"uuid","type":"string"},"userName":{"type":"string"}},"required":["id","type","note","createdAt","userId","userName"],"type":"object"},"type":"array"},"id":{"format":"uuid","type":"string"},"media":{"items":{"properties":{"alt":{"type":"string"},"height":{"type":"integer"},"id":{"format":"uuid","type":"string"},"url":{"format":"uri","type":"string"},"width":{"type":"integer"}},"required":["id","alt","url","width","height"],"type":"object"},"type":"array"},"notes":{"type":"null"},"organizationId":{"format":"uuid","type":"string"},"publishedAt":{"type":"null"},"scheduledAt":{"format":"date-time","type":"string"},"status":{"type":"string"},"submittedAt":{"format":"date-time","type":"string"},"submittedBy":{"format":"uuid","type":"string"},"targets":{"items":{"properties":{"automationError":{"type":"null"},"automationId":{"type":"null"},"caption":{"type":["null","string"]},"connectionId":{"format":"uuid","type":"string"},"error":{"type":"null"},"errorDetail":{"type":"null"},"externalId":{"type":"null"},"id":{"format":"uuid","type":"string"},"label":{"type":"string"},"metrics":{"type":"null"},"network":{"type":"string"},"permalink":{"type":"null"},"publishedAt":{"type":"null"},"status":{"type":"string"}},"required":["id","connectionId","network","label","caption","status","externalId","permalink","error","errorDetail","publishedAt","automationId","automationError","metrics"],"type":"object"},"type":"array"},"title":{"type":"string"},"updatedAt":{"format":"date-time","type":"string"},"updatedBy":{"format":"uuid","type":"string"}},"required":["id","organizationId","title","caption","firstComment","media","automation","notes","status","scheduledAt","createdBy","updatedBy","submittedBy","submittedAt","approvedBy","approvedAt","publishedAt","countedAt","createdAt","updatedAt","createdByName","approvedByName","targets","history"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/social-posts/{id}/retry":{"post":{"operationId":"POST /v1/social-posts/{id}/retry","summary":"Tries again the accounts where the post failed.","tags":["socialPosts"],"x-feature":"socialPosts","x-action":"update","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"approvedAt":{"format":"date-time","type":"string"},"approvedBy":{"format":"uuid","type":"string"},"approvedByName":{"type":"string"},"automation":{"type":"null"},"caption":{"type":"string"},"countedAt":{"format":"date-time","type":"string"},"createdAt":{"format":"date-time","type":"string"},"createdBy":{"format":"uuid","type":"string"},"createdByName":{"type":"string"},"firstComment":{"type":"null"},"history":{"items":{"properties":{"createdAt":{"format":"date-time","type":"string"},"id":{"format":"uuid","type":"string"},"note":{"type":["null","string"]},"type":{"type":"string"},"userId":{"format":"uuid","type":["null","string"]},"userName":{"type":["null","string"]}},"required":["id","type","note","createdAt","userId","userName"],"type":"object"},"type":"array"},"id":{"format":"uuid","type":"string"},"media":{"items":{"properties":{"alt":{"type":"null"},"height":{"type":"integer"},"id":{"format":"uuid","type":"string"},"url":{"format":"uri","type":"string"},"width":{"type":"integer"}},"required":["id","alt","url","width","height"],"type":"object"},"type":"array"},"notes":{"type":"null"},"organizationId":{"format":"uuid","type":"string"},"publishedAt":{"type":"null"},"scheduledAt":{"format":"date-time","type":"string"},"status":{"type":"string"},"submittedAt":{"format":"date-time","type":"string"},"submittedBy":{"format":"uuid","type":"string"},"targets":{"items":{"properties":{"automationError":{"type":"null"},"automationId":{"type":"null"},"caption":{"type":"null"},"connectionId":{"format":"uuid","type":"string"},"error":{"type":"null"},"errorDetail":{"type":"null"},"externalId":{"type":["null","string"]},"id":{"format":"uuid","type":"string"},"label":{"type":"string"},"metrics":{"properties":{"error":{"type":"null"},"fetchedAt":{"type":"null"},"metrics":{"type":"null"},"nextFetchAt":{"format":"date-time","type":"string"}},"required":["metrics","fetchedAt","nextFetchAt","error"],"type":["null","object"]},"network":{"type":"string"},"permalink":{"format":"uri","type":["null","string"]},"publishedAt":{"format":"date-time","type":["null","string"]},"status":{"type":"string"}},"required":["id","connectionId","network","label","caption","status","externalId","permalink","error","errorDetail","publishedAt","automationId","automationError","metrics"],"type":"object"},"type":"array"},"title":{"type":"null"},"updatedAt":{"format":"date-time","type":"string"},"updatedBy":{"format":"uuid","type":"string"}},"required":["id","organizationId","title","caption","firstComment","media","automation","notes","status","scheduledAt","createdBy","updatedBy","submittedBy","submittedAt","approvedBy","approvedAt","publishedAt","countedAt","createdAt","updatedAt","createdByName","approvedByName","targets","history"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/social-posts/{id}/schedule":{"post":{"operationId":"POST /v1/social-posts/{id}/schedule","summary":"Schedules a post, or sends it for approval when that is required.","tags":["socialPosts"],"x-feature":"socialPosts","x-action":"update","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"now":{"default":false,"type":"boolean"}}}}}},"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"approvedAt":{"format":"date-time","type":["null","string"]},"approvedBy":{"format":"uuid","type":["null","string"]},"approvedByName":{"type":["null","string"]},"automation":{"properties":{"createContacts":{"type":"boolean"},"days":{"type":"integer"},"keywords":{"items":{"type":"string"},"type":"array"},"like":{"type":"boolean"},"oncePerUser":{"type":"boolean"},"privateReply":{"type":"string"},"publicReply":{"type":"null"}},"required":["days","like","keywords","oncePerUser","publicReply","privateReply","createContacts"],"type":["null","object"]},"caption":{"type":"string"},"countedAt":{"type":"null"},"createdAt":{"format":"date-time","type":"string"},"createdBy":{"format":"uuid","type":"string"},"createdByName":{"type":"string"},"firstComment":{"type":["null","string"]},"history":{"items":{"properties":{"createdAt":{"format":"date-time","type":"string"},"id":{"format":"uuid","type":"string"},"note":{"type":["null","string"]},"type":{"type":"string"},"userId":{"format":"uuid","type":"string"},"userName":{"type":"string"}},"required":["id","type","note","createdAt","userId","userName"],"type":"object"},"type":"array"},"id":{"format":"uuid","type":"string"},"media":{"items":{"properties":{"alt":{"type":["null","string"]},"height":{"type":"integer"},"id":{"format":"uuid","type":"string"},"url":{"format":"uri","type":"string"},"width":{"type":"integer"}},"required":["id","alt","url","width","height"],"type":"object"},"type":"array"},"notes":{"type":"null"},"organizationId":{"format":"uuid","type":"string"},"publishedAt":{"type":"null"},"scheduledAt":{"format":"date-time","type":"string"},"status":{"type":"string"},"submittedAt":{"format":"date-time","type":"string"},"submittedBy":{"format":"uuid","type":"string"},"targets":{"items":{"properties":{"automationError":{"type":"null"},"automationId":{"type":"null"},"caption":{"type":["null","string"]},"connectionId":{"format":"uuid","type":"string"},"error":{"type":"null"},"errorDetail":{"type":"null"},"externalId":{"type":"null"},"id":{"format":"uuid","type":"string"},"label":{"type":"string"},"metrics":{"type":"null"},"network":{"type":"string"},"permalink":{"type":"null"},"publishedAt":{"type":"null"},"status":{"type":"string"}},"required":["id","connectionId","network","label","caption","status","externalId","permalink","error","errorDetail","publishedAt","automationId","automationError","metrics"],"type":"object"},"type":"array"},"title":{"type":["null","string"]},"updatedAt":{"format":"date-time","type":"string"},"updatedBy":{"format":"uuid","type":"string"}},"required":["id","organizationId","title","caption","firstComment","media","automation","notes","status","scheduledAt","createdBy","updatedBy","submittedBy","submittedAt","approvedBy","approvedAt","publishedAt","countedAt","createdAt","updatedAt","createdByName","approvedByName","targets","history"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/social-posts/{id}/unschedule":{"post":{"operationId":"POST /v1/social-posts/{id}/unschedule","summary":"Takes a post off the schedule, back to draft.","tags":["socialPosts"],"x-feature":"socialPosts","x-action":"update","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/social-posts/media":{"post":{"operationId":"POST /v1/social-posts/media","summary":"Uploads a picture for posts.","tags":["socialPosts"],"x-feature":"socialPosts","x-action":"create","requestBody":{"required":true,"content":{"multipart/form-data":{"schema":{"type":"object","required":["file"],"properties":{"file":{"type":"string","format":"binary"}}}}}},"responses":{"201":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"alt":{"type":"null"},"height":{"type":"integer"},"id":{"format":"uuid","type":"string"},"url":{"format":"uri","type":"string"},"width":{"type":"integer"}},"required":["id","url","width","height","alt"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/social-posts/overview":{"get":{"operationId":"GET /v1/social-posts/overview","summary":"The accounts posts can go to, the approval rules and what the caller may do.","tags":["socialPosts"],"x-feature":"socialPosts","x-action":"read","responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"accounts":{"items":{"properties":{"canPublish":{"type":"boolean"},"id":{"format":"uuid","type":"string"},"label":{"type":"string"},"network":{"type":"string"},"reconnectRequired":{"type":"boolean"}},"required":["id","network","label","canPublish","reconnectRequired"],"type":"object"},"type":"array"},"canApprove":{"type":"boolean"},"pendingApproval":{"type":"integer"},"publishingEnabled":{"type":"boolean"},"settings":{"properties":{"approverMemberIds":{"items":{"format":"uuid","type":"string"},"type":"array"},"approverRole":{"type":"string"},"requireApproval":{"type":"boolean"}},"required":["requireApproval","approverRole","approverMemberIds"],"type":"object"}},"required":["settings","canApprove","pendingApproval","publishingEnabled","accounts"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/social-posts/settings":{"put":{"operationId":"PUT /v1/social-posts/settings","summary":"Whether posts need approval and who approves (administrators).","tags":["socialPosts"],"x-feature":"socialPosts","x-action":"update","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"requireApproval":{"type":"boolean"},"approverRole":{"type":"string","enum":["editor","admin","owner"]},"approverMemberIds":{"default":[],"maxItems":100,"type":"array","items":{"type":"string","minLength":1,"maxLength":100}}},"required":["requireApproval","approverRole"]}}}},"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"accounts":{"items":{"properties":{"canPublish":{"type":"boolean"},"id":{"format":"uuid","type":"string"},"label":{"type":"string"},"network":{"type":"string"},"reconnectRequired":{"type":"boolean"}},"required":["id","network","label","canPublish","reconnectRequired"],"type":"object"},"type":"array"},"canApprove":{"type":"boolean"},"pendingApproval":{"type":"integer"},"publishingEnabled":{"type":"boolean"},"settings":{"properties":{"approverMemberIds":{"items":{"format":"uuid","type":"string"},"type":"array"},"approverRole":{"type":"string"},"requireApproval":{"type":"boolean"}},"required":["requireApproval","approverRole","approverMemberIds"],"type":"object"}},"required":["settings","canApprove","pendingApproval","publishingEnabled","accounts"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/surveys":{"get":{"operationId":"GET /v1/surveys","summary":"Lists the surveys.","tags":["surveys"],"x-feature":"surveys","x-action":"read","responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"post":{"operationId":"POST /v1/surveys","summary":"Creates a survey.","tags":["surveys"],"x-feature":"surveys","x-action":"create","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"name":{"type":"string","minLength":1,"maxLength":120},"title":{"anyOf":[{"type":"string","maxLength":200},{"type":"null"}]},"description":{"anyOf":[{"type":"string","maxLength":2000},{"type":"null"}]},"questions":{"maxItems":50,"type":"array","items":{"type":"object","properties":{"key":{"type":"string","pattern":"^[a-z][a-z0-9_]{0,39}$"},"type":{"type":"string","enum":["text","textarea","email","phone","number","date","url","select","radio","checkboxes","checkbox","rating","nps"]},"label":{"type":"string","minLength":1,"maxLength":500},"placeholder":{"anyOf":[{"type":"string","maxLength":200},{"type":"null"}]},"help":{"anyOf":[{"type":"string","maxLength":500},{"type":"null"}]},"required":{"default":false,"type":"boolean"},"options":{"default":[],"maxItems":100,"type":"array","items":{"type":"string","minLength":1,"maxLength":200}},"min":{"type":["number","null"]},"max":{"type":["number","null"]},"defaultValue":{"anyOf":[{"type":"string","maxLength":500},{"type":"null"}]},"width":{"default":"full","type":"string","enum":["full","half"]}},"required":["key","type","label"]}},"submitLabel":{"anyOf":[{"type":"string","maxLength":60},{"type":"null"}]},"successMessage":{"anyOf":[{"type":"string","maxLength":1000},{"type":"null"}]},"status":{"default":"draft","type":"string","enum":["draft","active","closed"]},"anonymous":{"default":false,"type":"boolean"},"singleResponse":{"default":true,"type":"boolean"},"responseWindowDays":{"anyOf":[{"type":"integer","minimum":1,"maximum":365},{"type":"null"}]},"openLink":{"default":false,"type":"boolean"},"closesAt":{"anyOf":[{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"},{"type":"null"}]},"delivery":{"default":{},"type":"object","properties":{"email":{"default":true,"type":"boolean"},"whatsapp":{"default":{},"type":"object","properties":{"enabled":{"default":false,"type":"boolean"},"connectionId":{"anyOf":[{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},{"type":"null"}]},"templateName":{"anyOf":[{"type":"string","pattern":"^[a-z0-9_]{1,512}$"},{"type":"null"}]},"language":{"anyOf":[{"type":"string","pattern":"^[a-z]{2,3}(_[A-Z]{2})?$"},{"type":"null"}]},"params":{"default":{},"type":"object","propertyNames":{"type":"string","maxLength":100},"additionalProperties":{"type":"string","enum":["link","firstName","name","surveyTitle","organization","deadline"]}}}},"reminderDaysBefore":{"anyOf":[{"type":"integer","minimum":1,"maximum":60},{"type":"null"}]},"message":{"anyOf":[{"type":"string","maxLength":2000},{"type":"null"}]}}},"triggers":{"default":{},"type":"object","properties":{"lists":{"default":[],"maxItems":10,"type":"array","items":{"type":"object","properties":{"listId":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"}},"required":["listId"]}},"events":{"maxItems":10,"type":"array","items":{"type":"object","properties":{"type":{"type":"string","enum":["deal.accepted","invoice.paid","form.submitted","appointment.completed"]},"formId":{"anyOf":[{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},{"type":"null"}]},"delayHours":{"default":0,"type":"integer","minimum":0,"maximum":1440}},"required":["type"]}}}},"notifyMemberIds":{"default":[],"maxItems":50,"type":"array","items":{"type":"string","minLength":1}},"templateId":{"anyOf":[{"type":"string","enum":["classic","modern","minimal","bold"]},{"type":"null"}]},"theme":{"default":{},"type":"object","properties":{"primaryColor":{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"accentColor":{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"backgroundColor":{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"textColor":{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"headingFont":{"type":"string","pattern":"^[A-Za-z0-9 ]{1,60}$"},"bodyFont":{"type":"string","pattern":"^[A-Za-z0-9 ]{1,60}$"},"coverImageUrl":{"type":"string","maxLength":2000,"format":"uri"},"cornerRadius":{"type":"string","enum":["none","small","medium","large"]}},"additionalProperties":false}},"required":["name"]}}}},"responses":{"201":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"activatedAt":{"format":"date-time","type":["null","string"]},"anonymous":{"type":"boolean"},"closesAt":{"type":"null"},"createdAt":{"format":"date-time","type":"string"},"createdBy":{"format":"uuid","type":"string"},"delivery":{"properties":{"email":{"type":"boolean"},"message":{"type":"null"},"reminderDaysBefore":{"type":"null"},"whatsapp":{"properties":{"connectionId":{"type":"null"},"enabled":{"type":"boolean"},"language":{"type":"null"},"params":{"properties":{},"required":[],"type":"object"},"templateName":{"type":"null"}},"required":["connectionId","enabled","language","params","templateName"],"type":"object"}},"required":["email","message","reminderDaysBefore","whatsapp"],"type":"object"},"description":{"type":"null"},"id":{"format":"uuid","type":"string"},"name":{"type":"string"},"notifyMemberIds":{"items":{"format":"uuid","type":"string"},"type":"array"},"openLink":{"type":"boolean"},"publicId":{"type":"string"},"questions":{"items":{"properties":{"defaultValue":{"type":"null"},"help":{"type":"null"},"key":{"type":"string"},"label":{"type":"string"},"max":{"type":["integer","null"]},"min":{"type":"null"},"options":{"items":{"type":"string"},"type":"array"},"placeholder":{"type":"null"},"required":{"type":"boolean"},"type":{"type":"string"},"width":{"type":"string"}},"required":["defaultValue","help","key","label","max","min","options","placeholder","required","type","width"],"type":"object"},"type":"array"},"responseWindowDays":{"type":["integer","null"]},"singleResponse":{"type":"boolean"},"stats":{"properties":{"answered":{"type":"integer"},"expired":{"type":"integer"},"invited":{"type":"integer"},"lastResponseAt":{"type":"null"},"pending":{"type":"integer"},"responseRate":{"type":"null"},"responses":{"type":"integer"}},"required":["answered","expired","invited","lastResponseAt","pending","responseRate","responses"],"type":"object"},"status":{"type":"string"},"submitLabel":{"type":"null"},"successMessage":{"type":"null"},"templateId":{"type":"null"},"theme":{"properties":{},"required":[],"type":"object"},"title":{"type":["null","string"]},"triggers":{"properties":{"events":{"items":{"properties":{"delayHours":{"type":"integer"},"formId":{"format":"uuid","type":"string"},"type":{"type":"string"}},"required":["type","formId","delayHours"],"type":"object"},"type":"array"},"lists":{"items":{"properties":{"listId":{"format":"uuid","type":"string"}},"required":["listId"],"type":"object"},"type":"array"}},"required":["events","lists"],"type":"object"},"updatedAt":{"format":"date-time","type":"string"},"updatedBy":{"format":"uuid","type":"string"},"url":{"format":"uri","type":"string"}},"required":["activatedAt","anonymous","closesAt","createdAt","createdBy","delivery","description","id","name","notifyMemberIds","openLink","publicId","questions","responseWindowDays","singleResponse","stats","status","submitLabel","successMessage","templateId","theme","title","triggers","updatedAt","updatedBy","url"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/surveys/{id}":{"delete":{"operationId":"DELETE /v1/surveys/{id}","summary":"Deletes a survey and its answers.","tags":["surveys"],"x-feature":"surveys","x-action":"delete","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"204":{"description":"Done, with no content."},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"get":{"operationId":"GET /v1/surveys/{id}","summary":"Returns a survey with its questions and settings.","tags":["surveys"],"x-feature":"surveys","x-action":"read","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"patch":{"operationId":"PATCH /v1/surveys/{id}","summary":"Changes a survey: questions, look, triggers and status.","tags":["surveys"],"x-feature":"surveys","x-action":"update","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"name":{"type":"string","minLength":1,"maxLength":120},"title":{"anyOf":[{"type":"string","maxLength":200},{"type":"null"}]},"description":{"anyOf":[{"type":"string","maxLength":2000},{"type":"null"}]},"questions":{"maxItems":50,"type":"array","items":{"type":"object","properties":{"key":{"type":"string","pattern":"^[a-z][a-z0-9_]{0,39}$"},"type":{"type":"string","enum":["text","textarea","email","phone","number","date","url","select","radio","checkboxes","checkbox","rating","nps"]},"label":{"type":"string","minLength":1,"maxLength":500},"placeholder":{"anyOf":[{"type":"string","maxLength":200},{"type":"null"}]},"help":{"anyOf":[{"type":"string","maxLength":500},{"type":"null"}]},"required":{"default":false,"type":"boolean"},"options":{"default":[],"maxItems":100,"type":"array","items":{"type":"string","minLength":1,"maxLength":200}},"min":{"type":["number","null"]},"max":{"type":["number","null"]},"defaultValue":{"anyOf":[{"type":"string","maxLength":500},{"type":"null"}]},"width":{"default":"full","type":"string","enum":["full","half"]}},"required":["key","type","label"]}},"submitLabel":{"anyOf":[{"type":"string","maxLength":60},{"type":"null"}]},"successMessage":{"anyOf":[{"type":"string","maxLength":1000},{"type":"null"}]},"status":{"type":"string","enum":["draft","active","closed"]},"anonymous":{"type":"boolean"},"singleResponse":{"type":"boolean"},"responseWindowDays":{"anyOf":[{"type":"integer","minimum":1,"maximum":365},{"type":"null"}]},"openLink":{"type":"boolean"},"closesAt":{"anyOf":[{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z|([+-](?:[01]\\d|2[0-3]):[0-5]\\d)))$"},{"type":"null"}]},"delivery":{"type":"object","properties":{"email":{"default":true,"type":"boolean"},"whatsapp":{"default":{},"type":"object","properties":{"enabled":{"default":false,"type":"boolean"},"connectionId":{"anyOf":[{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},{"type":"null"}]},"templateName":{"anyOf":[{"type":"string","pattern":"^[a-z0-9_]{1,512}$"},{"type":"null"}]},"language":{"anyOf":[{"type":"string","pattern":"^[a-z]{2,3}(_[A-Z]{2})?$"},{"type":"null"}]},"params":{"default":{},"type":"object","propertyNames":{"type":"string","maxLength":100},"additionalProperties":{"type":"string","enum":["link","firstName","name","surveyTitle","organization","deadline"]}}}},"reminderDaysBefore":{"anyOf":[{"type":"integer","minimum":1,"maximum":60},{"type":"null"}]},"message":{"anyOf":[{"type":"string","maxLength":2000},{"type":"null"}]}}},"triggers":{"type":"object","properties":{"lists":{"default":[],"maxItems":10,"type":"array","items":{"type":"object","properties":{"listId":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"}},"required":["listId"]}},"events":{"maxItems":10,"type":"array","items":{"type":"object","properties":{"type":{"type":"string","enum":["deal.accepted","invoice.paid","form.submitted","appointment.completed"]},"formId":{"anyOf":[{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},{"type":"null"}]},"delayHours":{"default":0,"type":"integer","minimum":0,"maximum":1440}},"required":["type"]}}}},"notifyMemberIds":{"maxItems":50,"type":"array","items":{"type":"string","minLength":1}},"templateId":{"anyOf":[{"type":"string","enum":["classic","modern","minimal","bold"]},{"type":"null"}]},"theme":{"type":"object","properties":{"primaryColor":{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"accentColor":{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"backgroundColor":{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"textColor":{"type":"string","pattern":"^#[0-9a-fA-F]{6}$"},"headingFont":{"type":"string","pattern":"^[A-Za-z0-9 ]{1,60}$"},"bodyFont":{"type":"string","pattern":"^[A-Za-z0-9 ]{1,60}$"},"coverImageUrl":{"type":"string","maxLength":2000,"format":"uri"},"cornerRadius":{"type":"string","enum":["none","small","medium","large"]}},"additionalProperties":false}}}}}},"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"activatedAt":{"format":"date-time","type":"string"},"anonymous":{"type":"boolean"},"closesAt":{"type":"null"},"createdAt":{"format":"date-time","type":"string"},"createdBy":{"format":"uuid","type":"string"},"delivery":{"properties":{"email":{"type":"boolean"},"message":{"type":"null"},"reminderDaysBefore":{"type":"null"},"whatsapp":{"properties":{"connectionId":{"type":"null"},"enabled":{"type":"boolean"},"language":{"type":"null"},"params":{"properties":{},"required":[],"type":"object"},"templateName":{"type":"null"}},"required":["params","enabled","language","connectionId","templateName"],"type":"object"}},"required":["email","message","whatsapp","reminderDaysBefore"],"type":"object"},"description":{"type":"null"},"id":{"format":"uuid","type":"string"},"name":{"type":"string"},"notifyMemberIds":{"items":{"format":"uuid","type":"string"},"type":"array"},"openLink":{"type":"boolean"},"publicId":{"type":"string"},"questions":{"items":{"properties":{"defaultValue":{"type":"null"},"help":{"type":"null"},"key":{"type":"string"},"label":{"type":"string"},"max":{"type":["integer","null"]},"min":{"type":"null"},"options":{"items":{"type":"string"},"type":"array"},"placeholder":{"type":"null"},"required":{"type":"boolean"},"type":{"type":"string"},"width":{"type":"string"}},"required":["key","max","min","help","type","label","width","options","required","placeholder","defaultValue"],"type":"object"},"type":"array"},"responseWindowDays":{"type":["integer","null"]},"singleResponse":{"type":"boolean"},"stats":{"properties":{"answered":{"type":"integer"},"expired":{"type":"integer"},"invited":{"type":"integer"},"lastResponseAt":{"format":"date-time","type":["null","string"]},"pending":{"type":"integer"},"responseRate":{"type":"null"},"responses":{"type":"integer"}},"required":["invited","answered","expired","pending","responses","lastResponseAt","responseRate"],"type":"object"},"status":{"type":"string"},"submitLabel":{"type":"null"},"successMessage":{"type":"null"},"templateId":{"type":"null"},"theme":{"properties":{},"required":[],"type":"object"},"title":{"type":["null","string"]},"triggers":{"properties":{"events":{"type":"array"},"lists":{"type":"array"}},"required":["lists","events"],"type":"object"},"updatedAt":{"format":"date-time","type":"string"},"updatedBy":{"format":"uuid","type":"string"},"url":{"format":"uri","type":"string"}},"required":["id","publicId","name","title","description","questions","submitLabel","successMessage","status","anonymous","singleResponse","responseWindowDays","openLink","closesAt","delivery","triggers","notifyMemberIds","templateId","theme","activatedAt","createdBy","updatedBy","createdAt","updatedAt","url","stats"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/surveys/{id}/duplicate":{"post":{"operationId":"POST /v1/surveys/{id}/duplicate","summary":"Copies a survey.","tags":["surveys"],"x-feature":"surveys","x-action":"create","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"name":{"type":"string","minLength":1,"maxLength":120}},"required":["name"]}}}},"responses":{"201":{"description":"Success.","content":{"application/json":{"schema":{}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/surveys/{id}/recipients":{"get":{"operationId":"GET /v1/surveys/{id}/recipients","summary":"The contacts invited to a survey, and whether they answered.","tags":["surveys"],"x-feature":"surveys","x-action":"read","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}},{"name":"page","in":"query","required":false,"schema":{"default":1,"type":"integer","minimum":1,"maximum":9007199254740991}},{"name":"pageSize","in":"query","required":false,"schema":{"default":25,"type":"integer","minimum":1,"maximum":100}},{"name":"status","in":"query","required":false,"schema":{"type":"string","enum":["pending","answered","expired"]}},{"name":"q","in":"query","required":false,"schema":{"type":"string","maxLength":200}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"data":{"items":{"properties":{"addedBy":{"format":"uuid","type":["null","string"]},"contact":{"properties":{"email":{"format":"email","type":"string"},"id":{"format":"uuid","type":"string"},"name":{"type":"string"},"phone":{"type":"null"}},"required":["id","name","email","phone"],"type":"object"},"contactId":{"format":"uuid","type":"string"},"expiresAt":{"format":"date-time","type":["null","string"]},"id":{"format":"uuid","type":"string"},"invitedAt":{"format":"date-time","type":"string"},"notifiedAt":{"format":"date-time","type":["null","string"]},"notifiedVia":{"items":{"type":"string"},"type":"array"},"notifyAt":{"format":"date-time","type":["null","string"]},"notifyError":{"type":"null"},"openedAt":{"type":"null"},"remindedAt":{"type":"null"},"respondedAt":{"format":"date-time","type":["null","string"]},"responseCount":{"type":"integer"},"source":{"type":"string"},"sourceRef":{"type":["null","string"]},"status":{"type":"string"},"surveyId":{"format":"uuid","type":"string"},"url":{"format":"uri","type":"string"}},"required":["id","surveyId","contactId","source","sourceRef","invitedAt","notifyAt","expiresAt","notifiedAt","notifiedVia","notifyError","remindedAt","openedAt","respondedAt","responseCount","addedBy","status","url","contact"],"type":"object"},"type":"array"},"page":{"type":"integer"},"pageSize":{"type":"integer"},"total":{"type":"integer"}},"required":["data","page","pageSize","total"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"post":{"operationId":"POST /v1/surveys/{id}/recipients","summary":"Invites contacts, by id or everyone in a list now.","tags":["surveys"],"x-feature":"surveys","x-action":"update","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"contactIds":{"default":[],"maxItems":1000,"type":"array","items":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"}},"listId":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"}}}}}},"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"invited":{"type":"integer"},"limited":{"type":"integer"},"skipped":{"type":"integer"}},"required":["invited","skipped","limited"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/surveys/{id}/recipients/{recipientId}":{"delete":{"operationId":"DELETE /v1/surveys/{id}/recipients/{recipientId}","summary":"Removes an invitation.","tags":["surveys"],"x-feature":"surveys","x-action":"update","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}},{"name":"recipientId","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"204":{"description":"Done, with no content."},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/surveys/{id}/recipients/{recipientId}/resend":{"post":{"operationId":"POST /v1/surveys/{id}/recipients/{recipientId}/resend","summary":"Emails an invited contact their link again.","tags":["surveys"],"x-feature":"surveys","x-action":"update","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}},{"name":"recipientId","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/surveys/{id}/responses":{"get":{"operationId":"GET /v1/surveys/{id}/responses","summary":"Lists a survey’s answers.","tags":["surveys"],"x-feature":"surveys","x-action":"read","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}},{"name":"page","in":"query","required":false,"schema":{"default":1,"type":"integer","minimum":1,"maximum":9007199254740991}},{"name":"pageSize","in":"query","required":false,"schema":{"default":25,"type":"integer","minimum":1,"maximum":100}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"data":{"items":{"properties":{"answers":{"items":{"properties":{"key":{"type":"string"},"label":{"type":"string"},"type":{"type":"string"},"value":{"items":{"type":"string"},"type":["array","integer","null","string"]}},"required":["key","type","label","value"],"type":"object"},"type":"array"},"contact":{"properties":{"id":{"format":"uuid","type":"string"},"name":{"type":"string"}},"required":["id","name"],"type":"object"},"contactId":{"format":"uuid","type":"string"},"createdAt":{"format":"date-time","type":"string"},"id":{"format":"uuid","type":"string"},"recipientId":{"format":"uuid","type":"string"},"source":{"type":"string"},"surveyId":{"format":"uuid","type":"string"}},"required":["id","surveyId","recipientId","contactId","answers","source","createdAt","contact"],"type":"object"},"type":"array"},"page":{"type":"integer"},"pageSize":{"type":"integer"},"total":{"type":"integer"}},"required":["data","page","pageSize","total"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"post":{"operationId":"POST /v1/surveys/{id}/responses","summary":"Answers a survey from the organization’s own systems, as a contact would.","tags":["surveys"],"x-feature":"surveys","x-action":"create","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"answers":{"type":"object","propertyNames":{"type":"string"},"additionalProperties":{}},"contactId":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"}},"required":["answers"]}}}},"responses":{"201":{"description":"Success.","content":{"application/json":{"schema":{}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/surveys/{id}/responses/{responseId}":{"delete":{"operationId":"DELETE /v1/surveys/{id}/responses/{responseId}","summary":"Deletes one answer.","tags":["surveys"],"x-feature":"surveys","x-action":"delete","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}},{"name":"responseId","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"204":{"description":"Done, with no content."},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"get":{"operationId":"GET /v1/surveys/{id}/responses/{responseId}","summary":"Returns one answer.","tags":["surveys"],"x-feature":"surveys","x-action":"read","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}},{"name":"responseId","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/surveys/{id}/responses/export":{"get":{"operationId":"GET /v1/surveys/{id}/responses/export","summary":"Downloads a survey’s answers as a CSV file.","tags":["surveys"],"x-feature":"surveys","x-action":"read","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/surveys/{id}/summary":{"get":{"operationId":"GET /v1/surveys/{id}/summary","summary":"A survey’s results: score, distribution and answers per question.","tags":["surveys"],"x-feature":"surveys","x-action":"read","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"daily":{"items":{"properties":{"date":{"format":"date","type":"string"},"total":{"type":"integer"}},"required":["date","total"],"type":"object"},"type":"array"},"questions":{"items":{"properties":{"answered":{"type":"integer"},"average":{"type":"number"},"choices":{"items":{"properties":{"count":{"type":"integer"},"option":{"type":"string"}},"required":["option","count"],"type":"object"},"type":"array"},"distribution":{"items":{"properties":{"count":{"type":"integer"},"value":{"type":"integer"}},"required":["value","count"],"type":"object"},"type":"array"},"key":{"type":"string"},"label":{"type":"string"},"nps":{"type":["integer","null"]},"samples":{"items":{"type":"string"},"type":"array"},"type":{"type":"string"}},"required":["key","label","type","answered"],"type":"object"},"type":"array"},"stats":{"properties":{"answered":{"type":"integer"},"expired":{"type":"integer"},"invited":{"type":"integer"},"lastResponseAt":{"format":"date-time","type":"string"},"pending":{"type":"integer"},"responseRate":{"type":"integer"},"responses":{"type":"integer"}},"required":["invited","answered","expired","pending","responses","lastResponseAt","responseRate"],"type":"object"}},"required":["stats","questions","daily"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/surveys/look":{"get":{"operationId":"GET /v1/surveys/look","summary":"The look a survey’s preview starts from; saves nothing.","tags":["surveys"],"x-feature":"surveys","x-action":"read","parameters":[{"name":"templateId","in":"query","required":false,"schema":{"type":"string","enum":["classic","modern","minimal","bold"]}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"organization":{"properties":{"language":{"type":"string"},"name":{"type":"string"}},"required":["name","language"],"type":"object"},"templateId":{"type":"string"},"theme":{"properties":{"accentColor":{"type":"string"},"backgroundColor":{"type":"string"},"bodyFont":{"type":"string"},"cornerRadius":{"type":"string"},"headingFont":{"type":"string"},"primaryColor":{"type":"string"},"textColor":{"type":"string"}},"required":["primaryColor","accentColor","backgroundColor","textColor","headingFont","bodyFont","cornerRadius"],"type":"object"}},"required":["organization","templateId","theme"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/tags":{"get":{"operationId":"GET /v1/tags","summary":"Lists the contact tags, with how many contacts each has.","tags":["contacts"],"x-feature":"contacts","x-action":"read","responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"items":{"properties":{"color":{"type":"string"},"contactCount":{"type":"integer"},"createdAt":{"format":"date-time","type":"string"},"id":{"format":"uuid","type":"string"},"name":{"type":"string"}},"required":["id","name","color","createdAt","contactCount"],"type":"object"},"type":"array"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"post":{"operationId":"POST /v1/tags","summary":"Creates a tag.","tags":["contacts"],"x-feature":"contacts","x-action":"create","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"name":{"type":"string","minLength":1,"maxLength":50},"color":{"default":"gray","type":"string","enum":["gray","red","orange","yellow","green","teal","blue","purple","pink"]}},"required":["name"]}}}},"responses":{"201":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"color":{"type":"string"},"contactCount":{"type":"integer"},"createdAt":{"format":"date-time","type":"string"},"id":{"format":"uuid","type":"string"},"name":{"type":"string"}},"required":["color","contactCount","createdAt","id","name"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/tags/{id}":{"delete":{"operationId":"DELETE /v1/tags/{id}","summary":"Deletes a tag, taking it off its contacts.","tags":["contacts"],"x-feature":"contacts","x-action":"delete","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"204":{"description":"Done, with no content."},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"patch":{"operationId":"PATCH /v1/tags/{id}","summary":"Renames a tag or changes its color.","tags":["contacts"],"x-feature":"contacts","x-action":"update","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"name":{"type":"string","minLength":1,"maxLength":50},"color":{"type":"string","enum":["gray","red","orange","yellow","green","teal","blue","purple","pink"]}}}}}},"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"color":{"type":"string"},"contactCount":{"type":"integer"},"createdAt":{"format":"date-time","type":"string"},"id":{"format":"uuid","type":"string"},"name":{"type":"string"}},"required":["id","name","color","createdAt","contactCount"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/tags/{id}/contacts":{"post":{"operationId":"POST /v1/tags/{id}/contacts","summary":"Adds a tag to contacts.","tags":["contacts"],"x-feature":"contacts","x-action":"update","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"contactIds":{"minItems":1,"maxItems":500,"type":"array","items":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"}}},"required":["contactIds"]}}}},"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"added":{"type":"integer"},"already":{"type":"integer"},"full":{"type":"integer"}},"required":["added","already","full"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/tags/{id}/contacts/remove":{"post":{"operationId":"POST /v1/tags/{id}/contacts/remove","summary":"Takes a tag off contacts.","tags":["contacts"],"x-feature":"contacts","x-action":"update","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"contactIds":{"minItems":1,"maxItems":500,"type":"array","items":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"}}},"required":["contactIds"]}}}},"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"removed":{"type":"integer"}},"required":["removed"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/tasks":{"get":{"operationId":"GET /v1/tasks","summary":"Lists tasks, by status, owner, priority or due date.","tags":["tasks"],"x-feature":"tasks","x-action":"read","parameters":[{"name":"page","in":"query","required":false,"schema":{"default":1,"type":"integer","minimum":1,"maximum":9007199254740991}},{"name":"pageSize","in":"query","required":false,"schema":{"default":25,"type":"integer","minimum":1,"maximum":100}},{"name":"q","in":"query","required":false,"schema":{"type":"string","minLength":1,"maxLength":200}},{"name":"archived","in":"query","required":false,"schema":{"type":"string"}},{"name":"contactId","in":"query","required":false,"schema":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"}},{"name":"companyId","in":"query","required":false,"schema":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"}},{"name":"projectId","in":"query","required":false,"schema":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"}},{"name":"status","in":"query","required":false,"schema":{"minItems":1,"maxItems":10,"type":"array","items":{"type":"string","enum":["suggested","open","in_progress","done","canceled"]}}},{"name":"priority","in":"query","required":false,"schema":{"minItems":1,"maxItems":10,"type":"array","items":{"type":"string","enum":["low","normal","high","urgent"]}}},{"name":"assigneeId","in":"query","required":false,"schema":{"type":"string","minLength":1}},{"name":"ownerId","in":"query","required":false,"schema":{"type":"string","minLength":1}},{"name":"unassigned","in":"query","required":false,"schema":{"type":"string"}},{"name":"dueFrom","in":"query","required":false,"schema":{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z))$"}},{"name":"dueBefore","in":"query","required":false,"schema":{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z))$"}},{"name":"createdFrom","in":"query","required":false,"schema":{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z))$"}},{"name":"createdBefore","in":"query","required":false,"schema":{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z))$"}},{"name":"sort","in":"query","required":false,"schema":{"default":"dueAt","type":"string","enum":["dueAt","createdAt","updatedAt","priority","title"]}},{"name":"order","in":"query","required":false,"schema":{"default":"asc","type":"string","enum":["asc","desc"]}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"data":{"items":{"properties":{"assignees":{"items":{"properties":{"id":{"format":"uuid","type":"string"},"image":{"type":"null"},"name":{"type":"string"}},"required":["id","name","image"],"type":"object"},"type":"array"},"companyId":{"type":"null"},"companyName":{"type":"null"},"contactId":{"format":"uuid","type":["null","string"]},"contactName":{"type":["null","string"]},"conversationId":{"type":"null"},"createdAt":{"format":"date-time","type":"string"},"createdBy":{"format":"uuid","type":"string"},"createdByName":{"type":"string"},"description":{"type":["null","string"]},"dueAt":{"format":"date-time","type":["null","string"]},"evidence":{"type":"array"},"id":{"format":"uuid","type":"string"},"organizationId":{"format":"uuid","type":"string"},"ownerId":{"format":"uuid","type":["null","string"]},"ownerName":{"type":["null","string"]},"priority":{"type":"string"},"sessionId":{"type":"null"},"sourceKey":{"type":"null"},"status":{"type":"string"},"title":{"type":"string"},"updatedAt":{"format":"date-time","type":"string"}},"required":["assignees","companyId","companyName","contactId","contactName","conversationId","createdAt","createdBy","createdByName","description","dueAt","evidence","id","organizationId","ownerId","ownerName","priority","sessionId","sourceKey","status","title","updatedAt"],"type":"object"},"type":"array"},"page":{"type":"integer"},"pageSize":{"type":"integer"},"total":{"type":"integer"}},"required":["data","page","pageSize","total"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"post":{"operationId":"POST /v1/tasks","summary":"Creates a task, optionally linked to a contact, company or proposal.","tags":["tasks"],"x-feature":"tasks","x-action":"create","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"title":{"type":"string","minLength":1,"maxLength":300},"description":{"anyOf":[{"type":"string","maxLength":5000},{"type":"null"}]},"status":{"default":"open","type":"string","enum":["suggested","open","in_progress","done","canceled"]},"priority":{"default":"normal","type":"string","enum":["low","normal","high","urgent"]},"dueAt":{"anyOf":[{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z))$"},{"type":"null"}]},"ownerId":{"anyOf":[{"type":"string","minLength":1},{"type":"null"}]},"assigneeIds":{"maxItems":100,"type":"array","items":{"type":"string","minLength":1}},"contactId":{"anyOf":[{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},{"type":"null"}]},"companyId":{"anyOf":[{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},{"type":"null"}]}},"required":["title"]}}}},"responses":{"201":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"assignees":{"items":{"properties":{"id":{"format":"uuid","type":"string"},"image":{"type":"null"},"name":{"type":"string"}},"required":["id","name","image"],"type":"object"},"type":"array"},"companyId":{"type":"null"},"companyName":{"type":"null"},"contactId":{"format":"uuid","type":["null","string"]},"contactName":{"type":["null","string"]},"conversationId":{"type":"null"},"createdAt":{"format":"date-time","type":"string"},"createdBy":{"format":"uuid","type":"string"},"createdByName":{"type":"string"},"description":{"type":["null","string"]},"dueAt":{"format":"date-time","type":["null","string"]},"evidence":{"type":"array"},"id":{"format":"uuid","type":"string"},"organizationId":{"format":"uuid","type":"string"},"ownerId":{"format":"uuid","type":["null","string"]},"ownerName":{"type":["null","string"]},"priority":{"type":"string"},"sessionId":{"type":"null"},"sourceKey":{"type":"null"},"status":{"type":"string"},"title":{"type":"string"},"updatedAt":{"format":"date-time","type":"string"}},"required":["assignees","companyId","companyName","contactId","contactName","conversationId","createdAt","createdBy","createdByName","description","dueAt","evidence","id","organizationId","ownerId","ownerName","priority","sessionId","sourceKey","status","title","updatedAt"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/tasks/{id}":{"delete":{"operationId":"DELETE /v1/tasks/{id}","summary":"Deletes a task.","tags":["tasks"],"x-feature":"tasks","x-action":"delete","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"204":{"description":"Done, with no content."},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"get":{"operationId":"GET /v1/tasks/{id}","summary":"Returns a task.","tags":["tasks"],"x-feature":"tasks","x-action":"read","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"assignees":{"items":{"properties":{"id":{"format":"uuid","type":"string"},"image":{"type":"null"},"name":{"type":"string"}},"required":["id","name","image"],"type":"object"},"type":"array"},"companyId":{"type":"null"},"companyName":{"type":"null"},"contactId":{"type":"null"},"contactName":{"type":"null"},"conversationId":{"type":"null"},"createdAt":{"format":"date-time","type":"string"},"createdBy":{"format":"uuid","type":"string"},"createdByName":{"type":"string"},"description":{"type":["null","string"]},"dueAt":{"format":"date-time","type":["null","string"]},"evidence":{"type":"array"},"id":{"format":"uuid","type":"string"},"organizationId":{"format":"uuid","type":"string"},"ownerId":{"format":"uuid","type":["null","string"]},"ownerName":{"type":["null","string"]},"priority":{"type":"string"},"sessionId":{"type":"null"},"sourceKey":{"type":"null"},"status":{"type":"string"},"title":{"type":"string"},"updatedAt":{"format":"date-time","type":"string"}},"required":["id","organizationId","title","description","status","priority","dueAt","ownerId","contactId","companyId","sessionId","sourceKey","evidence","createdBy","createdAt","updatedAt","contactName","companyName","ownerName","conversationId","createdByName","assignees"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"patch":{"operationId":"PATCH /v1/tasks/{id}","summary":"Changes a task: status, owner, due date or priority.","tags":["tasks"],"x-feature":"tasks","x-action":"update","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"title":{"type":"string","minLength":1,"maxLength":300},"description":{"anyOf":[{"type":"string","maxLength":5000},{"type":"null"}]},"status":{"type":"string","enum":["suggested","open","in_progress","done","canceled"]},"priority":{"type":"string","enum":["low","normal","high","urgent"]},"dueAt":{"anyOf":[{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z))$"},{"type":"null"}]},"ownerId":{"anyOf":[{"type":"string","minLength":1},{"type":"null"}]},"assigneeIds":{"maxItems":100,"type":"array","items":{"type":"string","minLength":1}},"contactId":{"anyOf":[{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},{"type":"null"}]},"companyId":{"anyOf":[{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},{"type":"null"}]}}}}}},"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"assignees":{"items":{"properties":{"id":{"format":"uuid","type":"string"},"image":{"type":"null"},"name":{"type":"string"}},"required":["id","name","image"],"type":"object"},"type":"array"},"companyId":{"type":"null"},"companyName":{"type":"null"},"contactId":{"format":"uuid","type":["null","string"]},"contactName":{"type":["null","string"]},"conversationId":{"format":"uuid","type":["null","string"]},"createdAt":{"format":"date-time","type":"string"},"createdBy":{"format":"uuid","type":["null","string"]},"createdByName":{"type":["null","string"]},"description":{"type":["null","string"]},"dueAt":{"format":"date-time","type":["null","string"]},"evidence":{"items":{"format":"uuid","type":"string"},"type":"array"},"id":{"format":"uuid","type":"string"},"organizationId":{"format":"uuid","type":"string"},"ownerId":{"format":"uuid","type":["null","string"]},"ownerName":{"type":["null","string"]},"priority":{"type":"string"},"sessionId":{"format":"uuid","type":["null","string"]},"sourceKey":{"type":["null","string"]},"status":{"type":"string"},"title":{"type":"string"},"updatedAt":{"format":"date-time","type":"string"}},"required":["assignees","companyId","companyName","contactId","contactName","conversationId","createdAt","createdBy","createdByName","description","dueAt","evidence","id","organizationId","ownerId","ownerName","priority","sessionId","sourceKey","status","title","updatedAt"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/tasks/board":{"get":{"operationId":"GET /v1/tasks/board","summary":"Tasks grouped by status, for a board.","tags":["tasks"],"x-feature":"tasks","x-action":"read","parameters":[{"name":"page","in":"query","required":false,"schema":{"default":1,"type":"integer","minimum":1,"maximum":9007199254740991}},{"name":"pageSize","in":"query","required":false,"schema":{"default":25,"type":"integer","minimum":1,"maximum":100}},{"name":"q","in":"query","required":false,"schema":{"type":"string","minLength":1,"maxLength":200}},{"name":"archived","in":"query","required":false,"schema":{"type":"string"}},{"name":"contactId","in":"query","required":false,"schema":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"}},{"name":"companyId","in":"query","required":false,"schema":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"}},{"name":"projectId","in":"query","required":false,"schema":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"}},{"name":"status","in":"query","required":false,"schema":{"minItems":1,"maxItems":10,"type":"array","items":{"type":"string","enum":["suggested","open","in_progress","done","canceled"]}}},{"name":"priority","in":"query","required":false,"schema":{"minItems":1,"maxItems":10,"type":"array","items":{"type":"string","enum":["low","normal","high","urgent"]}}},{"name":"assigneeId","in":"query","required":false,"schema":{"type":"string","minLength":1}},{"name":"ownerId","in":"query","required":false,"schema":{"type":"string","minLength":1}},{"name":"unassigned","in":"query","required":false,"schema":{"type":"string"}},{"name":"dueFrom","in":"query","required":false,"schema":{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z))$"}},{"name":"dueBefore","in":"query","required":false,"schema":{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z))$"}},{"name":"createdFrom","in":"query","required":false,"schema":{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z))$"}},{"name":"createdBefore","in":"query","required":false,"schema":{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z))$"}},{"name":"sort","in":"query","required":false,"schema":{"default":"dueAt","type":"string","enum":["dueAt","createdAt","updatedAt","priority","title"]}},{"name":"order","in":"query","required":false,"schema":{"default":"asc","type":"string","enum":["asc","desc"]}}],"responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"columns":{"items":{"properties":{"data":{"items":{"properties":{"assignees":{"items":{"properties":{"id":{"format":"uuid","type":"string"},"image":{"type":"null"},"name":{"type":"string"}},"required":["id","name","image"],"type":"object"},"type":"array"},"companyId":{"type":"null"},"companyName":{"type":"null"},"contactId":{"type":"null"},"contactName":{"type":"null"},"conversationId":{"type":"null"},"createdAt":{"format":"date-time","type":"string"},"createdBy":{"format":"uuid","type":"string"},"createdByName":{"type":"string"},"description":{"type":["null","string"]},"dueAt":{"format":"date-time","type":["null","string"]},"evidence":{"type":"array"},"id":{"format":"uuid","type":"string"},"organizationId":{"format":"uuid","type":"string"},"ownerId":{"format":"uuid","type":["null","string"]},"ownerName":{"type":["null","string"]},"priority":{"type":"string"},"sessionId":{"type":"null"},"sourceKey":{"type":"null"},"status":{"type":"string"},"title":{"type":"string"},"updatedAt":{"format":"date-time","type":"string"}},"required":["assignees","companyId","companyName","contactId","contactName","conversationId","createdAt","createdBy","createdByName","description","dueAt","evidence","id","organizationId","ownerId","ownerName","priority","sessionId","sourceKey","status","title","updatedAt"],"type":"object"},"type":"array"},"page":{"type":"integer"},"pageSize":{"type":"integer"},"status":{"type":"string"},"total":{"type":"integer"}},"required":["data","page","pageSize","status","total"],"type":"object"},"type":"array"}},"required":["columns"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/usage":{"get":{"operationId":"GET /v1/usage","summary":"What the organization used this month against its plan, by allowance.","tags":["organization"],"x-feature":"organization","x-action":"read","responses":{"200":{"description":"Success.","content":{"application/json":{"schema":{"properties":{"monthly":{"properties":{"appointments":{"properties":{"limit":{"type":["integer","null"]},"used":{"type":"integer"}},"required":["limit","used"],"type":"object"},"approvals":{"properties":{"limit":{"type":"integer"},"used":{"type":"integer"}},"required":["limit","used"],"type":"object"},"catalogRequests":{"properties":{"limit":{"type":"integer"},"used":{"type":"integer"}},"required":["limit","used"],"type":"object"},"contactEvents":{"properties":{"limit":{"type":"integer"},"used":{"type":"integer"}},"required":["limit","used"],"type":"object"},"contractSignatures":{"properties":{"limit":{"type":"integer"},"used":{"type":"integer"}},"required":["limit","used"],"type":"object"},"deals":{"properties":{"limit":{"type":"integer"},"used":{"type":"integer"}},"required":["limit","used"],"type":"object"},"emails":{"properties":{"limit":{"type":"integer"},"used":{"type":"integer"}},"required":["limit","used"],"type":"object"},"formSubmissions":{"properties":{"limit":{"type":"integer"},"used":{"type":"integer"}},"required":["limit","used"],"type":"object"},"invoices":{"properties":{"limit":{"type":"integer"},"used":{"type":"integer"}},"required":["limit","used"],"type":"object"},"messagingConversations":{"properties":{"limit":{"type":"integer"},"used":{"type":"integer"}},"required":["limit","used"],"type":"object"},"messagingMessages":{"properties":{"limit":{"type":"integer"},"used":{"type":"integer"}},"required":["limit","used"],"type":"object"},"socialPosts":{"properties":{"limit":{"type":"integer"},"used":{"type":"integer"}},"required":["limit","used"],"type":"object"},"surveyInvites":{"properties":{"limit":{"type":"integer"},"used":{"type":"integer"}},"required":["limit","used"],"type":"object"}},"required":["appointments","approvals","catalogRequests","contactEvents","contractSignatures","deals","emails","formSubmissions","invoices","messagingConversations","messagingMessages","socialPosts","surveyInvites"],"type":"object"},"period":{"type":"string"},"resetsAt":{"format":"date-time","type":"string"},"storage":{"properties":{"limit":{"type":"integer"},"used":{"type":"integer"}},"required":["limit","used"],"type":"object"},"totals":{"properties":{"calendarEvents":{"properties":{"limit":{"type":"integer"},"used":{"type":"integer"}},"required":["limit","used"],"type":"object"},"catalogPages":{"properties":{"limit":{"type":"integer"},"used":{"type":"integer"}},"required":["limit","used"],"type":"object"},"companies":{"properties":{"limit":{"type":"integer"},"used":{"type":"integer"}},"required":["limit","used"],"type":"object"},"contacts":{"properties":{"limit":{"type":"integer"},"used":{"type":"integer"}},"required":["limit","used"],"type":"object"},"contracts":{"properties":{"limit":{"type":"integer"},"used":{"type":"integer"}},"required":["limit","used"],"type":"object"},"emailSavedBlocks":{"properties":{"limit":{"type":"integer"},"used":{"type":"integer"}},"required":["limit","used"],"type":"object"},"emailSignatures":{"properties":{"limit":{"type":"integer"},"used":{"type":"integer"}},"required":["limit","used"],"type":"object"},"forms":{"properties":{"limit":{"type":"integer"},"used":{"type":"integer"}},"required":["limit","used"],"type":"object"},"googleBusinessLocations":{"properties":{"limit":{"type":"integer"},"used":{"type":"integer"}},"required":["limit","used"],"type":"object"},"linkPages":{"properties":{"limit":{"type":"integer"},"used":{"type":"integer"}},"required":["limit","used"],"type":"object"},"lists":{"properties":{"limit":{"type":"integer"},"used":{"type":"integer"}},"required":["limit","used"],"type":"object"},"loyaltyRewards":{"properties":{"limit":{"type":"integer"},"used":{"type":"integer"}},"required":["limit","used"],"type":"object"},"marketingPosts":{"properties":{"limit":{"type":"integer"},"used":{"type":"integer"}},"required":["limit","used"],"type":"object"},"microsites":{"properties":{"limit":{"type":"integer"},"used":{"type":"integer"}},"required":["limit","used"],"type":"object"},"packages":{"properties":{"limit":{"type":"integer"},"used":{"type":"integer"}},"required":["limit","used"],"type":"object"},"projects":{"properties":{"limit":{"type":"integer"},"used":{"type":"integer"}},"required":["limit","used"],"type":"object"},"qrCodes":{"properties":{"limit":{"type":"integer"},"used":{"type":"integer"}},"required":["limit","used"],"type":"object"},"services":{"properties":{"limit":{"type":"integer"},"used":{"type":"integer"}},"required":["limit","used"],"type":"object"},"sharedFiles":{"properties":{"limit":{"type":"integer"},"used":{"type":"integer"}},"required":["limit","used"],"type":"object"},"shortLinks":{"properties":{"limit":{"type":"integer"},"used":{"type":"integer"}},"required":["limit","used"],"type":"object"},"surveys":{"properties":{"limit":{"type":"integer"},"used":{"type":"integer"}},"required":["limit","used"],"type":"object"},"tags":{"properties":{"limit":{"type":"integer"},"used":{"type":"integer"}},"required":["limit","used"],"type":"object"}},"required":["calendarEvents","catalogPages","companies","contacts","contracts","emailSavedBlocks","emailSignatures","forms","googleBusinessLocations","linkPages","lists","loyaltyRewards","marketingPosts","microsites","packages","projects","qrCodes","services","sharedFiles","shortLinks","surveys","tags"],"type":"object"}},"required":["monthly","period","resetsAt","storage","totals"],"type":"object"}}}},"400":{"description":"The input failed validation (`VALIDATION_ERROR`, with the issues in `details`) or the action does not apply.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"No API key, or the key is revoked or expired.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"The plan does not include this, or an allowance is used up (`*_LIMIT_REACHED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"The key lacks the permission for this feature and action (`API_KEY_PERMISSION_DENIED`).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found in this organization.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Conflicts with what exists (a reference or number already taken...).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Over the requests per minute of the plan (`API_RATE_LIMITED`); wait for `Retry-After` seconds.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}}},"components":{"securitySchemes":{"apiKey":{"type":"apiKey","in":"header","name":"X-Api-Key"},"bearer":{"type":"http","scheme":"bearer","description":"The same API key, as a bearer token."}},"schemas":{"Error":{"type":"object","required":["error"],"properties":{"error":{"type":"object","required":["code","message"],"properties":{"code":{"type":"string","description":"Stable, machine-readable: act on this.","examples":["CONTACT_LIMIT_REACHED"]},"message":{"type":"string","description":"For people, in English."},"details":{"description":"Extra data some codes carry (the limit, the fields that failed...)."}}}}}}},"x-webhook-events":[{"type":"catalog_page.created","feature":"catalogPages","change":"create"},{"type":"catalog_page.updated","feature":"catalogPages","change":"update"},{"type":"catalog_request.created","feature":"catalogRequests","change":"create"},{"type":"catalog_request.updated","feature":"catalogRequests","change":"update"},{"type":"post_automation.created","feature":"postAutomations","change":"create"},{"type":"post_automation.updated","feature":"postAutomations","change":"update"},{"type":"post_automation.deleted","feature":"postAutomations","change":"delete"},{"type":"task.created","feature":"tasks","change":"create"},{"type":"task.updated","feature":"tasks","change":"update"},{"type":"task.deleted","feature":"tasks","change":"delete"},{"type":"contact.created","feature":"contacts","change":"create"},{"type":"contact.updated","feature":"contacts","change":"update"},{"type":"contact.deleted","feature":"contacts","change":"delete"},{"type":"contact.merged","feature":"contacts","change":"update"},{"type":"company.created","feature":"companies","change":"create"},{"type":"company.updated","feature":"companies","change":"update"},{"type":"company.deleted","feature":"companies","change":"delete"},{"type":"list.created","feature":"lists","change":"create"},{"type":"list.updated","feature":"lists","change":"update"},{"type":"list.members_added","feature":"lists","change":"update"},{"type":"list.members_removed","feature":"lists","change":"update"},{"type":"list.deleted","feature":"lists","change":"delete"},{"type":"deal.created","feature":"deals","change":"create"},{"type":"deal.updated","feature":"deals","change":"update"},{"type":"deal.sent","feature":"deals","change":"update"},{"type":"deal.viewed","feature":"deals","change":"update"},{"type":"deal.question","feature":"deals","change":"update"},{"type":"deal.accepted","feature":"deals","change":"update"},{"type":"deal.declined","feature":"deals","change":"update"},{"type":"deal.expired","feature":"deals","change":"update"},{"type":"deal.paid","feature":"deals","change":"update"},{"type":"deal.deleted","feature":"deals","change":"delete"},{"type":"manual_payment.created","feature":"payments","change":"create"},{"type":"manual_payment.updated","feature":"payments","change":"update"},{"type":"manual_payment.deleted","feature":"payments","change":"delete"},{"type":"invoice.created","feature":"invoices","change":"create"},{"type":"invoice.updated","feature":"invoices","change":"update"},{"type":"invoice.sent","feature":"invoices","change":"update"},{"type":"invoice.viewed","feature":"invoices","change":"update"},{"type":"invoice.paid","feature":"invoices","change":"update"},{"type":"invoice.overdue","feature":"invoices","change":"update"},{"type":"invoice.voided","feature":"invoices","change":"update"},{"type":"invoice.deleted","feature":"invoices","change":"delete"},{"type":"approval.created","feature":"approvals","change":"create"},{"type":"approval.updated","feature":"approvals","change":"update"},{"type":"approval.sent","feature":"approvals","change":"update"},{"type":"approval.approved","feature":"approvals","change":"update"},{"type":"approval.completed","feature":"approvals","change":"update"},{"type":"approval.declined","feature":"approvals","change":"update"},{"type":"approval.canceled","feature":"approvals","change":"update"},{"type":"approval.deleted","feature":"approvals","change":"delete"},{"type":"contract_template.created","feature":"contracts","change":"create"},{"type":"contract_template.updated","feature":"contracts","change":"update"},{"type":"contract_template.deleted","feature":"contracts","change":"delete"},{"type":"contract.created","feature":"contracts","change":"create"},{"type":"contract.updated","feature":"contracts","change":"update"},{"type":"contract.sent","feature":"contracts","change":"update"},{"type":"contract.signed","feature":"contracts","change":"update"},{"type":"contract.completed","feature":"contracts","change":"update"},{"type":"contract.declined","feature":"contracts","change":"update"},{"type":"contract.canceled","feature":"contracts","change":"update"},{"type":"contract.deleted","feature":"contracts","change":"delete"},{"type":"calendar_event.created","feature":"calendarEvents","change":"create"},{"type":"calendar_event.updated","feature":"calendarEvents","change":"update"},{"type":"calendar_event.deleted","feature":"calendarEvents","change":"delete"},{"type":"social_post.created","feature":"socialPosts","change":"create"},{"type":"social_post.updated","feature":"socialPosts","change":"update"},{"type":"social_post.published","feature":"socialPosts","change":"update"},{"type":"social_post.failed","feature":"socialPosts","change":"update"},{"type":"social_post.deleted","feature":"socialPosts","change":"delete"},{"type":"loyalty_program.updated","feature":"loyalty","change":"update"},{"type":"loyalty_member.joined","feature":"loyalty","change":"create"},{"type":"loyalty.points_changed","feature":"loyalty","change":"update"},{"type":"loyalty_reward.created","feature":"loyalty","change":"create"},{"type":"loyalty_reward.updated","feature":"loyalty","change":"update"},{"type":"loyalty_reward.deleted","feature":"loyalty","change":"delete"},{"type":"loyalty_redemption.created","feature":"loyalty","change":"create"},{"type":"loyalty_redemption.updated","feature":"loyalty","change":"update"},{"type":"contact_event.created","feature":"contactEvents","change":"create"},{"type":"contact_event.deleted","feature":"contactEvents","change":"delete"},{"type":"service.created","feature":"services","change":"create"},{"type":"service.updated","feature":"services","change":"update"},{"type":"service.deleted","feature":"services","change":"delete"},{"type":"package.created","feature":"packages","change":"create"},{"type":"package.updated","feature":"packages","change":"update"},{"type":"package.deleted","feature":"packages","change":"delete"},{"type":"appointment.created","feature":"appointments","change":"create"},{"type":"appointment.updated","feature":"appointments","change":"update"},{"type":"appointment.canceled","feature":"appointments","change":"update"},{"type":"appointment.deleted","feature":"appointments","change":"delete"},{"type":"booking_page.created","feature":"bookingPages","change":"create"},{"type":"booking_page.updated","feature":"bookingPages","change":"update"},{"type":"booking_page.deleted","feature":"bookingPages","change":"delete"},{"type":"availability.updated","feature":"availability","change":"update"},{"type":"custom_property.created","feature":"customProperties","change":"create"},{"type":"custom_property.updated","feature":"customProperties","change":"update"},{"type":"custom_property.deleted","feature":"customProperties","change":"delete"},{"type":"form.created","feature":"forms","change":"create"},{"type":"form.updated","feature":"forms","change":"update"},{"type":"form.deleted","feature":"forms","change":"delete"},{"type":"form.submitted","feature":"forms","change":"create"},{"type":"form.submission_deleted","feature":"forms","change":"delete"},{"type":"survey.created","feature":"surveys","change":"create"},{"type":"survey.updated","feature":"surveys","change":"update"},{"type":"survey.deleted","feature":"surveys","change":"delete"},{"type":"survey.recipients_added","feature":"surveys","change":"update"},{"type":"survey.recipient_removed","feature":"surveys","change":"update"},{"type":"survey.responded","feature":"surveys","change":"create"},{"type":"survey.response_deleted","feature":"surveys","change":"delete"},{"type":"link_page.created","feature":"linkPages","change":"create"},{"type":"link_page.updated","feature":"linkPages","change":"update"},{"type":"link_page.deleted","feature":"linkPages","change":"delete"},{"type":"microsite.created","feature":"microsites","change":"create"},{"type":"microsite.updated","feature":"microsites","change":"update"},{"type":"microsite.deleted","feature":"microsites","change":"delete"},{"type":"qr_code.created","feature":"qrCodes","change":"create"},{"type":"qr_code.updated","feature":"qrCodes","change":"update"},{"type":"qr_code.deleted","feature":"qrCodes","change":"delete"},{"type":"email_signature.created","feature":"emailSignatures","change":"create"},{"type":"email_signature.updated","feature":"emailSignatures","change":"update"},{"type":"email_signature.deleted","feature":"emailSignatures","change":"delete"},{"type":"short_link.created","feature":"shortLinks","change":"create"},{"type":"short_link.updated","feature":"shortLinks","change":"update"},{"type":"short_link.deleted","feature":"shortLinks","change":"delete"},{"type":"file.uploaded","feature":"files","change":"create"},{"type":"file.updated","feature":"files","change":"update"},{"type":"file.deleted","feature":"files","change":"delete"},{"type":"shared_file.created","feature":"sharedFiles","change":"create"},{"type":"shared_file.updated","feature":"sharedFiles","change":"update"},{"type":"shared_file.deleted","feature":"sharedFiles","change":"delete"},{"type":"shared_file.requested","feature":"sharedFiles","change":"create"},{"type":"project.created","feature":"projects","change":"create"},{"type":"project.updated","feature":"projects","change":"update"},{"type":"project.items_added","feature":"projects","change":"update"},{"type":"project.item_removed","feature":"projects","change":"update"},{"type":"project.deleted","feature":"projects","change":"delete"},{"type":"email_template.created","feature":"emails","change":"create"},{"type":"email_template.updated","feature":"emails","change":"update"},{"type":"email_template.deleted","feature":"emails","change":"delete"},{"type":"email_campaign.created","feature":"emails","change":"create"},{"type":"email_campaign.updated","feature":"emails","change":"update"},{"type":"email_campaign.sent","feature":"emails","change":"update"},{"type":"email_campaign.deleted","feature":"emails","change":"delete"},{"type":"email_automation.created","feature":"emails","change":"create"},{"type":"email_automation.updated","feature":"emails","change":"update"},{"type":"email_automation.deleted","feature":"emails","change":"delete"},{"type":"email.delivered","feature":"emails","change":"update"},{"type":"email.bounced","feature":"emails","change":"update"},{"type":"email.complained","feature":"emails","change":"update"},{"type":"email.opened","feature":"emails","change":"update"},{"type":"email.clicked","feature":"emails","change":"update"},{"type":"email.unsubscribed","feature":"emails","change":"update"}]}