{"openapi":"3.1.0","info":{"title":"Notifications API","version":"0.1.0","description":"Every message Manifold sends for a tenant, and the record of it (`docs/notifications.md`), by email or text message: who the tenant's mail goes out as, the domain it may verify to send from its own address — with the DNS records that takes — the SMS sender ID its texts arrive from in each country, the tenant's own email templates for each kind of message, push to the tenant's own people on their phones and in their browsers, and a log of each notification: what, why, to whom, from where, when, and what became of it."},"paths":{"/settings":{"get":{"tags":["settings"],"operationId":"settings.get","parameters":[],"security":[{"bearer":[]}],"responses":{"200":{"description":"NotificationSettings","content":{"application/json":{"schema":{"$ref":"#/components/schemas/NotificationSettingsEncoded"},"examples":{"contract":{"summary":"settings.get","value":{"sender":{"senderName":"Ridgeline Outdoor","accountsEmail":"accounts@ridgeline-outdoor.example"},"domain":{"id":"sdm_01a15777-5386-7d1f-af0c-8abfe9c68bf4","domain":"ridgeline-outdoor.example","status":"verified","mailFromDomain":"bounce.ridgeline-outdoor.example","records":[{"purpose":"dkim","type":"CNAME","name":"q3v7k2m9x4c8b1n6z5t0r2w8y4p7s3d1._domainkey.ridgeline-outdoor.example","value":"q3v7k2m9x4c8b1n6z5t0r2w8y4p7s3d1.dkim.amazonses.com","required":true,"state":"found"},{"purpose":"dkim","type":"CNAME","name":"h8j2f6l0a4e9u3o7i1g5c2v8b6n0m4k7._domainkey.ridgeline-outdoor.example","value":"h8j2f6l0a4e9u3o7i1g5c2v8b6n0m4k7.dkim.amazonses.com","required":true,"state":"found"},{"purpose":"dkim","type":"CNAME","name":"t5r1y9w3q7e2u6i0o4p8a3s7d1f5g9h2._domainkey.ridgeline-outdoor.example","value":"t5r1y9w3q7e2u6i0o4p8a3s7d1f5g9h2.dkim.amazonses.com","required":true,"state":"found"},{"purpose":"mail-from-mx","type":"MX","name":"bounce.ridgeline-outdoor.example","value":"10 feedback-smtp.ap-southeast-2.amazonses.com","required":true,"state":"found"},{"purpose":"mail-from-spf","type":"TXT","name":"bounce.ridgeline-outdoor.example","value":"v=spf1 include:amazonses.com ~all","required":true,"state":"found"},{"purpose":"dmarc","type":"TXT","name":"_dmarc.ridgeline-outdoor.example","value":"v=DMARC1; p=none;","required":false,"state":"found"}],"addedAt":"2026-10-20T05:12:40.000Z","verifiedAt":"2026-10-20T05:31:02.000Z","checkedAt":"2026-10-20T05:31:02.000Z"},"tracking":true,"fromAddress":"\"Ridgeline Outdoor\" <accounts@ridgeline-outdoor.example>","platformFromAddress":"notifications@send.getmanifold.io"}}}}}},"401":{"description":"Unauthorized | TokenAlreadyUsed","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/UnauthorizedEncoded"},{"$ref":"#/components/schemas/TokenAlreadyUsedEncoded"}]}}}},"402":{"description":"SubscriptionRequired","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SubscriptionRequiredEncoded"}}}},"403":{"description":"TenantRequired | ScopeRequired | PlatformAdminRequired","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/TenantRequiredEncoded"},{"$ref":"#/components/schemas/ScopeRequiredEncoded"},{"$ref":"#/components/schemas/PlatformAdminRequiredEncoded"}]}}}},"409":{"description":"MirroredFromSource","content":{"application/json":{"schema":{"$ref":"#/components/schemas/MirroredFromSourceEncoded"}}}},"503":{"description":"RequestLogUnavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RequestLogUnavailableEncoded"}}}}},"description":"The tenant's notifications setup: the sender (the name its mail goes out under and its one accounts email, absent until saved — nothing is sent before), its own sending domain with the DNS records it needs and what the last lookup found, and the `From` address mail goes out from today — the accounts email once its domain is verified, else Manifold's sending address.\n\nRequires `settings:read` or `notifications:read`.","x-mcp-tool":{"name":"notifications_get_settings","title":"Notifications: Senders and sending domain","toolset":"notifications","readOnlyHint":true,"destructiveHint":false,"idempotentHint":true,"openWorldHint":false},"x-required-scopes":["settings:read","notifications:read"],"x-example-source":{"origin":"contract"}}},"/settings/sender":{"put":{"tags":["settings"],"operationId":"settings.saveSender","parameters":[],"security":[{"bearer":[]}],"responses":{"200":{"description":"NotificationSettings","content":{"application/json":{"schema":{"$ref":"#/components/schemas/NotificationSettingsEncoded"},"examples":{"contract":{"summary":"settings.saveSender","value":{"sender":{"senderName":"Ridgeline Outdoor","accountsEmail":"accounts@ridgeline-outdoor.example"},"tracking":true,"fromAddress":"\"Ridgeline Outdoor\" <notifications@send.getmanifold.io>","platformFromAddress":"notifications@send.getmanifold.io"}}}}}},"401":{"description":"Unauthorized | TokenAlreadyUsed","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/UnauthorizedEncoded"},{"$ref":"#/components/schemas/TokenAlreadyUsedEncoded"}]}}}},"402":{"description":"SubscriptionRequired","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SubscriptionRequiredEncoded"}}}},"403":{"description":"TenantRequired | ScopeRequired | PlatformAdminRequired","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/TenantRequiredEncoded"},{"$ref":"#/components/schemas/ScopeRequiredEncoded"},{"$ref":"#/components/schemas/PlatformAdminRequiredEncoded"}]}}}},"409":{"description":"MirroredFromSource","content":{"application/json":{"schema":{"$ref":"#/components/schemas/MirroredFromSourceEncoded"}}}},"503":{"description":"RequestLogUnavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RequestLogUnavailableEncoded"}}}}},"description":"Set who the tenant's mail goes out as: `senderName`, the name recipients see, and `accountsEmail`, the one address every message's `Reply-To` names (and its `From`, once the address's domain is the tenant's verified sending domain). Appends `notifications.sender-saved`. Idempotent by content: saving the sender as it stands appends nothing.\n\nRequires `settings:write`.","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SaveSenderSettingsEncoded"},"example":{"senderName":"Ridgeline Outdoor","accountsEmail":"accounts@ridgeline-outdoor.example"}}},"required":true},"x-mcp-withheld":"Who the tenant's mail goes out as — its name and accounts email — is the owner's call in Settings › Notifications, not an agent's.","x-required-scopes":["settings:write"],"x-example-source":{"origin":"contract"}}},"/settings/domain":{"post":{"tags":["settings"],"operationId":"settings.addDomain","parameters":[],"security":[{"bearer":[]}],"responses":{"200":{"description":"NotificationSettings","content":{"application/json":{"schema":{"$ref":"#/components/schemas/NotificationSettingsEncoded"},"examples":{"contract":{"summary":"settings.addDomain","value":{"sender":{"senderName":"Ridgeline Outdoor","accountsEmail":"accounts@ridgeline-outdoor.example"},"domain":{"id":"sdm_01a15777-5386-7d1f-af0c-8abfe9c68bf4","domain":"ridgeline-outdoor.example","status":"pending","mailFromDomain":"bounce.ridgeline-outdoor.example","records":[{"purpose":"dkim","type":"CNAME","name":"q3v7k2m9x4c8b1n6z5t0r2w8y4p7s3d1._domainkey.ridgeline-outdoor.example","value":"q3v7k2m9x4c8b1n6z5t0r2w8y4p7s3d1.dkim.amazonses.com","required":true,"state":"unchecked"},{"purpose":"dkim","type":"CNAME","name":"h8j2f6l0a4e9u3o7i1g5c2v8b6n0m4k7._domainkey.ridgeline-outdoor.example","value":"h8j2f6l0a4e9u3o7i1g5c2v8b6n0m4k7.dkim.amazonses.com","required":true,"state":"unchecked"},{"purpose":"dkim","type":"CNAME","name":"t5r1y9w3q7e2u6i0o4p8a3s7d1f5g9h2._domainkey.ridgeline-outdoor.example","value":"t5r1y9w3q7e2u6i0o4p8a3s7d1f5g9h2.dkim.amazonses.com","required":true,"state":"unchecked"},{"purpose":"mail-from-mx","type":"MX","name":"bounce.ridgeline-outdoor.example","value":"10 feedback-smtp.ap-southeast-2.amazonses.com","required":true,"state":"unchecked"},{"purpose":"mail-from-spf","type":"TXT","name":"bounce.ridgeline-outdoor.example","value":"v=spf1 include:amazonses.com ~all","required":true,"state":"unchecked"},{"purpose":"dmarc","type":"TXT","name":"_dmarc.ridgeline-outdoor.example","value":"v=DMARC1; p=none;","required":false,"state":"unchecked"}],"addedAt":"2026-10-20T05:12:40.000Z"},"tracking":true,"fromAddress":"\"Ridgeline Outdoor\" <notifications@send.getmanifold.io>","platformFromAddress":"notifications@send.getmanifold.io"}}}}}},"401":{"description":"Unauthorized | TokenAlreadyUsed","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/UnauthorizedEncoded"},{"$ref":"#/components/schemas/TokenAlreadyUsedEncoded"}]}}}},"402":{"description":"SubscriptionRequired","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SubscriptionRequiredEncoded"}}}},"403":{"description":"TenantRequired | ScopeRequired | PlatformAdminRequired","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/TenantRequiredEncoded"},{"$ref":"#/components/schemas/ScopeRequiredEncoded"},{"$ref":"#/components/schemas/PlatformAdminRequiredEncoded"}]}}}},"409":{"description":"SendingDomainExists | SendingDomainUnavailable | MirroredFromSource","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/SendingDomainExistsEncoded"},{"$ref":"#/components/schemas/SendingDomainUnavailableEncoded"},{"$ref":"#/components/schemas/MirroredFromSourceEncoded"}]}}}},"503":{"description":"MailProviderUnavailable | RequestLogUnavailable","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/MailProviderUnavailableEncoded"},{"$ref":"#/components/schemas/RequestLogUnavailableEncoded"}]}}}}},"description":"Start sending from the tenant's own domain (`ridgeline.com`): Manifold registers the domain with its mail provider and answers the DNS records to create at the domain's DNS host — three DKIM `CNAME`s, an `MX` and an SPF `TXT` on the bounce subdomain `bounce.<domain>`, and a DMARC `TXT` recommended where the domain has none. Mail keeps going from Manifold's address until the records are found (`POST /settings/domain/check`). Appends `notifications.sending-domain-added`. 409 `SendingDomainUnavailable` for a domain another organization sends from or one of Manifold's own. Idempotent by state: adding the domain the tenant already has answers it as it stands and appends nothing, and any other domain while one is held meets 409 `SendingDomainExists` — remove it first.\n\nRequires `settings:write`.","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AddSendingDomainEncoded"},"example":{"domain":"ridgeline-outdoor.example"}}},"required":true},"x-mcp-withheld":"Sending from the merchant's own domain means records at their DNS host: the owner's work in Settings › Notifications, where the records are shown to copy.","x-required-scopes":["settings:write"],"x-example-source":{"origin":"contract"}},"delete":{"tags":["settings"],"operationId":"settings.removeDomain","parameters":[],"security":[{"bearer":[]}],"responses":{"200":{"description":"NotificationSettings","content":{"application/json":{"schema":{"$ref":"#/components/schemas/NotificationSettingsEncoded"},"examples":{"contract":{"summary":"settings.removeDomain","value":{"sender":{"senderName":"Ridgeline Outdoor","accountsEmail":"accounts@ridgeline-outdoor.example"},"tracking":true,"fromAddress":"\"Ridgeline Outdoor\" <notifications@send.getmanifold.io>","platformFromAddress":"notifications@send.getmanifold.io"}}}}}},"401":{"description":"Unauthorized | TokenAlreadyUsed","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/UnauthorizedEncoded"},{"$ref":"#/components/schemas/TokenAlreadyUsedEncoded"}]}}}},"402":{"description":"SubscriptionRequired","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SubscriptionRequiredEncoded"}}}},"403":{"description":"TenantRequired | ScopeRequired | PlatformAdminRequired","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/TenantRequiredEncoded"},{"$ref":"#/components/schemas/ScopeRequiredEncoded"},{"$ref":"#/components/schemas/PlatformAdminRequiredEncoded"}]}}}},"404":{"description":"SendingDomainNotFound","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SendingDomainNotFoundEncoded"}}}},"409":{"description":"MirroredFromSource","content":{"application/json":{"schema":{"$ref":"#/components/schemas/MirroredFromSourceEncoded"}}}},"503":{"description":"MailProviderUnavailable | RequestLogUnavailable","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/MailProviderUnavailableEncoded"},{"$ref":"#/components/schemas/RequestLogUnavailableEncoded"}]}}}}},"description":"Stop sending from the tenant's own domain: the provider forgets it and mail goes from Manifold's address again; the DNS records can then be deleted at the DNS host. Appends `notifications.sending-domain-removed`. Idempotent by state: a domain is removed once, and a retry meets 404 `SendingDomainNotFound` and appends nothing.\n\nRequires `settings:write`.","x-mcp-withheld":"Letting the sending domain go changes the address every customer sees mail from: the owner's call in Settings › Notifications.","x-required-scopes":["settings:write"],"x-example-source":{"origin":"contract"}}},"/settings/domain/check":{"post":{"tags":["settings"],"operationId":"settings.checkDomain","parameters":[],"security":[{"bearer":[]}],"responses":{"200":{"description":"NotificationSettings","content":{"application/json":{"schema":{"$ref":"#/components/schemas/NotificationSettingsEncoded"},"examples":{"contract":{"summary":"settings.checkDomain","value":{"sender":{"senderName":"Ridgeline Outdoor","accountsEmail":"accounts@ridgeline-outdoor.example"},"domain":{"id":"sdm_01a15777-5386-7d1f-af0c-8abfe9c68bf4","domain":"ridgeline-outdoor.example","status":"verified","mailFromDomain":"bounce.ridgeline-outdoor.example","records":[{"purpose":"dkim","type":"CNAME","name":"q3v7k2m9x4c8b1n6z5t0r2w8y4p7s3d1._domainkey.ridgeline-outdoor.example","value":"q3v7k2m9x4c8b1n6z5t0r2w8y4p7s3d1.dkim.amazonses.com","required":true,"state":"found"},{"purpose":"dkim","type":"CNAME","name":"h8j2f6l0a4e9u3o7i1g5c2v8b6n0m4k7._domainkey.ridgeline-outdoor.example","value":"h8j2f6l0a4e9u3o7i1g5c2v8b6n0m4k7.dkim.amazonses.com","required":true,"state":"found"},{"purpose":"dkim","type":"CNAME","name":"t5r1y9w3q7e2u6i0o4p8a3s7d1f5g9h2._domainkey.ridgeline-outdoor.example","value":"t5r1y9w3q7e2u6i0o4p8a3s7d1f5g9h2.dkim.amazonses.com","required":true,"state":"found"},{"purpose":"mail-from-mx","type":"MX","name":"bounce.ridgeline-outdoor.example","value":"10 feedback-smtp.ap-southeast-2.amazonses.com","required":true,"state":"found"},{"purpose":"mail-from-spf","type":"TXT","name":"bounce.ridgeline-outdoor.example","value":"v=spf1 include:amazonses.com ~all","required":true,"state":"found"},{"purpose":"dmarc","type":"TXT","name":"_dmarc.ridgeline-outdoor.example","value":"v=DMARC1; p=none;","required":false,"state":"found"}],"addedAt":"2026-10-20T05:12:40.000Z","verifiedAt":"2026-10-20T05:31:02.000Z","checkedAt":"2026-10-20T05:31:02.000Z"},"tracking":true,"fromAddress":"\"Ridgeline Outdoor\" <accounts@ridgeline-outdoor.example>","platformFromAddress":"notifications@send.getmanifold.io"}}}}}},"401":{"description":"Unauthorized | TokenAlreadyUsed","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/UnauthorizedEncoded"},{"$ref":"#/components/schemas/TokenAlreadyUsedEncoded"}]}}}},"402":{"description":"SubscriptionRequired","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SubscriptionRequiredEncoded"}}}},"403":{"description":"TenantRequired | ScopeRequired | PlatformAdminRequired","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/TenantRequiredEncoded"},{"$ref":"#/components/schemas/ScopeRequiredEncoded"},{"$ref":"#/components/schemas/PlatformAdminRequiredEncoded"}]}}}},"404":{"description":"SendingDomainNotFound","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SendingDomainNotFoundEncoded"}}}},"409":{"description":"MirroredFromSource","content":{"application/json":{"schema":{"$ref":"#/components/schemas/MirroredFromSourceEncoded"}}}},"503":{"description":"MailProviderUnavailable | RequestLogUnavailable","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/MailProviderUnavailableEncoded"},{"$ref":"#/components/schemas/RequestLogUnavailableEncoded"}]}}}}},"description":"Look the sending domain's records up now: each record's state (`found`, `missing`, `mismatch`) from public DNS, and the provider's own verdict. Appends `notifications.sending-domain-verified` when the provider has found the DKIM records, or `notifications.sending-domain-failed` when it has given up looking. Idempotent by state: a check that finds the domain where it already stands appends nothing. 404 `SendingDomainNotFound` when there is no domain.\n\nRequires `settings:write`.","x-mcp-withheld":"The domain is checked on an interval and from the settings panel; an agent reads where it stands with notifications_get_settings.","x-required-scopes":["settings:write"],"x-example-source":{"origin":"contract"}}},"/settings/sms":{"put":{"tags":["settings"],"operationId":"settings.saveSms","parameters":[],"security":[{"bearer":[]}],"responses":{"200":{"description":"NotificationSettings","content":{"application/json":{"schema":{"$ref":"#/components/schemas/NotificationSettingsEncoded"},"examples":{"contract":{"summary":"settings.saveSms","value":{"sender":{"senderName":"Ridgeline Outdoor","accountsEmail":"accounts@ridgeline-outdoor.example"},"domain":{"id":"sdm_01a15777-5386-7d1f-af0c-8abfe9c68bf4","domain":"ridgeline-outdoor.example","status":"verified","mailFromDomain":"bounce.ridgeline-outdoor.example","records":[{"purpose":"dkim","type":"CNAME","name":"q3v7k2m9x4c8b1n6z5t0r2w8y4p7s3d1._domainkey.ridgeline-outdoor.example","value":"q3v7k2m9x4c8b1n6z5t0r2w8y4p7s3d1.dkim.amazonses.com","required":true,"state":"found"},{"purpose":"dkim","type":"CNAME","name":"h8j2f6l0a4e9u3o7i1g5c2v8b6n0m4k7._domainkey.ridgeline-outdoor.example","value":"h8j2f6l0a4e9u3o7i1g5c2v8b6n0m4k7.dkim.amazonses.com","required":true,"state":"found"},{"purpose":"dkim","type":"CNAME","name":"t5r1y9w3q7e2u6i0o4p8a3s7d1f5g9h2._domainkey.ridgeline-outdoor.example","value":"t5r1y9w3q7e2u6i0o4p8a3s7d1f5g9h2.dkim.amazonses.com","required":true,"state":"found"},{"purpose":"mail-from-mx","type":"MX","name":"bounce.ridgeline-outdoor.example","value":"10 feedback-smtp.ap-southeast-2.amazonses.com","required":true,"state":"found"},{"purpose":"mail-from-spf","type":"TXT","name":"bounce.ridgeline-outdoor.example","value":"v=spf1 include:amazonses.com ~all","required":true,"state":"found"},{"purpose":"dmarc","type":"TXT","name":"_dmarc.ridgeline-outdoor.example","value":"v=DMARC1; p=none;","required":false,"state":"found"}],"addedAt":"2026-10-20T05:12:40.000Z","verifiedAt":"2026-10-20T05:31:02.000Z","checkedAt":"2026-10-20T05:31:02.000Z"},"sms":{"senderId":"Ridgeline","countries":[{"country":"AU","status":"active"},{"country":"NZ","status":"active"},{"country":"US","status":"unsupported","reason":"the United States accepts no sender IDs: texts there go from Manifold's number, your name first"}]},"tracking":true,"fromAddress":"\"Ridgeline Outdoor\" <accounts@ridgeline-outdoor.example>","platformFromAddress":"notifications@send.getmanifold.io"}}}}}},"401":{"description":"Unauthorized | TokenAlreadyUsed","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/UnauthorizedEncoded"},{"$ref":"#/components/schemas/TokenAlreadyUsedEncoded"}]}}}},"402":{"description":"SubscriptionRequired","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SubscriptionRequiredEncoded"}}}},"403":{"description":"TenantRequired | ScopeRequired | PlatformAdminRequired","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/TenantRequiredEncoded"},{"$ref":"#/components/schemas/ScopeRequiredEncoded"},{"$ref":"#/components/schemas/PlatformAdminRequiredEncoded"}]}}}},"409":{"description":"MirroredFromSource","content":{"application/json":{"schema":{"$ref":"#/components/schemas/MirroredFromSourceEncoded"}}}},"503":{"description":"SmsProviderUnavailable | RequestLogUnavailable","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/SmsProviderUnavailableEncoded"},{"$ref":"#/components/schemas/RequestLogUnavailableEncoded"}]}}}}},"description":"Set who the tenant's text messages come from: `senderId`, the 3 to 11 letters and digits recipients see in place of a number (`Ridgeline`), and `countries`, the countries the tenant texts (ISO codes: `AU`, `NZ`). Manifold asks the SMS provider for the sender ID in each country and answers where it stands there: `active`, `requested` while a country's carriers register it, `unsupported` where they take no sender IDs (texts go from Manifold's number, the sender's name first), or `failed` with the reason. Appends `notifications.sms-sender-saved`. Idempotent by content: saving the sender ID and countries as they stand appends nothing.\n\nRequires `settings:write`.","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SaveSmsSenderEncoded"},"example":{"senderId":"Ridgeline","countries":["AU","NZ","US"]}}},"required":true},"x-mcp-withheld":"The name every customer's texts arrive from, registered with carriers country by country, is the owner's call in Settings › Notifications, not an agent's.","x-required-scopes":["settings:write"],"x-example-source":{"origin":"contract"}},"delete":{"tags":["settings"],"operationId":"settings.removeSms","parameters":[],"security":[{"bearer":[]}],"responses":{"200":{"description":"NotificationSettings","content":{"application/json":{"schema":{"$ref":"#/components/schemas/NotificationSettingsEncoded"},"examples":{"contract":{"summary":"settings.removeSms","value":{"sender":{"senderName":"Ridgeline Outdoor","accountsEmail":"accounts@ridgeline-outdoor.example"},"domain":{"id":"sdm_01a15777-5386-7d1f-af0c-8abfe9c68bf4","domain":"ridgeline-outdoor.example","status":"verified","mailFromDomain":"bounce.ridgeline-outdoor.example","records":[{"purpose":"dkim","type":"CNAME","name":"q3v7k2m9x4c8b1n6z5t0r2w8y4p7s3d1._domainkey.ridgeline-outdoor.example","value":"q3v7k2m9x4c8b1n6z5t0r2w8y4p7s3d1.dkim.amazonses.com","required":true,"state":"found"},{"purpose":"dkim","type":"CNAME","name":"h8j2f6l0a4e9u3o7i1g5c2v8b6n0m4k7._domainkey.ridgeline-outdoor.example","value":"h8j2f6l0a4e9u3o7i1g5c2v8b6n0m4k7.dkim.amazonses.com","required":true,"state":"found"},{"purpose":"dkim","type":"CNAME","name":"t5r1y9w3q7e2u6i0o4p8a3s7d1f5g9h2._domainkey.ridgeline-outdoor.example","value":"t5r1y9w3q7e2u6i0o4p8a3s7d1f5g9h2.dkim.amazonses.com","required":true,"state":"found"},{"purpose":"mail-from-mx","type":"MX","name":"bounce.ridgeline-outdoor.example","value":"10 feedback-smtp.ap-southeast-2.amazonses.com","required":true,"state":"found"},{"purpose":"mail-from-spf","type":"TXT","name":"bounce.ridgeline-outdoor.example","value":"v=spf1 include:amazonses.com ~all","required":true,"state":"found"},{"purpose":"dmarc","type":"TXT","name":"_dmarc.ridgeline-outdoor.example","value":"v=DMARC1; p=none;","required":false,"state":"found"}],"addedAt":"2026-10-20T05:12:40.000Z","verifiedAt":"2026-10-20T05:31:02.000Z","checkedAt":"2026-10-20T05:31:02.000Z"},"tracking":true,"fromAddress":"\"Ridgeline Outdoor\" <accounts@ridgeline-outdoor.example>","platformFromAddress":"notifications@send.getmanifold.io"}}}}}},"401":{"description":"Unauthorized | TokenAlreadyUsed","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/UnauthorizedEncoded"},{"$ref":"#/components/schemas/TokenAlreadyUsedEncoded"}]}}}},"402":{"description":"SubscriptionRequired","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SubscriptionRequiredEncoded"}}}},"403":{"description":"TenantRequired | ScopeRequired | PlatformAdminRequired","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/TenantRequiredEncoded"},{"$ref":"#/components/schemas/ScopeRequiredEncoded"},{"$ref":"#/components/schemas/PlatformAdminRequiredEncoded"}]}}}},"404":{"description":"SmsSenderNotFound","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SmsSenderNotFoundEncoded"}}}},"409":{"description":"MirroredFromSource","content":{"application/json":{"schema":{"$ref":"#/components/schemas/MirroredFromSourceEncoded"}}}},"503":{"description":"SmsProviderUnavailable | RequestLogUnavailable","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/SmsProviderUnavailableEncoded"},{"$ref":"#/components/schemas/RequestLogUnavailableEncoded"}]}}}}},"description":"Stop sending text messages: the provider releases the sender ID in every country, and nothing is texted until another is saved. Appends `notifications.sms-sender-removed`. Idempotent by state: a sender ID is removed once, and a retry meets 404 `SmsSenderNotFound` and appends nothing.\n\nRequires `settings:write`.","x-mcp-withheld":"Letting the SMS sender ID go stops every text the tenant sends: the owner's call in Settings › Notifications.","x-required-scopes":["settings:write"],"x-example-source":{"origin":"contract"}}},"/settings/sms/check":{"post":{"tags":["settings"],"operationId":"settings.checkSms","parameters":[],"security":[{"bearer":[]}],"responses":{"200":{"description":"NotificationSettings","content":{"application/json":{"schema":{"$ref":"#/components/schemas/NotificationSettingsEncoded"},"examples":{"contract":{"summary":"settings.checkSms","value":{"sender":{"senderName":"Ridgeline Outdoor","accountsEmail":"accounts@ridgeline-outdoor.example"},"domain":{"id":"sdm_01a15777-5386-7d1f-af0c-8abfe9c68bf4","domain":"ridgeline-outdoor.example","status":"verified","mailFromDomain":"bounce.ridgeline-outdoor.example","records":[{"purpose":"dkim","type":"CNAME","name":"q3v7k2m9x4c8b1n6z5t0r2w8y4p7s3d1._domainkey.ridgeline-outdoor.example","value":"q3v7k2m9x4c8b1n6z5t0r2w8y4p7s3d1.dkim.amazonses.com","required":true,"state":"found"},{"purpose":"dkim","type":"CNAME","name":"h8j2f6l0a4e9u3o7i1g5c2v8b6n0m4k7._domainkey.ridgeline-outdoor.example","value":"h8j2f6l0a4e9u3o7i1g5c2v8b6n0m4k7.dkim.amazonses.com","required":true,"state":"found"},{"purpose":"dkim","type":"CNAME","name":"t5r1y9w3q7e2u6i0o4p8a3s7d1f5g9h2._domainkey.ridgeline-outdoor.example","value":"t5r1y9w3q7e2u6i0o4p8a3s7d1f5g9h2.dkim.amazonses.com","required":true,"state":"found"},{"purpose":"mail-from-mx","type":"MX","name":"bounce.ridgeline-outdoor.example","value":"10 feedback-smtp.ap-southeast-2.amazonses.com","required":true,"state":"found"},{"purpose":"mail-from-spf","type":"TXT","name":"bounce.ridgeline-outdoor.example","value":"v=spf1 include:amazonses.com ~all","required":true,"state":"found"},{"purpose":"dmarc","type":"TXT","name":"_dmarc.ridgeline-outdoor.example","value":"v=DMARC1; p=none;","required":false,"state":"found"}],"addedAt":"2026-10-20T05:12:40.000Z","verifiedAt":"2026-10-20T05:31:02.000Z","checkedAt":"2026-10-20T05:31:02.000Z"},"sms":{"senderId":"Ridgeline","countries":[{"country":"AU","status":"active"},{"country":"NZ","status":"active"},{"country":"US","status":"unsupported","reason":"the United States accepts no sender IDs: texts there go from Manifold's number, your name first"}]},"tracking":true,"fromAddress":"\"Ridgeline Outdoor\" <accounts@ridgeline-outdoor.example>","platformFromAddress":"notifications@send.getmanifold.io"}}}}}},"401":{"description":"Unauthorized | TokenAlreadyUsed","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/UnauthorizedEncoded"},{"$ref":"#/components/schemas/TokenAlreadyUsedEncoded"}]}}}},"402":{"description":"SubscriptionRequired","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SubscriptionRequiredEncoded"}}}},"403":{"description":"TenantRequired | ScopeRequired | PlatformAdminRequired","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/TenantRequiredEncoded"},{"$ref":"#/components/schemas/ScopeRequiredEncoded"},{"$ref":"#/components/schemas/PlatformAdminRequiredEncoded"}]}}}},"404":{"description":"SmsSenderNotFound","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SmsSenderNotFoundEncoded"}}}},"409":{"description":"MirroredFromSource","content":{"application/json":{"schema":{"$ref":"#/components/schemas/MirroredFromSourceEncoded"}}}},"503":{"description":"SmsProviderUnavailable | RequestLogUnavailable","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/SmsProviderUnavailableEncoded"},{"$ref":"#/components/schemas/RequestLogUnavailableEncoded"}]}}}}},"description":"Ask the SMS provider where the sender ID stands in each country it is still `requested` in, and record each that moved. Appends `notifications.sms-sender-country-changed` for each country that became `active` or `failed`. Idempotent by state: a check that finds every country where it stands appends nothing. 404 `SmsSenderNotFound` when no sender ID is saved.\n\nRequires `settings:write`.","x-mcp-withheld":"Sender IDs still being registered are checked on an interval and from the settings panel; an agent reads where they stand with notifications_get_settings.","x-required-scopes":["settings:write"],"x-example-source":{"origin":"contract"}}},"/settings/tracking":{"put":{"tags":["settings"],"operationId":"settings.saveTracking","parameters":[],"security":[{"bearer":[]}],"responses":{"200":{"description":"NotificationSettings","content":{"application/json":{"schema":{"$ref":"#/components/schemas/NotificationSettingsEncoded"},"examples":{"contract":{"summary":"settings.saveTracking","value":{"sender":{"senderName":"Ridgeline Outdoor","accountsEmail":"accounts@ridgeline-outdoor.example"},"domain":{"id":"sdm_01a15777-5386-7d1f-af0c-8abfe9c68bf4","domain":"ridgeline-outdoor.example","status":"verified","mailFromDomain":"bounce.ridgeline-outdoor.example","records":[{"purpose":"dkim","type":"CNAME","name":"q3v7k2m9x4c8b1n6z5t0r2w8y4p7s3d1._domainkey.ridgeline-outdoor.example","value":"q3v7k2m9x4c8b1n6z5t0r2w8y4p7s3d1.dkim.amazonses.com","required":true,"state":"found"},{"purpose":"dkim","type":"CNAME","name":"h8j2f6l0a4e9u3o7i1g5c2v8b6n0m4k7._domainkey.ridgeline-outdoor.example","value":"h8j2f6l0a4e9u3o7i1g5c2v8b6n0m4k7.dkim.amazonses.com","required":true,"state":"found"},{"purpose":"dkim","type":"CNAME","name":"t5r1y9w3q7e2u6i0o4p8a3s7d1f5g9h2._domainkey.ridgeline-outdoor.example","value":"t5r1y9w3q7e2u6i0o4p8a3s7d1f5g9h2.dkim.amazonses.com","required":true,"state":"found"},{"purpose":"mail-from-mx","type":"MX","name":"bounce.ridgeline-outdoor.example","value":"10 feedback-smtp.ap-southeast-2.amazonses.com","required":true,"state":"found"},{"purpose":"mail-from-spf","type":"TXT","name":"bounce.ridgeline-outdoor.example","value":"v=spf1 include:amazonses.com ~all","required":true,"state":"found"},{"purpose":"dmarc","type":"TXT","name":"_dmarc.ridgeline-outdoor.example","value":"v=DMARC1; p=none;","required":false,"state":"found"}],"addedAt":"2026-10-20T05:12:40.000Z","verifiedAt":"2026-10-20T05:31:02.000Z","checkedAt":"2026-10-20T05:31:02.000Z"},"tracking":false,"fromAddress":"\"Ridgeline Outdoor\" <accounts@ridgeline-outdoor.example>","platformFromAddress":"notifications@send.getmanifold.io"}}}}}},"401":{"description":"Unauthorized | TokenAlreadyUsed","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/UnauthorizedEncoded"},{"$ref":"#/components/schemas/TokenAlreadyUsedEncoded"}]}}}},"402":{"description":"SubscriptionRequired","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SubscriptionRequiredEncoded"}}}},"403":{"description":"TenantRequired | ScopeRequired | PlatformAdminRequired","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/TenantRequiredEncoded"},{"$ref":"#/components/schemas/ScopeRequiredEncoded"},{"$ref":"#/components/schemas/PlatformAdminRequiredEncoded"}]}}}},"409":{"description":"MirroredFromSource","content":{"application/json":{"schema":{"$ref":"#/components/schemas/MirroredFromSourceEncoded"}}}},"503":{"description":"RequestLogUnavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RequestLogUnavailableEncoded"}}}}},"description":"Switch tracking of opens and clicks on or off for the tenant's mail to its customers and suppliers (on unless switched off). A tracked email carries the mail provider's pixel and rewritten links, so the log records when it was first opened and first clicked; mail to the tenant's own people and tests are never tracked, and texts cannot be. It applies to messages sent from now. Appends `notifications.tracking-set`. Idempotent by content: setting tracking as it stands appends nothing.\n\nRequires `settings:write`.","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SaveTrackingEncoded"},"example":{"enabled":false}}},"required":true},"x-mcp-withheld":"Whether the merchant's customers and suppliers have their opens and clicks tracked is the owner's privacy call in Settings › Notifications, not an agent's.","x-required-scopes":["settings:write"],"x-example-source":{"origin":"contract"}}},"/settings/brand":{"get":{"tags":["settings"],"operationId":"settings.getBrand","parameters":[],"security":[{"bearer":[]}],"responses":{"200":{"description":"Brand","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BrandEncoded"},"examples":{"contract":{"summary":"settings.getBrand","value":{"businessName":"Ridgeline Outdoor","brandColour":"#1f4d3a","accentColour":"#1f6f50","contact":{"email":"accounts@ridgeline-outdoor.example","phone":"+61 2 9000 1234","website":"https://ridgeline-outdoor.example"},"footer":"Ridgeline Outdoor Pty Ltd · ABN 12 345 678 901","terms":"Quotes hold their prices until the date shown. Payment within 30 days of invoice.","onBrandColour":"#ffffff","logo":{"reference":"brand-logo-2026-10","contentType":"image/png","size":18204,"version":1,"storedAt":"2026-10-20T05:12:00.000Z"}}}}}}},"401":{"description":"Unauthorized | TokenAlreadyUsed","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/UnauthorizedEncoded"},{"$ref":"#/components/schemas/TokenAlreadyUsedEncoded"}]}}}},"402":{"description":"SubscriptionRequired","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SubscriptionRequiredEncoded"}}}},"403":{"description":"TenantRequired | ScopeRequired | PlatformAdminRequired","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/TenantRequiredEncoded"},{"$ref":"#/components/schemas/ScopeRequiredEncoded"},{"$ref":"#/components/schemas/PlatformAdminRequiredEncoded"}]}}}},"404":{"description":"BrandNotFound","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BrandNotFoundEncoded"}}}},"409":{"description":"MirroredFromSource","content":{"application/json":{"schema":{"$ref":"#/components/schemas/MirroredFromSourceEncoded"}}}},"503":{"description":"RequestLogUnavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RequestLogUnavailableEncoded"}}}}},"description":"The tenant's brand (`docs/customer-pages.md` › Brand): its business name, brand and accent colours (with the text colour its brand colour takes), how customers reach it, the footer and terms, and its logo — what every email template, customer page and PDF wears. 404 `BrandNotFound` until one is saved.\n\nRequires `settings:read` or `notifications:read`.","x-mcp-tool":{"name":"notifications_get_brand","title":"Notifications: Brand","toolset":"notifications","readOnlyHint":true,"destructiveHint":false,"idempotentHint":true,"openWorldHint":false},"x-required-scopes":["settings:read","notifications:read"],"x-example-source":{"origin":"contract"}},"put":{"tags":["settings"],"operationId":"settings.saveBrand","parameters":[],"security":[{"bearer":[]}],"responses":{"200":{"description":"Brand","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BrandEncoded"},"examples":{"contract":{"summary":"settings.saveBrand","value":{"businessName":"Ridgeline Outdoor","brandColour":"#1f4d3a","accentColour":"#1f6f50","contact":{"email":"accounts@ridgeline-outdoor.example","phone":"+61 2 9000 1234","website":"https://ridgeline-outdoor.example"},"footer":"Ridgeline Outdoor Pty Ltd · ABN 12 345 678 901","terms":"Quotes hold their prices until the date shown. Payment within 30 days of invoice.","onBrandColour":"#ffffff","logo":{"reference":"brand-logo-2026-10","contentType":"image/png","size":18204,"version":1,"storedAt":"2026-10-20T05:12:00.000Z"}}}}}}},"401":{"description":"Unauthorized | TokenAlreadyUsed","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/UnauthorizedEncoded"},{"$ref":"#/components/schemas/TokenAlreadyUsedEncoded"}]}}}},"402":{"description":"SubscriptionRequired","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SubscriptionRequiredEncoded"}}}},"403":{"description":"TenantRequired | ScopeRequired | PlatformAdminRequired","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/TenantRequiredEncoded"},{"$ref":"#/components/schemas/ScopeRequiredEncoded"},{"$ref":"#/components/schemas/PlatformAdminRequiredEncoded"}]}}}},"409":{"description":"MirroredFromSource","content":{"application/json":{"schema":{"$ref":"#/components/schemas/MirroredFromSourceEncoded"}}}},"422":{"description":"BrandColourContrast","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BrandColourContrastEncoded"}}}},"503":{"description":"RequestLogUnavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RequestLogUnavailableEncoded"}}}}},"description":"Set the tenant's brand, whole: `businessName`, `brandColour` (the header band and buttons — its text colour is chosen to read at 4.5:1 or better), `accentColour` (links and figures on the white page), `contact`, `footer` and `terms`. The logo is its own upload and stays. 422 `BrandColourContrast` when the accent reads below 4.5:1 on white. Appends `notifications.brand-saved`. Idempotent by content: saving the brand as it stands appends nothing.\n\nRequires `settings:write`.","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SaveBrandEncoded"},"example":{"businessName":"Ridgeline Outdoor","brandColour":"#1f4d3a","accentColour":"#1f6f50","contact":{"email":"accounts@ridgeline-outdoor.example","phone":"+61 2 9000 1234","website":"https://ridgeline-outdoor.example"},"footer":"Ridgeline Outdoor Pty Ltd · ABN 12 345 678 901","terms":"Quotes hold their prices until the date shown. Payment within 30 days of invoice."}}},"required":true},"x-mcp-withheld":"The name, colours, footer and terms every customer's emails and pages wear are the owner's call in Settings › Brand, where they are previewed; an agent reads them with notifications_get_brand.","x-required-scopes":["settings:write"],"x-example-source":{"origin":"contract"}}},"/settings/brand/logo":{"put":{"tags":["settings"],"operationId":"settings.uploadLogo","parameters":[{"name":"reference","in":"query","schema":{"type":"string","minLength":1,"maxLength":200},"required":true,"example":"brand-logo-2026-10"}],"security":[{"bearer":[]}],"responses":{"200":{"description":"Brand","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BrandEncoded"},"examples":{"contract":{"summary":"Send the image as the raw request body, with `Content-Type: image/png`.","value":{"businessName":"Ridgeline Outdoor","brandColour":"#1f4d3a","accentColour":"#1f6f50","contact":{"email":"accounts@ridgeline-outdoor.example","phone":"+61 2 9000 1234","website":"https://ridgeline-outdoor.example"},"footer":"Ridgeline Outdoor Pty Ltd · ABN 12 345 678 901","terms":"Quotes hold their prices until the date shown. Payment within 30 days of invoice.","onBrandColour":"#ffffff","logo":{"reference":"brand-logo-2026-10","contentType":"image/png","size":18204,"version":1,"storedAt":"2026-10-20T05:12:00.000Z"}}}}}}},"401":{"description":"Unauthorized | TokenAlreadyUsed","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/UnauthorizedEncoded"},{"$ref":"#/components/schemas/TokenAlreadyUsedEncoded"}]}}}},"402":{"description":"SubscriptionRequired","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SubscriptionRequiredEncoded"}}}},"403":{"description":"TenantRequired | ScopeRequired | PlatformAdminRequired","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/TenantRequiredEncoded"},{"$ref":"#/components/schemas/ScopeRequiredEncoded"},{"$ref":"#/components/schemas/PlatformAdminRequiredEncoded"}]}}}},"404":{"description":"BrandNotFound","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BrandNotFoundEncoded"}}}},"409":{"description":"MirroredFromSource","content":{"application/json":{"schema":{"$ref":"#/components/schemas/MirroredFromSourceEncoded"}}}},"422":{"description":"BrandLogoRefused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BrandLogoRefusedEncoded"}}}},"503":{"description":"BrandLogoUnavailable | RequestLogUnavailable","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/BrandLogoUnavailableEncoded"},{"$ref":"#/components/schemas/RequestLogUnavailableEncoded"}]}}}}},"description":"Set the brand's logo. The body is the raw file — a PNG or JPEG image of at most 1 MiB, with its media type in `Content-Type` (SVG is refused: it can carry script) — streamed into the private bucket. 404 `BrandNotFound` before a brand is saved; 422 `BrandLogoRefused` for anything else (the bytes must be the image they claim to be); 503 `BrandLogoUnavailable` when the file store cannot be reached. Appends `notifications.brand-logo-saved`. Idempotent on `reference`: a retried upload is acknowledged from the journal and appends nothing.\n\nRequires `settings:write`.","x-mcp-withheld":"A logo is an image file the owner uploads in Settings › Brand; its raw bytes are no tool's input, and an agent reads the brand with notifications_get_brand.","x-required-scopes":["settings:write"],"x-example-source":{"origin":"contract"},"requestBody":{"required":true,"content":{"image/png":{"schema":{"type":"string","format":"binary"},"example":"PNG … (the logo's bytes)"}}}},"delete":{"tags":["settings"],"operationId":"settings.removeLogo","parameters":[],"security":[{"bearer":[]}],"responses":{"200":{"description":"Brand","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BrandEncoded"},"examples":{"contract":{"summary":"settings.removeLogo","value":{"businessName":"Ridgeline Outdoor","brandColour":"#1f4d3a","accentColour":"#1f6f50","contact":{"email":"accounts@ridgeline-outdoor.example","phone":"+61 2 9000 1234","website":"https://ridgeline-outdoor.example"},"footer":"Ridgeline Outdoor Pty Ltd · ABN 12 345 678 901","terms":"Quotes hold their prices until the date shown. Payment within 30 days of invoice.","onBrandColour":"#ffffff"}}}}}},"401":{"description":"Unauthorized | TokenAlreadyUsed","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/UnauthorizedEncoded"},{"$ref":"#/components/schemas/TokenAlreadyUsedEncoded"}]}}}},"402":{"description":"SubscriptionRequired","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SubscriptionRequiredEncoded"}}}},"403":{"description":"TenantRequired | ScopeRequired | PlatformAdminRequired","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/TenantRequiredEncoded"},{"$ref":"#/components/schemas/ScopeRequiredEncoded"},{"$ref":"#/components/schemas/PlatformAdminRequiredEncoded"}]}}}},"404":{"description":"BrandNotFound","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BrandNotFoundEncoded"}}}},"409":{"description":"MirroredFromSource","content":{"application/json":{"schema":{"$ref":"#/components/schemas/MirroredFromSourceEncoded"}}}},"503":{"description":"RequestLogUnavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RequestLogUnavailableEncoded"}}}}},"description":"Take the logo off the brand: pages, PDFs and emails show the business name in its place. Appends `notifications.brand-logo-removed`. Idempotent by state: a brand without a logo answers as it stands and appends nothing.\n\nRequires `settings:write`.","x-mcp-withheld":"Taking the logo off every customer's emails and pages is the owner's call in Settings › Brand, not an agent's.","x-required-scopes":["settings:write"],"x-example-source":{"origin":"contract"}}},"/settings/pages-domain":{"get":{"tags":["settings"],"operationId":"settings.getPagesDomain","parameters":[],"security":[{"bearer":[]}],"responses":{"200":{"description":"PagesDomainSettings","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PagesDomainSettingsEncoded"},"examples":{"contract":{"summary":"settings.getPagesDomain","value":{"domain":{"id":"pgd_01a159a2-6c1e-7c0d-9a51-3f0e7d3b8a21","hostname":"orders.ridgeline-outdoor.example","status":"live","records":[{"purpose":"route","type":"CNAME","name":"orders.ridgeline-outdoor.example","value":"customers.getmanifold.io","required":true},{"purpose":"ownership","type":"TXT","name":"_cf-custom-hostname.orders.ridgeline-outdoor.example","value":"5cc07c04-ea62-4a5a-95f0-419334a875a4","required":false}],"edgeId":"0d89c70d-ad9f-4843-b99f-6cc0252067e9","requestedAt":"2026-10-30T22:10:00.000Z","problems":[],"verifiedAt":"2026-10-30T22:31:00.000Z","liveAt":"2026-10-30T22:34:00.000Z","checkedAt":"2026-10-30T22:34:00.000Z"},"available":true,"target":"customers.getmanifold.io","origin":"https://orders.ridgeline-outdoor.example"}}}}}},"401":{"description":"Unauthorized | TokenAlreadyUsed","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/UnauthorizedEncoded"},{"$ref":"#/components/schemas/TokenAlreadyUsedEncoded"}]}}}},"402":{"description":"SubscriptionRequired","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SubscriptionRequiredEncoded"}}}},"403":{"description":"TenantRequired | ScopeRequired | PlatformAdminRequired","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/TenantRequiredEncoded"},{"$ref":"#/components/schemas/ScopeRequiredEncoded"},{"$ref":"#/components/schemas/PlatformAdminRequiredEncoded"}]}}}},"409":{"description":"MirroredFromSource","content":{"application/json":{"schema":{"$ref":"#/components/schemas/MirroredFromSourceEncoded"}}}},"503":{"description":"RequestLogUnavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RequestLogUnavailableEncoded"}}}}},"description":"The tenant's own host for its customer pages (`docs/customer-pages.md` › The tenant's own host), when it has one: the subdomain, where it stands (`pending`, `verified`, `live`, `lapsed`), the DNS records to create and what the edge said is still missing — beside whether this deployment takes tenants' hosts at all, what the `CNAME` points at, and the origin the tenant's customer links name today.\n\nRequires `settings:read` or `notifications:read`.","x-mcp-withheld":"The customer pages' own host is DNS work the owner does with the records shown in Settings › Branding; links an agent sends already name whichever host is live.","x-required-scopes":["settings:read","notifications:read"],"x-example-source":{"origin":"contract"}},"post":{"tags":["settings"],"operationId":"settings.addPagesDomain","parameters":[],"security":[{"bearer":[]}],"responses":{"200":{"description":"PagesDomainSettings","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PagesDomainSettingsEncoded"},"examples":{"contract":{"summary":"settings.addPagesDomain","value":{"domain":{"id":"pgd_01a159a2-6c1e-7c0d-9a51-3f0e7d3b8a21","hostname":"orders.ridgeline-outdoor.example","status":"pending","records":[{"purpose":"route","type":"CNAME","name":"orders.ridgeline-outdoor.example","value":"customers.getmanifold.io","required":true},{"purpose":"ownership","type":"TXT","name":"_cf-custom-hostname.orders.ridgeline-outdoor.example","value":"5cc07c04-ea62-4a5a-95f0-419334a875a4","required":false}],"edgeId":"0d89c70d-ad9f-4843-b99f-6cc0252067e9","requestedAt":"2026-10-30T22:10:00.000Z","problems":["the name does not point at customers.getmanifold.io yet"]},"available":true,"target":"customers.getmanifold.io","origin":"https://pages.getmanifold.io/org_01a156d2-8680-7738-ab2e-ff985e454887"}}}}}},"401":{"description":"Unauthorized | TokenAlreadyUsed","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/UnauthorizedEncoded"},{"$ref":"#/components/schemas/TokenAlreadyUsedEncoded"}]}}}},"402":{"description":"SubscriptionRequired","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SubscriptionRequiredEncoded"}}}},"403":{"description":"TenantRequired | ScopeRequired | PlatformAdminRequired","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/TenantRequiredEncoded"},{"$ref":"#/components/schemas/ScopeRequiredEncoded"},{"$ref":"#/components/schemas/PlatformAdminRequiredEncoded"}]}}}},"409":{"description":"PagesDomainExists | PagesDomainUnavailable | MirroredFromSource","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/PagesDomainExistsEncoded"},{"$ref":"#/components/schemas/PagesDomainUnavailableEncoded"},{"$ref":"#/components/schemas/MirroredFromSourceEncoded"}]}}}},"503":{"description":"PagesEdgeUnavailable | RequestLogUnavailable","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/PagesEdgeUnavailableEncoded"},{"$ref":"#/components/schemas/RequestLogUnavailableEncoded"}]}}}}},"description":"Serve the tenant's customer pages on a subdomain it owns (`orders.ridgeline.com`): Manifold registers the host with its edge, which will issue and renew its certificate, and answers the records to create at the domain's DNS host — a `CNAME` from the host to Manifold's edge, and an optional ownership `TXT` that proves the name before the `CNAME` moves. Links keep naming Manifold's pages host until the host is live (`POST /settings/pages-domain/check`, and a check on an interval). Appends `notifications.pages-domain-requested`. 409 `PagesDomainUnavailable` for a host another organization uses or one of Manifold's own; 503 `PagesEdgeUnavailable` when the edge cannot be reached or the deployment has none. Idempotent by state: adding the host the tenant already has answers it as it stands and appends nothing, and any other host while one is held meets 409 `PagesDomainExists` — remove it first.\n\nRequires `settings:write`.","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AddPagesDomainEncoded"},"example":{"hostname":"orders.ridgeline-outdoor.example"}}},"required":true},"x-mcp-withheld":"Serving every customer page on the merchant's own subdomain means a record at their DNS host: the owner's work in Settings › Branding, where the record is shown to copy.","x-required-scopes":["settings:write"],"x-example-source":{"origin":"contract"}},"delete":{"tags":["settings"],"operationId":"settings.removePagesDomain","parameters":[],"security":[{"bearer":[]}],"responses":{"200":{"description":"PagesDomainSettings","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PagesDomainSettingsEncoded"},"examples":{"contract":{"summary":"settings.removePagesDomain","value":{"available":true,"target":"customers.getmanifold.io","origin":"https://pages.getmanifold.io/org_01a156d2-8680-7738-ab2e-ff985e454887"}}}}}},"401":{"description":"Unauthorized | TokenAlreadyUsed","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/UnauthorizedEncoded"},{"$ref":"#/components/schemas/TokenAlreadyUsedEncoded"}]}}}},"402":{"description":"SubscriptionRequired","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SubscriptionRequiredEncoded"}}}},"403":{"description":"TenantRequired | ScopeRequired | PlatformAdminRequired","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/TenantRequiredEncoded"},{"$ref":"#/components/schemas/ScopeRequiredEncoded"},{"$ref":"#/components/schemas/PlatformAdminRequiredEncoded"}]}}}},"404":{"description":"PagesDomainNotFound","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PagesDomainNotFoundEncoded"}}}},"409":{"description":"MirroredFromSource","content":{"application/json":{"schema":{"$ref":"#/components/schemas/MirroredFromSourceEncoded"}}}},"503":{"description":"PagesEdgeUnavailable | RequestLogUnavailable","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/PagesEdgeUnavailableEncoded"},{"$ref":"#/components/schemas/RequestLogUnavailableEncoded"}]}}}}},"description":"Stop serving the customer pages on the tenant's own host: the edge forgets it, new links name Manifold's pages host, and the `CNAME` can then be deleted at the DNS host. Links already sent on the tenant's host stop opening once the record is gone, so remove it only when you mean to. Appends `notifications.pages-domain-removed`. Idempotent by state: a host is removed once, and a retry meets 404 `PagesDomainNotFound` and appends nothing.\n\nRequires `settings:write`.","x-mcp-withheld":"Letting the pages host go changes the address in every link a customer is sent: the owner's call in Settings › Branding.","x-required-scopes":["settings:write"],"x-example-source":{"origin":"contract"}}},"/settings/pages-domain/check":{"post":{"tags":["settings"],"operationId":"settings.checkPagesDomain","parameters":[],"security":[{"bearer":[]}],"responses":{"200":{"description":"PagesDomainSettings","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PagesDomainSettingsEncoded"},"examples":{"contract":{"summary":"settings.checkPagesDomain","value":{"domain":{"id":"pgd_01a159a2-6c1e-7c0d-9a51-3f0e7d3b8a21","hostname":"orders.ridgeline-outdoor.example","status":"live","records":[{"purpose":"route","type":"CNAME","name":"orders.ridgeline-outdoor.example","value":"customers.getmanifold.io","required":true},{"purpose":"ownership","type":"TXT","name":"_cf-custom-hostname.orders.ridgeline-outdoor.example","value":"5cc07c04-ea62-4a5a-95f0-419334a875a4","required":false}],"edgeId":"0d89c70d-ad9f-4843-b99f-6cc0252067e9","requestedAt":"2026-10-30T22:10:00.000Z","problems":[],"verifiedAt":"2026-10-30T22:31:00.000Z","liveAt":"2026-10-30T22:34:00.000Z","checkedAt":"2026-10-30T22:34:00.000Z"},"available":true,"target":"customers.getmanifold.io","origin":"https://orders.ridgeline-outdoor.example"}}}}}},"401":{"description":"Unauthorized | TokenAlreadyUsed","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/UnauthorizedEncoded"},{"$ref":"#/components/schemas/TokenAlreadyUsedEncoded"}]}}}},"402":{"description":"SubscriptionRequired","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SubscriptionRequiredEncoded"}}}},"403":{"description":"TenantRequired | ScopeRequired | PlatformAdminRequired","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/TenantRequiredEncoded"},{"$ref":"#/components/schemas/ScopeRequiredEncoded"},{"$ref":"#/components/schemas/PlatformAdminRequiredEncoded"}]}}}},"404":{"description":"PagesDomainNotFound","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PagesDomainNotFoundEncoded"}}}},"409":{"description":"MirroredFromSource","content":{"application/json":{"schema":{"$ref":"#/components/schemas/MirroredFromSourceEncoded"}}}},"503":{"description":"PagesEdgeUnavailable | RequestLogUnavailable","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/PagesEdgeUnavailableEncoded"},{"$ref":"#/components/schemas/RequestLogUnavailableEncoded"}]}}}}},"description":"Ask the edge where the pages host stands now, and the records it still needs. Appends `notifications.pages-domain-verified` when the edge has found the name routed to it, `notifications.pages-domain-live` when its certificate is issued (or a lapsed host is restored), and `notifications.pages-domain-lapsed` when a live host no longer reaches Manifold — links then name Manifold's pages host and the owners and admins are told. Idempotent by state: a check that finds the host where it already stands appends nothing. 404 `PagesDomainNotFound` when there is no host.\n\nRequires `settings:write`.","x-mcp-withheld":"The pages host is checked on an interval and from Settings › Branding; nothing an agent does waits on it, since links name whichever host is live.","x-required-scopes":["settings:write"],"x-example-source":{"origin":"contract"}}},"/notifications":{"get":{"tags":["notifications"],"operationId":"notifications.list","parameters":[{"name":"status","in":"query","schema":{"$ref":"#/components/schemas/NotificationStatus"},"required":false},{"name":"kind","in":"query","schema":{"$ref":"#/components/schemas/NotificationKind"},"required":false},{"name":"channel","in":"query","schema":{"$ref":"#/components/schemas/NotificationChannel"},"required":false},{"name":"sourceId","in":"query","schema":{"type":"string"},"required":false},{"name":"to","in":"query","schema":{"type":"string"},"required":false,"example":"ops@ridgeline-outdoor.example"},{"name":"before","in":"query","schema":{"type":"string"},"required":false},{"name":"limit","in":"query","schema":{"type":"string"},"required":false,"example":"50"}],"security":[{"bearer":[]}],"responses":{"200":{"description":"NotificationList","content":{"application/json":{"schema":{"$ref":"#/components/schemas/NotificationListEncoded"},"examples":{"contract":{"summary":"notifications.list","value":{"items":[{"id":"ntf_01a157ae-4288-7f3b-bb14-41f2affd24eb","kind":"sending-test","channel":"email","status":"sent","to":["ops@ridgeline-outdoor.example"],"cc":[],"from":"\"Ridgeline Outdoor\" <accounts@ridgeline-outdoor.example>","replyTo":"accounts@ridgeline-outdoor.example","subject":"Test message from Ridgeline Outdoor","source":{"kind":"settings","id":"sender"},"requestedBy":{"_tag":"user","id":"usr_01a15709-7582-7646-b491-261a138f0650"},"requestedAt":"2026-10-20T05:40:11.000Z","sentAt":"2026-10-20T05:40:12.000Z","providerMessageId":"0108019a2b3c4d5e-01a1587e-cd9b-7f2a-9b3c-4d5e6f7a8b9c-000000","steps":[{"status":"requested","at":"2026-10-20T05:40:11.000Z"},{"status":"sent","at":"2026-10-20T05:40:12.000Z"}]}]}}}}}},"401":{"description":"Unauthorized | TokenAlreadyUsed","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/UnauthorizedEncoded"},{"$ref":"#/components/schemas/TokenAlreadyUsedEncoded"}]}}}},"402":{"description":"SubscriptionRequired","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SubscriptionRequiredEncoded"}}}},"403":{"description":"TenantRequired | ScopeRequired | PlatformAdminRequired","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/TenantRequiredEncoded"},{"$ref":"#/components/schemas/ScopeRequiredEncoded"},{"$ref":"#/components/schemas/PlatformAdminRequiredEncoded"}]}}}},"409":{"description":"MirroredFromSource","content":{"application/json":{"schema":{"$ref":"#/components/schemas/MirroredFromSourceEncoded"}}}},"503":{"description":"RequestLogUnavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RequestLogUnavailableEncoded"}}}}},"description":"The notification log, newest first: every message sent for the tenant, by email or text — what it was, why (the record it is about), to whom, from which address or sender ID, who asked, when, and what became of it. Narrow by `status`, `kind`, `channel`, `sourceId` (everything sent about one order or purchase order) or `to` (one email address or phone number). At most `limit` a page (default 50, capped at 200); pass the page's `next` back as `before` for the older ones.\n\nRequires `notifications:read`.","x-mcp-tool":{"name":"notifications_list_notifications","title":"Notifications: List notifications","toolset":"notifications","readOnlyHint":true,"destructiveHint":false,"idempotentHint":true,"openWorldHint":false},"x-required-scopes":["notifications:read"],"x-example-source":{"origin":"contract"}}},"/notifications/{notificationId}":{"get":{"tags":["notifications"],"operationId":"notifications.get","parameters":[{"name":"notificationId","in":"path","schema":{"$ref":"#/components/schemas/NtfId"},"required":true,"example":"ntf_01a15a4f-2b6d-7e8f-a1b2-c3d4e5f6a7b8"}],"security":[{"bearer":[]}],"responses":{"200":{"description":"Notification","content":{"application/json":{"schema":{"$ref":"#/components/schemas/NotificationEncoded"},"examples":{"contract":{"summary":"notifications.get","value":{"id":"ntf_01a15a4f-2b6d-7e8f-a1b2-c3d4e5f6a7b8","kind":"quote","channel":"email","status":"opened","to":["buyer@ridgeline-outdoor.example"],"cc":[],"from":"\"Ridgeline Outdoor\" <accounts@ridgeline-outdoor.example>","replyTo":"accounts@ridgeline-outdoor.example","subject":"Quote SO-19203 from Ridgeline Outdoor","source":{"kind":"quote","id":"ord_01a15a3c-7e21-7c4d-9b0e-5f6a7b8c9d0e"},"requestedBy":{"_tag":"user","id":"usr_01a15709-7582-7646-b491-261a138f0650"},"requestedAt":"2026-10-20T05:40:11.000Z","sentAt":"2026-10-20T05:40:12.000Z","providerMessageId":"0108019a2b3c4d5e-01a1587e-cd9b-7f2a-9b3c-4d5e6f7a8b9c-000000","steps":[{"status":"requested","at":"2026-10-20T05:40:11.000Z"},{"status":"sent","at":"2026-10-20T05:40:12.000Z"},{"status":"delivered","at":"2026-10-20T05:40:15.000Z"},{"status":"opened","at":"2026-10-20T07:02:52.000Z"}],"template":{"starterId":"quote-classic"},"tracked":true,"deliveredAt":"2026-10-20T05:40:14.000Z","openedAt":"2026-10-20T07:02:51.000Z"}}}}}},"401":{"description":"Unauthorized | TokenAlreadyUsed","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/UnauthorizedEncoded"},{"$ref":"#/components/schemas/TokenAlreadyUsedEncoded"}]}}}},"402":{"description":"SubscriptionRequired","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SubscriptionRequiredEncoded"}}}},"403":{"description":"TenantRequired | ScopeRequired | PlatformAdminRequired","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/TenantRequiredEncoded"},{"$ref":"#/components/schemas/ScopeRequiredEncoded"},{"$ref":"#/components/schemas/PlatformAdminRequiredEncoded"}]}}}},"404":{"description":"NotificationNotFound","content":{"application/json":{"schema":{"$ref":"#/components/schemas/NotificationNotFoundEncoded"}}}},"409":{"description":"MirroredFromSource","content":{"application/json":{"schema":{"$ref":"#/components/schemas/MirroredFromSourceEncoded"}}}},"503":{"description":"RequestLogUnavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RequestLogUnavailableEncoded"}}}}},"description":"One notification as the log holds it — what it was, why, to whom, from which address, who asked, and each step of its life with when it happened: requested, sent (with the provider's message id), then what the provider reported — delivered, delayed, bounced (with its diagnostic), marked as spam, and for tracked mail its first open and click. 404 `NotificationNotFound`.\n\nRequires `notifications:read`.","x-mcp-tool":{"name":"notifications_get_notification","title":"Notifications: One notification","toolset":"notifications","readOnlyHint":true,"destructiveHint":false,"idempotentHint":true,"openWorldHint":false},"x-required-scopes":["notifications:read"],"x-example-source":{"origin":"contract"}}},"/notifications/test":{"post":{"tags":["notifications"],"operationId":"notifications.sendTest","parameters":[],"security":[{"bearer":[]}],"responses":{"200":{"description":"Notification","content":{"application/json":{"schema":{"$ref":"#/components/schemas/NotificationEncoded"},"examples":{"contract":{"summary":"notifications.sendTest","value":{"id":"ntf_01a157ae-4288-7f3b-bb14-41f2affd24eb","kind":"sending-test","channel":"email","status":"sent","to":["ops@ridgeline-outdoor.example"],"cc":[],"from":"\"Ridgeline Outdoor\" <accounts@ridgeline-outdoor.example>","replyTo":"accounts@ridgeline-outdoor.example","subject":"Test message from Ridgeline Outdoor","source":{"kind":"settings","id":"sender"},"requestedBy":{"_tag":"user","id":"usr_01a15709-7582-7646-b491-261a138f0650"},"requestedAt":"2026-10-20T05:40:11.000Z","sentAt":"2026-10-20T05:40:12.000Z","providerMessageId":"0108019a2b3c4d5e-01a1587e-cd9b-7f2a-9b3c-4d5e6f7a8b9c-000000","steps":[{"status":"requested","at":"2026-10-20T05:40:11.000Z"},{"status":"sent","at":"2026-10-20T05:40:12.000Z"}]}}}}}},"400":{"description":"RecipientInvalid","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RecipientInvalidEncoded"}}}},"401":{"description":"Unauthorized | TokenAlreadyUsed","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/UnauthorizedEncoded"},{"$ref":"#/components/schemas/TokenAlreadyUsedEncoded"}]}}}},"402":{"description":"SubscriptionRequired","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SubscriptionRequiredEncoded"}}}},"403":{"description":"TenantRequired | ScopeRequired | PlatformAdminRequired","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/TenantRequiredEncoded"},{"$ref":"#/components/schemas/ScopeRequiredEncoded"},{"$ref":"#/components/schemas/PlatformAdminRequiredEncoded"}]}}}},"404":{"description":"SmsSenderNotFound","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SmsSenderNotFoundEncoded"}}}},"409":{"description":"RecipientSuppressed | SenderNotConfigured | SmsNotSendable | MirroredFromSource","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/RecipientSuppressedEncoded"},{"$ref":"#/components/schemas/SenderNotConfiguredEncoded"},{"$ref":"#/components/schemas/SmsNotSendableEncoded"},{"$ref":"#/components/schemas/MirroredFromSourceEncoded"}]}}}},"503":{"description":"MailProviderUnavailable | RequestLogUnavailable","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/MailProviderUnavailableEncoded"},{"$ref":"#/components/schemas/RequestLogUnavailableEncoded"}]}}}}},"description":"Send a test message on `channel` to `to` from the tenant's sender as it stands — an email address for `email`, a phone number in international form (`+61 412 345 678`) for `sms` — the way to see what recipients will see and that the sending domain or the SMS sender ID works. Appends `notifications.requested`, then `notifications.sent` (with the provider's message id) or `notifications.failed` (with its reason). 400 `RecipientInvalid` when `to` does not fit the channel; 409 `SenderNotConfigured` until the sender is saved; for a text, 404 `SmsSenderNotFound` until a sender ID is saved and 409 `SmsNotSendable` when the number's country is not one it is active in; 409 `RecipientSuppressed` for an address that bounced for good, complained or opted out. Keyed on `notificationId`, the caller-minted `ntf_` id: a retry answers the notification as recorded and never sends a second message.\n\nRequires `notifications:write`.","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SendTestNotificationEncoded"},"example":{"notificationId":"ntf_01a157ae-4288-7f3b-bb14-41f2affd24eb","channel":"email","to":"ops@ridgeline-outdoor.example"}}},"required":true},"x-mcp-tool":{"name":"notifications_send_test","title":"Notifications: Send test","toolset":"notifications","readOnlyHint":false,"destructiveHint":false,"idempotentHint":true,"openWorldHint":true},"x-required-scopes":["notifications:write"],"x-example-source":{"origin":"contract"}}},"/notifications/quotes":{"post":{"tags":["notifications"],"operationId":"notifications.sendQuote","parameters":[],"security":[{"bearer":[]}],"responses":{"200":{"description":"Notification","content":{"application/json":{"schema":{"$ref":"#/components/schemas/NotificationEncoded"},"examples":{"contract":{"summary":"notifications.sendQuote","value":{"id":"ntf_01a15a4f-2b6d-7e8f-a1b2-c3d4e5f6a7b8","kind":"quote","channel":"email","status":"sent","to":["buyer@ridgeline-outdoor.example"],"cc":[],"from":"\"Ridgeline Outdoor\" <accounts@ridgeline-outdoor.example>","replyTo":"accounts@ridgeline-outdoor.example","subject":"Quote SO-19203 from Ridgeline Outdoor","source":{"kind":"quote","id":"ord_01a15a3c-7e21-7c4d-9b0e-5f6a7b8c9d0e"},"requestedBy":{"_tag":"user","id":"usr_01a15709-7582-7646-b491-261a138f0650"},"requestedAt":"2026-10-20T05:40:11.000Z","sentAt":"2026-10-20T05:40:12.000Z","providerMessageId":"0108019a2b3c4d5e-01a1587e-cd9b-7f2a-9b3c-4d5e6f7a8b9c-000000","steps":[{"status":"requested","at":"2026-10-20T05:40:11.000Z"},{"status":"sent","at":"2026-10-20T05:40:12.000Z"}],"template":{"starterId":"quote-classic"},"tracked":true}}}}}},"400":{"description":"RecipientInvalid","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RecipientInvalidEncoded"}}}},"401":{"description":"Unauthorized | TokenAlreadyUsed","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/UnauthorizedEncoded"},{"$ref":"#/components/schemas/TokenAlreadyUsedEncoded"}]}}}},"402":{"description":"SubscriptionRequired","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SubscriptionRequiredEncoded"}}}},"403":{"description":"TenantRequired | ScopeRequired | PlatformAdminRequired","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/TenantRequiredEncoded"},{"$ref":"#/components/schemas/ScopeRequiredEncoded"},{"$ref":"#/components/schemas/PlatformAdminRequiredEncoded"}]}}}},"404":{"description":"SmsSenderNotFound","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SmsSenderNotFoundEncoded"}}}},"409":{"description":"RecipientSuppressed | QuoteNotSendable | QuotesDisabled | SenderNotConfigured | SmsNotSendable | MirroredFromSource","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/RecipientSuppressedEncoded"},{"$ref":"#/components/schemas/QuoteNotSendableEncoded"},{"$ref":"#/components/schemas/QuotesDisabledEncoded"},{"$ref":"#/components/schemas/SenderNotConfiguredEncoded"},{"$ref":"#/components/schemas/SmsNotSendableEncoded"},{"$ref":"#/components/schemas/MirroredFromSourceEncoded"}]}}}},"422":{"description":"TemplateInvalid","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TemplateInvalidEncoded"}}}},"503":{"description":"ComposeSourceUnavailable | RequestLogUnavailable","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/ComposeSourceUnavailableEncoded"},{"$ref":"#/components/schemas/RequestLogUnavailableEncoded"}]}}}}},"description":"Send an issued quote (`orderId`) to the customer on `channel`: by `email`, rendered through the quote's email template as it stands — the tenant's active one, else the chosen style's starter, else Classic — whose id and version (or starter) and layout the notification records as `template`, with its lines, totals and the date it holds its prices until and replies to the accounts email; by `sms`, a short text with its number, total and validity — each linking the quote's customer page, where the customer views, accepts or declines it (opening it marks the message opened). `to` is the address or number (international form) chosen. The message is built from the quote as issued, never a draft; an email's first open and click are recorded unless tracking is off. Appends `notifications.requested`, then `notifications.sent` (with the provider's message id) or `notifications.failed` (with its reason); while the organization is read-only it is recorded and held, failed with the reason. 400 `RecipientInvalid` when `to` does not fit the channel; 409 `QuoteNotSendable` for an order that is not an issued quote (issue it first: `POST /orders/{orderId}/quote` on fulfillment); 409 `QuotesDisabled` when `quoteMode` is `draft-orders`; 409 `SenderNotConfigured` until the sender is saved; for a text, 404 `SmsSenderNotFound` and 409 `SmsNotSendable` as for a test; 409 `RecipientSuppressed` for a suppressed address; 422 `TemplateInvalid` when the email's template cannot render this quote (nothing is recorded: fix or switch the template); 503 `ComposeSourceUnavailable` when the quote or the customer cannot be read. Keyed on `notificationId`, the caller-minted `ntf_` id: a retry answers the notification as recorded and never sends a second message.\n\nRequires `notifications:write`.","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SendQuoteEncoded"},"example":{"notificationId":"ntf_01a15a4f-2b6d-7e8f-a1b2-c3d4e5f6a7b8","orderId":"ord_01a15a3c-7e21-7c4d-9b0e-5f6a7b8c9d0e","channel":"email","to":"buyer@ridgeline-outdoor.example"}}},"required":true},"x-mcp-tool":{"name":"notifications_send_quote","title":"Notifications: Send quote","toolset":"notifications","readOnlyHint":false,"destructiveHint":false,"idempotentHint":true,"openWorldHint":true},"x-required-scopes":["notifications:write"],"x-example-source":{"origin":"contract"}}},"/suppressions":{"get":{"tags":["suppressions"],"operationId":"suppressions.list","parameters":[],"security":[{"bearer":[]}],"responses":{"200":{"description":"SuppressionList","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SuppressionListEncoded"},"examples":{"contract":{"summary":"suppressions.list","value":{"items":[{"id":"sup_01a15b10-4c2e-7d3f-8a4b-5c6d7e8f9a0b","address":"old-buyer@ridgeline-outdoor.example","channel":"email","reason":"bounced","notificationId":"ntf_01a15b02-3d4e-7f5a-9b6c-7d8e9f0a1b2c","detail":"smtp; 550 5.1.1 user unknown","suppressedAt":"2026-10-21T01:15:09.000Z"}]}}}}}},"401":{"description":"Unauthorized | TokenAlreadyUsed","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/UnauthorizedEncoded"},{"$ref":"#/components/schemas/TokenAlreadyUsedEncoded"}]}}}},"402":{"description":"SubscriptionRequired","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SubscriptionRequiredEncoded"}}}},"403":{"description":"TenantRequired | ScopeRequired | PlatformAdminRequired","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/TenantRequiredEncoded"},{"$ref":"#/components/schemas/ScopeRequiredEncoded"},{"$ref":"#/components/schemas/PlatformAdminRequiredEncoded"}]}}}},"409":{"description":"MirroredFromSource","content":{"application/json":{"schema":{"$ref":"#/components/schemas/MirroredFromSourceEncoded"}}}},"503":{"description":"RequestLogUnavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RequestLogUnavailableEncoded"}}}}},"description":"The addresses and numbers the tenant no longer sends to, newest first: each with why — a message to it bounced permanently (`bounced`), its owner marked one as spam (`complained`) or the number asked to receive no more texts (`opted-out`) — the notification that did it and the provider's diagnostic. A send to a suppressed address is refused 409 `RecipientSuppressed` until the suppression is lifted.\n\nRequires `settings:read` or `notifications:read`.","x-mcp-tool":{"name":"notifications_list_suppressions","title":"Notifications: Suppressed addresses","toolset":"notifications","readOnlyHint":true,"destructiveHint":false,"idempotentHint":true,"openWorldHint":false},"x-required-scopes":["settings:read","notifications:read"],"x-example-source":{"origin":"contract"}}},"/suppressions/{suppressionId}":{"delete":{"tags":["suppressions"],"operationId":"suppressions.lift","parameters":[{"name":"suppressionId","in":"path","schema":{"$ref":"#/components/schemas/SupId"},"required":true,"example":"sup_01a15b10-4c2e-7d3f-8a4b-5c6d7e8f9a0b"}],"security":[{"bearer":[]}],"responses":{"200":{"description":"SuppressionList","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SuppressionListEncoded"},"examples":{"contract":{"summary":"suppressions.lift","value":{"items":[]}}}}}},"401":{"description":"Unauthorized | TokenAlreadyUsed","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/UnauthorizedEncoded"},{"$ref":"#/components/schemas/TokenAlreadyUsedEncoded"}]}}}},"402":{"description":"SubscriptionRequired","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SubscriptionRequiredEncoded"}}}},"403":{"description":"TenantRequired | ScopeRequired | PlatformAdminRequired","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/TenantRequiredEncoded"},{"$ref":"#/components/schemas/ScopeRequiredEncoded"},{"$ref":"#/components/schemas/PlatformAdminRequiredEncoded"}]}}}},"404":{"description":"SuppressionNotFound","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SuppressionNotFoundEncoded"}}}},"409":{"description":"MirroredFromSource","content":{"application/json":{"schema":{"$ref":"#/components/schemas/MirroredFromSourceEncoded"}}}},"503":{"description":"RequestLogUnavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RequestLogUnavailableEncoded"}}}}},"description":"Lift a suppression, so the address or number may be sent to again — after the customer has fixed their mailbox or asked to hear from the tenant again — and answer the suppressions that remain. Another permanent bounce or complaint suppresses it again. Appends `notifications.suppression-lifted`. Idempotent by state: a suppression is lifted once, and a retry meets 404 `SuppressionNotFound` and appends nothing.\n\nRequires `settings:write`.","x-mcp-withheld":"Mailing an address again after it bounced for good, marked a message as spam or opted out is the owner's call in Settings › Notifications; an agent reads the list with notifications_list_suppressions.","x-required-scopes":["settings:write"],"x-example-source":{"origin":"contract"}}},"/email-templates/catalog":{"get":{"tags":["templates"],"operationId":"templates.catalog","parameters":[],"security":[{"bearer":[]}],"responses":{"200":{"description":"EmailTemplateCatalog","content":{"application/json":{"schema":{"$ref":"#/components/schemas/EmailTemplateCatalogEncoded"},"examples":{"contract":{"summary":"templates.catalog","value":{"style":"bold","styles":[{"style":"classic","name":"Classic","description":"A white card with your name as letterhead, every line and the totals."},{"style":"bold","name":"Bold","description":"The figure that matters set large on a colour band, then the lines."},{"style":"minimal","name":"Minimal","description":"A short plain letter: the figure, the date and the lines."},{"style":"custom","name":"Custom","description":"Your own layout — the page, header and footer every email is drawn in."}],"kinds":[{"kind":"invoice","description":"Sent to the customer when a tax invoice is issued for their order.","dataSchema":"InvoiceTemplateData","sample":{"kind":"invoice","version":2,"shop":{"name":"Ridgeline Outdoor","email":"accounts@ridgeline-outdoor.example"},"invoice":{"number":"INV-1042"}},"activeTemplateId":"etp_01a15a02-7c41-7a6e-9d10-3f6c2b8e4a11","starterId":"invoice-bold"}],"starters":[{"id":"invoice-classic","kind":"invoice","style":"classic","name":"Classic","description":"A white card with the shop's name as letterhead.","default":true,"source":"import { Container, Heading, Text, money } from \"@manifold/email\";\nexport const subject = (data) => `Invoice ${data.invoice.number} from ${data.shop.name}`;\nexport default function Invoice(data) {\n  return (\n    <Container>\n      <Heading>Thanks, {data.customer?.firstName ?? \"there\"}</Heading>\n      <Text>{money(data.invoice.totals.totalCents, data.invoice.currency)} is due.</Text>\n    </Container>\n  );\n}\n"}],"typings":"declare module \"@manifold/email\" { … }"}}}}}},"401":{"description":"Unauthorized | TokenAlreadyUsed","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/UnauthorizedEncoded"},{"$ref":"#/components/schemas/TokenAlreadyUsedEncoded"}]}}}},"402":{"description":"SubscriptionRequired","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SubscriptionRequiredEncoded"}}}},"403":{"description":"TenantRequired | ScopeRequired | PlatformAdminRequired","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/TenantRequiredEncoded"},{"$ref":"#/components/schemas/ScopeRequiredEncoded"},{"$ref":"#/components/schemas/PlatformAdminRequiredEncoded"}]}}}},"409":{"description":"MirroredFromSource","content":{"application/json":{"schema":{"$ref":"#/components/schemas/MirroredFromSourceEncoded"}}}},"503":{"description":"RequestLogUnavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RequestLogUnavailableEncoded"}}}}},"description":"Everything a template author needs: the `style` the tenant chose (absent until it chooses one) and the `styles` on offer (`custom`: the tenant's layout, `layoutTemplateId`); each kind of email a template can be written for (`invoice`, `quote`, `order-confirmation`, `purchase-order`) with what sends it, the template data schema it renders and a fixed sample of that data, the tenant's active template for it, and `starterId`, the starter it renders without one (the chosen style's, else `classic`); Manifold's starter templates — one per kind in each style, and `layout-custom` — with their whole source; and `typings`, the TypeScript declarations of `@manifold/email`. A template is a TSX module in react-email's dialect: it exports `subject` (a string, or a function of the data), optionally `preview`, and the email as its default export — a function of the kind's template data returning react-email components (`Html`, `Body`, `Container`, `Section`, `Row`, `Column`, `Heading`, `Text`, `Button`, `Link`, `Img`, `Hr`, …) and plain HTML elements, imported from `@manifold/email` with the helpers `money`, `date` and `plural` (`GET /email-templates/catalog` answers the full declarations). It runs in a sandbox — no network, files, timers or other modules, 250 ms and 16 MB a render — and what it returns is held to the dialect: no script, event handler or class, links `https:`/`http:`/`mailto:`/`tel:`, images `https:`.\n\nRequires `settings:read` or `notifications:read`.","x-mcp-tool":{"name":"notifications_get_email_template_catalog","title":"Notifications: Email template kinds, starters and dialect","toolset":"notifications","readOnlyHint":true,"destructiveHint":false,"idempotentHint":true,"openWorldHint":false},"x-required-scopes":["settings:read","notifications:read"],"x-example-source":{"origin":"contract"}}},"/email-templates":{"get":{"tags":["templates"],"operationId":"templates.list","parameters":[{"name":"archived","in":"query","schema":{"$ref":"#/components/schemas/BooleanString"},"required":false}],"security":[{"bearer":[]}],"responses":{"200":{"description":"EmailTemplateList","content":{"application/json":{"schema":{"$ref":"#/components/schemas/EmailTemplateListEncoded"},"examples":{"contract":{"summary":"templates.list","value":{"items":[{"id":"etp_01a15a02-7c41-7a6e-9d10-3f6c2b8e4a11","kind":"invoice","name":"Invoice — our colours","source":"import { Container, Heading, Text, money } from \"@manifold/email\";\nexport const subject = (data) => `Invoice ${data.invoice.number} from ${data.shop.name}`;\nexport default function Invoice(data) {\n  return (\n    <Container>\n      <Heading>Thanks, {data.customer?.firstName ?? \"there\"}</Heading>\n      <Text>{money(data.invoice.totals.totalCents, data.invoice.currency)} is due.</Text>\n    </Container>\n  );\n}\n","version":2,"basedOn":"invoice-classic","active":true,"archived":false,"createdAt":"2026-10-27T02:10:00.000Z","savedAt":"2026-10-27T02:14:31.000Z","savedBy":{"_tag":"user","id":"usr_01a15709-7582-7646-b491-261a138f0650"}}]}}}}}},"401":{"description":"Unauthorized | TokenAlreadyUsed","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/UnauthorizedEncoded"},{"$ref":"#/components/schemas/TokenAlreadyUsedEncoded"}]}}}},"402":{"description":"SubscriptionRequired","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SubscriptionRequiredEncoded"}}}},"403":{"description":"TenantRequired | ScopeRequired | PlatformAdminRequired","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/TenantRequiredEncoded"},{"$ref":"#/components/schemas/ScopeRequiredEncoded"},{"$ref":"#/components/schemas/PlatformAdminRequiredEncoded"}]}}}},"409":{"description":"MirroredFromSource","content":{"application/json":{"schema":{"$ref":"#/components/schemas/MirroredFromSourceEncoded"}}}},"503":{"description":"RequestLogUnavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RequestLogUnavailableEncoded"}}}}},"description":"The tenant's own email templates, most recently saved first, each at its latest version with its whole source, its kind, the starter it was made from and whether its kind renders it (`active`). Archived templates are left out unless `archived=true`.\n\nRequires `settings:read` or `notifications:read`.","x-mcp-tool":{"name":"notifications_list_email_templates","title":"Notifications: List email templates","toolset":"notifications","readOnlyHint":true,"destructiveHint":false,"idempotentHint":true,"openWorldHint":false},"x-required-scopes":["settings:read","notifications:read"],"x-example-source":{"origin":"contract"}}},"/email-templates/{templateId}":{"get":{"tags":["templates"],"operationId":"templates.get","parameters":[{"name":"templateId","in":"path","schema":{"$ref":"#/components/schemas/EtpId"},"required":true,"example":"etp_01a15a02-7c41-7a6e-9d10-3f6c2b8e4a11"}],"security":[{"bearer":[]}],"responses":{"200":{"description":"EmailTemplate","content":{"application/json":{"schema":{"$ref":"#/components/schemas/EmailTemplateEncoded"},"examples":{"contract":{"summary":"templates.get","value":{"id":"etp_01a15a02-7c41-7a6e-9d10-3f6c2b8e4a11","kind":"invoice","name":"Invoice — our colours","source":"import { Container, Heading, Text, money } from \"@manifold/email\";\nexport const subject = (data) => `Invoice ${data.invoice.number} from ${data.shop.name}`;\nexport default function Invoice(data) {\n  return (\n    <Container>\n      <Heading>Thanks, {data.customer?.firstName ?? \"there\"}</Heading>\n      <Text>{money(data.invoice.totals.totalCents, data.invoice.currency)} is due.</Text>\n    </Container>\n  );\n}\n","version":2,"basedOn":"invoice-classic","active":true,"archived":false,"createdAt":"2026-10-27T02:10:00.000Z","savedAt":"2026-10-27T02:14:31.000Z","savedBy":{"_tag":"user","id":"usr_01a15709-7582-7646-b491-261a138f0650"}}}}}}},"401":{"description":"Unauthorized | TokenAlreadyUsed","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/UnauthorizedEncoded"},{"$ref":"#/components/schemas/TokenAlreadyUsedEncoded"}]}}}},"402":{"description":"SubscriptionRequired","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SubscriptionRequiredEncoded"}}}},"403":{"description":"TenantRequired | ScopeRequired | PlatformAdminRequired","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/TenantRequiredEncoded"},{"$ref":"#/components/schemas/ScopeRequiredEncoded"},{"$ref":"#/components/schemas/PlatformAdminRequiredEncoded"}]}}}},"404":{"description":"EmailTemplateNotFound","content":{"application/json":{"schema":{"$ref":"#/components/schemas/EmailTemplateNotFoundEncoded"}}}},"409":{"description":"MirroredFromSource","content":{"application/json":{"schema":{"$ref":"#/components/schemas/MirroredFromSourceEncoded"}}}},"503":{"description":"RequestLogUnavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RequestLogUnavailableEncoded"}}}}},"description":"One of the tenant's email templates at its latest version, with its whole source. 404 `EmailTemplateNotFound`.\n\nRequires `settings:read` or `notifications:read`.","x-mcp-tool":{"name":"notifications_get_email_template","title":"Notifications: One email template","toolset":"notifications","readOnlyHint":true,"destructiveHint":false,"idempotentHint":true,"openWorldHint":false},"x-required-scopes":["settings:read","notifications:read"],"x-example-source":{"origin":"contract"}},"put":{"tags":["templates"],"operationId":"templates.save","parameters":[{"name":"templateId","in":"path","schema":{"$ref":"#/components/schemas/EtpId"},"required":true,"example":"etp_01a15a02-7c41-7a6e-9d10-3f6c2b8e4a11"}],"security":[{"bearer":[]}],"responses":{"200":{"description":"EmailTemplate","content":{"application/json":{"schema":{"$ref":"#/components/schemas/EmailTemplateEncoded"},"examples":{"contract":{"summary":"templates.save","value":{"id":"etp_01a15a02-7c41-7a6e-9d10-3f6c2b8e4a11","kind":"invoice","name":"Invoice — our colours","source":"import { Container, Heading, Text, money } from \"@manifold/email\";\nexport const subject = (data) => `Invoice ${data.invoice.number} from ${data.shop.name}`;\nexport default function Invoice(data) {\n  return (\n    <Container>\n      <Heading>Thanks, {data.customer?.firstName ?? \"there\"}</Heading>\n      <Text>{money(data.invoice.totals.totalCents, data.invoice.currency)} is due.</Text>\n    </Container>\n  );\n}\n","version":2,"basedOn":"invoice-classic","active":true,"archived":false,"createdAt":"2026-10-27T02:10:00.000Z","savedAt":"2026-10-27T02:14:31.000Z","savedBy":{"_tag":"user","id":"usr_01a15709-7582-7646-b491-261a138f0650"}}}}}}},"401":{"description":"Unauthorized | TokenAlreadyUsed","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/UnauthorizedEncoded"},{"$ref":"#/components/schemas/TokenAlreadyUsedEncoded"}]}}}},"402":{"description":"SubscriptionRequired","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SubscriptionRequiredEncoded"}}}},"403":{"description":"TenantRequired | ScopeRequired | PlatformAdminRequired","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/TenantRequiredEncoded"},{"$ref":"#/components/schemas/ScopeRequiredEncoded"},{"$ref":"#/components/schemas/PlatformAdminRequiredEncoded"}]}}}},"409":{"description":"EmailTemplateConflict | MirroredFromSource","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/EmailTemplateConflictEncoded"},{"$ref":"#/components/schemas/MirroredFromSourceEncoded"}]}}}},"422":{"description":"TemplateInvalid","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TemplateInvalidEncoded"}}}},"503":{"description":"RequestLogUnavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RequestLogUnavailableEncoded"}}}}},"description":"Create or change one of the tenant's email templates under a caller-minted `etp_` id: its `kind` (or `layout`), `name`, `source` and, for one started from Manifold's, the starter it was `basedOn`. Saving does not make it what the kind sends — `PUT /email-templates/kinds/:kind/active` does (a layout: the `custom` style). The source must render against the kind's sample before it is kept: 422 `TemplateInvalid` with the `stage` (`compile`, `run`, `output`), the reason and the `line` where one can be told. A template is a TSX module in react-email's dialect: it exports `subject` (a string, or a function of the data), optionally `preview`, and the email as its default export — a function of the kind's template data returning react-email components (`Html`, `Body`, `Container`, `Section`, `Row`, `Column`, `Heading`, `Text`, `Button`, `Link`, `Img`, `Hr`, …) and plain HTML elements, imported from `@manifold/email` with the helpers `money`, `date` and `plural` (`GET /email-templates/catalog` answers the full declarations). It runs in a sandbox — no network, files, timers or other modules, 250 ms and 16 MB a render — and what it returns is held to the dialect: no script, event handler or class, links `https:`/`http:`/`mailto:`/`tel:`, images `https:`. Appends `notifications.template-saved` with the whole source and the next `version`, so every version is kept. 409 `EmailTemplateConflict` for a different `kind` than the template was made for, or an archived one. Idempotent by content: saving the template as it stands appends nothing and answers it.\n\nRequires `settings:write`.","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SaveEmailTemplateEncoded"},"example":{"kind":"invoice","name":"Invoice — our colours","source":"import { Container, Heading, Text, money } from \"@manifold/email\";\nexport const subject = (data) => `Invoice ${data.invoice.number} from ${data.shop.name}`;\nexport default function Invoice(data) {\n  return (\n    <Container>\n      <Heading>Thanks, {data.customer?.firstName ?? \"there\"}</Heading>\n      <Text>{money(data.invoice.totals.totalCents, data.invoice.currency)} is due.</Text>\n    </Container>\n  );\n}\n","basedOn":"invoice-classic"}}},"required":true},"x-mcp-tool":{"name":"notifications_save_email_template","title":"Notifications: Save email template","toolset":"notifications","readOnlyHint":false,"destructiveHint":false,"idempotentHint":true,"openWorldHint":false},"x-required-scopes":["settings:write"],"x-example-source":{"origin":"contract"}}},"/email-templates/{templateId}/archive":{"post":{"tags":["templates"],"operationId":"templates.archive","parameters":[{"name":"templateId","in":"path","schema":{"$ref":"#/components/schemas/EtpId"},"required":true,"example":"etp_01a15a02-7c41-7a6e-9d10-3f6c2b8e4a11"}],"security":[{"bearer":[]}],"responses":{"200":{"description":"EmailTemplate","content":{"application/json":{"schema":{"$ref":"#/components/schemas/EmailTemplateEncoded"},"examples":{"contract":{"summary":"templates.archive","value":{"id":"etp_01a15a02-7c41-7a6e-9d10-3f6c2b8e4a11","kind":"invoice","name":"Invoice — our colours","source":"import { Container, Heading, Text, money } from \"@manifold/email\";\nexport const subject = (data) => `Invoice ${data.invoice.number} from ${data.shop.name}`;\nexport default function Invoice(data) {\n  return (\n    <Container>\n      <Heading>Thanks, {data.customer?.firstName ?? \"there\"}</Heading>\n      <Text>{money(data.invoice.totals.totalCents, data.invoice.currency)} is due.</Text>\n    </Container>\n  );\n}\n","version":2,"basedOn":"invoice-classic","active":false,"archived":true,"createdAt":"2026-10-27T02:10:00.000Z","savedAt":"2026-10-27T02:14:31.000Z","savedBy":{"_tag":"user","id":"usr_01a15709-7582-7646-b491-261a138f0650"}}}}}}},"401":{"description":"Unauthorized | TokenAlreadyUsed","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/UnauthorizedEncoded"},{"$ref":"#/components/schemas/TokenAlreadyUsedEncoded"}]}}}},"402":{"description":"SubscriptionRequired","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SubscriptionRequiredEncoded"}}}},"403":{"description":"TenantRequired | ScopeRequired | PlatformAdminRequired","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/TenantRequiredEncoded"},{"$ref":"#/components/schemas/ScopeRequiredEncoded"},{"$ref":"#/components/schemas/PlatformAdminRequiredEncoded"}]}}}},"404":{"description":"EmailTemplateNotFound","content":{"application/json":{"schema":{"$ref":"#/components/schemas/EmailTemplateNotFoundEncoded"}}}},"409":{"description":"MirroredFromSource","content":{"application/json":{"schema":{"$ref":"#/components/schemas/MirroredFromSourceEncoded"}}}},"503":{"description":"RequestLogUnavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RequestLogUnavailableEncoded"}}}}},"description":"Archive one of the tenant's email templates: it is kept with every version, no longer offered, and never active again — if its kind rendered it, the kind goes back to Manifold's default. Appends `notifications.template-archived`. Idempotent by state: a template is archived once, and archiving it again appends nothing. 404 `EmailTemplateNotFound`.\n\nRequires `settings:write`.","x-mcp-tool":{"name":"notifications_archive_email_template","title":"Notifications: Archive email template","toolset":"notifications","readOnlyHint":false,"destructiveHint":true,"idempotentHint":true,"openWorldHint":false},"x-required-scopes":["settings:write"],"x-example-source":{"origin":"contract"}}},"/email-templates/kinds/{kind}/active":{"put":{"tags":["templates"],"operationId":"templates.activate","parameters":[{"name":"kind","in":"path","schema":{"$ref":"#/components/schemas/EmailTemplateKind"},"required":true,"example":"invoice"}],"security":[{"bearer":[]}],"responses":{"200":{"description":"EmailTemplateKindInfo","content":{"application/json":{"schema":{"$ref":"#/components/schemas/EmailTemplateKindInfoEncoded"},"examples":{"contract":{"summary":"templates.activate","value":{"kind":"invoice","description":"Sent to the customer when a tax invoice is issued for their order.","dataSchema":"InvoiceTemplateData","sample":{"kind":"invoice","version":2,"shop":{"name":"Ridgeline Outdoor","email":"accounts@ridgeline-outdoor.example"},"invoice":{"number":"INV-1042"}},"activeTemplateId":"etp_01a15a02-7c41-7a6e-9d10-3f6c2b8e4a11","starterId":"invoice-bold"}}}}}},"401":{"description":"Unauthorized | TokenAlreadyUsed","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/UnauthorizedEncoded"},{"$ref":"#/components/schemas/TokenAlreadyUsedEncoded"}]}}}},"402":{"description":"SubscriptionRequired","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SubscriptionRequiredEncoded"}}}},"403":{"description":"TenantRequired | ScopeRequired | PlatformAdminRequired","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/TenantRequiredEncoded"},{"$ref":"#/components/schemas/ScopeRequiredEncoded"},{"$ref":"#/components/schemas/PlatformAdminRequiredEncoded"}]}}}},"404":{"description":"EmailTemplateNotFound","content":{"application/json":{"schema":{"$ref":"#/components/schemas/EmailTemplateNotFoundEncoded"}}}},"409":{"description":"EmailTemplateConflict | MirroredFromSource","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/EmailTemplateConflictEncoded"},{"$ref":"#/components/schemas/MirroredFromSourceEncoded"}]}}}},"503":{"description":"RequestLogUnavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RequestLogUnavailableEncoded"}}}}},"description":"Choose what a kind of email renders from now: one of the tenant's templates for that kind (`templateId`), or — without one — Manifold's default. Every message of the kind sent from then names the template version it went out with. Appends `notifications.template-activated`. 404 `EmailTemplateNotFound`; 409 `EmailTemplateConflict` for a template of another kind or an archived one. Idempotent by content: choosing what the kind already renders appends nothing.\n\nRequires `settings:write`.","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ActivateEmailTemplateEncoded"},"example":{"templateId":"etp_01a15a02-7c41-7a6e-9d10-3f6c2b8e4a11"}}},"required":true},"x-mcp-withheld":"Which design every customer or supplier receives is the merchant's choice: an agent drafts, previews and tests a template, and the merchant makes it live in Settings › Notifications › Email templates.","x-required-scopes":["settings:write"],"x-example-source":{"origin":"contract"}}},"/email-templates/style":{"put":{"tags":["templates"],"operationId":"templates.chooseStyle","parameters":[],"security":[{"bearer":[]}],"responses":{"200":{"description":"EmailTemplateCatalog","content":{"application/json":{"schema":{"$ref":"#/components/schemas/EmailTemplateCatalogEncoded"},"examples":{"contract":{"summary":"templates.chooseStyle","value":{"style":"custom","layoutTemplateId":"etp_01a15a02-7c41-7a6e-9d10-3f6c2b8e4a12","styles":[{"style":"classic","name":"Classic","description":"A white card with your name as letterhead, every line and the totals."},{"style":"bold","name":"Bold","description":"The figure that matters set large on a colour band, then the lines."},{"style":"minimal","name":"Minimal","description":"A short plain letter: the figure, the date and the lines."},{"style":"custom","name":"Custom","description":"Your own layout — the page, header and footer every email is drawn in."}],"kinds":[{"kind":"invoice","description":"Sent to the customer when a tax invoice is issued for their order.","dataSchema":"InvoiceTemplateData","sample":{"kind":"invoice","version":2,"shop":{"name":"Ridgeline Outdoor","email":"accounts@ridgeline-outdoor.example"},"invoice":{"number":"INV-1042"}},"activeTemplateId":"etp_01a15a02-7c41-7a6e-9d10-3f6c2b8e4a11","starterId":"invoice-custom"}],"starters":[],"typings":"declare module \"@manifold/email\" { … }"}}}}}},"401":{"description":"Unauthorized | TokenAlreadyUsed","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/UnauthorizedEncoded"},{"$ref":"#/components/schemas/TokenAlreadyUsedEncoded"}]}}}},"402":{"description":"SubscriptionRequired","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SubscriptionRequiredEncoded"}}}},"403":{"description":"TenantRequired | ScopeRequired | PlatformAdminRequired","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/TenantRequiredEncoded"},{"$ref":"#/components/schemas/ScopeRequiredEncoded"},{"$ref":"#/components/schemas/PlatformAdminRequiredEncoded"}]}}}},"404":{"description":"EmailTemplateNotFound","content":{"application/json":{"schema":{"$ref":"#/components/schemas/EmailTemplateNotFoundEncoded"}}}},"409":{"description":"EmailTemplateConflict | MirroredFromSource","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/EmailTemplateConflictEncoded"},{"$ref":"#/components/schemas/MirroredFromSourceEncoded"}]}}}},"503":{"description":"RequestLogUnavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RequestLogUnavailableEncoded"}}}}},"description":"Choose the tenant's email `style` — `classic`, `bold` or `minimal`, a look Manifold's starters share, or `custom`, the tenant's own layout (`layoutTemplateId`, a template of kind `layout`; absent to keep the one chosen before) drawn around each kind's content — so every kind without an active template of its own renders that style's starter from now; a kind with its own template keeps it. Answers the catalogue as it then stands. Appends `notifications.template-style-chosen`. 404 `EmailTemplateNotFound` for an unknown layout; 409 `EmailTemplateConflict` for `custom` with no layout, a template that is not a layout or is archived, or a layout named with another style. Idempotent by content: choosing the style (and layout) already chosen appends nothing.\n\nRequires `settings:write`.","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ChooseEmailTemplateStyleEncoded"},"example":{"style":"custom","layoutTemplateId":"etp_01a15a02-7c41-7a6e-9d10-3f6c2b8e4a12"}}},"required":true},"x-mcp-withheld":"The look every customer's and supplier's email wears is the merchant's choice, made once in Settings › Notifications › Email templates; an agent reads it in notifications_get_email_template_catalog.","x-required-scopes":["settings:write"],"x-example-source":{"origin":"contract"}}},"/email-templates/render":{"post":{"tags":["templates"],"operationId":"templates.render","parameters":[],"security":[{"bearer":[]}],"responses":{"200":{"description":"RenderedEmailTemplate","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RenderedEmailTemplateEncoded"},"examples":{"contract":{"summary":"templates.render","value":{"subject":"Invoice INV-1042 from Ridgeline Outdoor","html":"<!DOCTYPE html …>","text":"THANKS, MAYA\n\n$618.30 is due.","durationMs":41}}}}}},"401":{"description":"Unauthorized | TokenAlreadyUsed","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/UnauthorizedEncoded"},{"$ref":"#/components/schemas/TokenAlreadyUsedEncoded"}]}}}},"402":{"description":"SubscriptionRequired","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SubscriptionRequiredEncoded"}}}},"403":{"description":"TenantRequired | ScopeRequired | PlatformAdminRequired","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/TenantRequiredEncoded"},{"$ref":"#/components/schemas/ScopeRequiredEncoded"},{"$ref":"#/components/schemas/PlatformAdminRequiredEncoded"}]}}}},"409":{"description":"MirroredFromSource","content":{"application/json":{"schema":{"$ref":"#/components/schemas/MirroredFromSourceEncoded"}}}},"422":{"description":"TemplateInvalid","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TemplateInvalidEncoded"}}}},"503":{"description":"RequestLogUnavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RequestLogUnavailableEncoded"}}}}},"description":"Render a template's `source` for a `kind` (a `layout` around `previewKind`'s email) without keeping it — the editor's live preview, and how an agent checks a draft before saving it: answers the `subject`, the inbox `preview`, the `html` and its plain-text twin, rendered against `data` (as the kind's template data schema carries it) or the kind's sample. 422 `TemplateInvalid` with the `stage`, reason and `line`. A template is a TSX module in react-email's dialect: it exports `subject` (a string, or a function of the data), optionally `preview`, and the email as its default export — a function of the kind's template data returning react-email components (`Html`, `Body`, `Container`, `Section`, `Row`, `Column`, `Heading`, `Text`, `Button`, `Link`, `Img`, `Hr`, …) and plain HTML elements, imported from `@manifold/email` with the helpers `money`, `date` and `plural` (`GET /email-templates/catalog` answers the full declarations). It runs in a sandbox — no network, files, timers or other modules, 250 ms and 16 MB a render — and what it returns is held to the dialect: no script, event handler or class, links `https:`/`http:`/`mailto:`/`tel:`, images `https:`. Appends nothing: a render is a read of what the source would send, and the request row is acknowledged rather than committed. No idempotency key: a render records nothing, so a retry is simply another render.\n\nRequires `settings:write` or `notifications:write`.","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RenderEmailTemplateEncoded"},"example":{"kind":"invoice","source":"import { Container, Heading, Text, money } from \"@manifold/email\";\nexport const subject = (data) => `Invoice ${data.invoice.number} from ${data.shop.name}`;\nexport default function Invoice(data) {\n  return (\n    <Container>\n      <Heading>Thanks, {data.customer?.firstName ?? \"there\"}</Heading>\n      <Text>{money(data.invoice.totals.totalCents, data.invoice.currency)} is due.</Text>\n    </Container>\n  );\n}\n"}}},"required":true},"x-mcp-tool":{"name":"notifications_preview_email_template","title":"Notifications: Preview an email template","toolset":"notifications","readOnlyHint":false,"destructiveHint":false,"idempotentHint":false,"openWorldHint":false},"x-required-scopes":["settings:write","notifications:write"],"x-example-source":{"origin":"contract"}}},"/email-templates/{templateId}/test":{"post":{"tags":["templates"],"operationId":"templates.test","parameters":[{"name":"templateId","in":"path","schema":{"$ref":"#/components/schemas/EtpId"},"required":true,"example":"etp_01a15a02-7c41-7a6e-9d10-3f6c2b8e4a11"}],"security":[{"bearer":[]}],"responses":{"200":{"description":"Notification","content":{"application/json":{"schema":{"$ref":"#/components/schemas/NotificationEncoded"},"examples":{"contract":{"summary":"templates.test","value":{"id":"ntf_01a157ae-4288-7f3b-bb14-41f2affd24eb","kind":"template-test","channel":"email","status":"sent","to":["maya@ridgeline-outdoor.example"],"cc":[],"from":"\"Ridgeline Outdoor\" <accounts@ridgeline-outdoor.example>","replyTo":"accounts@ridgeline-outdoor.example","subject":"[Test] Invoice INV-1042 from Ridgeline Outdoor","source":{"kind":"email-template","id":"etp_01a15a02-7c41-7a6e-9d10-3f6c2b8e4a11"},"requestedBy":{"_tag":"user","id":"usr_01a15709-7582-7646-b491-261a138f0650"},"requestedAt":"2026-10-20T05:40:11.000Z","sentAt":"2026-10-20T05:40:12.000Z","providerMessageId":"0108019a2b3c4d5e-01a1587e-cd9b-7f2a-9b3c-4d5e6f7a8b9c-000000","steps":[{"status":"requested","at":"2026-10-20T05:40:11.000Z"},{"status":"sent","at":"2026-10-20T05:40:12.000Z"}],"template":{"templateId":"etp_01a15a02-7c41-7a6e-9d10-3f6c2b8e4a11","version":2}}}}}}},"400":{"description":"RecipientInvalid","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RecipientInvalidEncoded"}}}},"401":{"description":"Unauthorized | TokenAlreadyUsed","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/UnauthorizedEncoded"},{"$ref":"#/components/schemas/TokenAlreadyUsedEncoded"}]}}}},"402":{"description":"SubscriptionRequired","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SubscriptionRequiredEncoded"}}}},"403":{"description":"TenantRequired | ScopeRequired | PlatformAdminRequired","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/TenantRequiredEncoded"},{"$ref":"#/components/schemas/ScopeRequiredEncoded"},{"$ref":"#/components/schemas/PlatformAdminRequiredEncoded"}]}}}},"404":{"description":"EmailTemplateNotFound","content":{"application/json":{"schema":{"$ref":"#/components/schemas/EmailTemplateNotFoundEncoded"}}}},"409":{"description":"SenderNotConfigured | MirroredFromSource","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/SenderNotConfiguredEncoded"},{"$ref":"#/components/schemas/MirroredFromSourceEncoded"}]}}}},"422":{"description":"TemplateInvalid","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TemplateInvalidEncoded"}}}},"503":{"description":"MailProviderUnavailable | RequestLogUnavailable","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/MailProviderUnavailableEncoded"},{"$ref":"#/components/schemas/RequestLogUnavailableEncoded"}]}}}}},"description":"Send one of the tenant's templates, at its latest version and rendered with its kind's sample, to the person asking — at the address they signed in with, never one typed, since a template is the tenant's own content — from the tenant's sender as it stands, subject prefixed `[Test]`. It goes while the tenant is read-only. Appends `notifications.requested` (kind `template-test`, naming the template version), then `notifications.sent` or `notifications.failed`. 409 `SenderNotConfigured` until the sender is saved; 422 `TemplateInvalid` if it no longer renders. Keyed on `notificationId`, the caller-minted `ntf_` id: a retry answers the notification as recorded and never sends a second message.\n\nRequires `notifications:write`.","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SendTemplateTestEncoded"},"example":{"notificationId":"ntf_01a157ae-4288-7f3b-bb14-41f2affd24eb"}}},"required":true},"x-mcp-tool":{"name":"notifications_send_email_template_test","title":"Notifications: Send me an email template test","toolset":"notifications","readOnlyHint":false,"destructiveHint":false,"idempotentHint":true,"openWorldHint":true},"x-required-scopes":["notifications:write"],"x-example-source":{"origin":"contract"}}},"/brands/{tenantId}":{"get":{"tags":["brands"],"operationId":"brands.get","parameters":[{"name":"tenantId","in":"path","schema":{"$ref":"#/components/schemas/TenantId"},"required":true,"example":"org_01a156d2-8680-7738-ab2e-ff985e454887"}],"security":[],"responses":{"200":{"description":"PublicBrand","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PublicBrandEncoded"},"examples":{"contract":{"summary":"brands.get","value":{"tenantId":"org_01a156d2-8680-7738-ab2e-ff985e454887","businessName":"Ridgeline Outdoor","brandColour":"#1f4d3a","accentColour":"#1f6f50","contact":{"email":"accounts@ridgeline-outdoor.example","phone":"+61 2 9000 1234","website":"https://ridgeline-outdoor.example"},"footer":"Ridgeline Outdoor Pty Ltd · ABN 12 345 678 901","terms":"Quotes hold their prices until the date shown. Payment within 30 days of invoice.","onBrandColour":"#ffffff","logoUrl":"https://manifold-files.s3.ap-southeast-2.amazonaws.com/org_01a156d2-8680-7738-ab2e-ff985e454887/brand-logo-brand-logo-2026-10?X-Amz-Expires=900","logoVersion":"brand-logo-2026-10"}}}}}},"404":{"description":"BrandNotFound","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BrandNotFoundEncoded"}}}},"503":{"description":"BrandLogoUnavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BrandLogoUnavailableEncoded"}}}}},"description":"The brand a tenant's customer pages wear: its business name, colours, contact, footer, terms and a fifteen-minute signed URL for its logo, with the logo's version (its upload's reference), which the pages' logo address carries so a replaced logo is a new address. 404 `BrandNotFound` for a tenant that has not saved one (the pages then wear Manifold's plain look); 503 `BrandLogoUnavailable` when the logo's URL cannot be signed. Appends nothing.\n\nPublic: a brand is what every message and customer page already shows its customers, and names no record","x-mcp-withheld":"The brand as a tenant's customers see it is what the customer pages service reads to dress their pages; an agent reads the tenant's own brand with notifications_get_brand.","x-requires":{"kind":"public","reason":"a brand is what every message and customer page already shows its customers, and names no record"},"x-example-source":{"origin":"contract"}}},"/pages-hosts/{hostname}":{"get":{"tags":["brands"],"operationId":"brands.pagesHost","parameters":[{"name":"hostname","in":"path","schema":{"$ref":"#/components/schemas/PagesHostnameEncoded"},"required":true,"example":"orders.ridgeline-outdoor.example"}],"security":[],"responses":{"200":{"description":"PagesHost","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PagesHostEncoded"},"examples":{"contract":{"summary":"brands.pagesHost","value":{"hostname":"orders.ridgeline-outdoor.example","tenantId":"org_01a156d2-8680-7738-ab2e-ff985e454887","status":"live"}}}}}},"404":{"description":"PagesHostNotFound","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PagesHostNotFoundEncoded"}}}}},"description":"The tenant whose customer pages a host serves: what the customer pages service asks of a request that arrives on a host other than Manifold's own. Answers a `live` host, and a `lapsed` one (which the pages send to Manifold's host); 404 `PagesHostNotFound` for any other — never requested, still pending, or removed. Appends nothing.\n\nPublic: which tenant a live host serves is what its DNS already says publicly, and it names no record","x-mcp-withheld":"Which tenant a host serves is what the customer pages service asks of a request on a tenant's own host; an agent acts inside its own organization and never resolves hosts.","x-requires":{"kind":"public","reason":"which tenant a live host serves is what its DNS already says publicly, and it names no record"},"x-example-source":{"origin":"contract"}}},"/brands/{tenantId}/pages-host":{"get":{"tags":["brands"],"operationId":"brands.tenantPagesHost","parameters":[{"name":"tenantId","in":"path","schema":{"$ref":"#/components/schemas/TenantId"},"required":true,"example":"org_01a156d2-8680-7738-ab2e-ff985e454887"}],"security":[],"responses":{"200":{"description":"TenantPagesHost","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TenantPagesHostEncoded"},"examples":{"contract":{"summary":"brands.tenantPagesHost","value":{"tenantId":"org_01a156d2-8680-7738-ab2e-ff985e454887","hostname":"orders.ridgeline-outdoor.example"}}}}}}},"description":"The host a tenant's customer links name: its own while it is live, absent otherwise (links then name Manifold's pages host with the tenant in the path). Fulfillment asks it when it answers a link, and the customer pages when a link on Manifold's host should move to the tenant's. Appends nothing.\n\nPublic: a tenant's live host is printed in every link its customers are sent, and names no record","x-mcp-withheld":"The host a tenant's links name is what fulfillment and the customer pages read to build and move links; an agent is handed finished links and never builds one.","x-requires":{"kind":"public","reason":"a tenant's live host is printed in every link its customers are sent, and names no record"},"x-example-source":{"origin":"contract"}}},"/me/push/config":{"get":{"tags":["push"],"operationId":"push.config","parameters":[],"security":[{"bearer":[]}],"responses":{"200":{"description":"PushConfig","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PushConfigEncoded"},"examples":{"contract":{"summary":"push.config","value":{"provider":"fcm","web":{"apiKey":"AIzaSyDn3mU8x2f0Q-manifold-web","projectId":"manifold-508900","appId":"1:603158000000:web:9f1c2d3e4f5a6b7c","messagingSenderId":"603158000000","vapidKey":"BEl62iUYgUivxIkv69yViEuiBIa-Ib9-SkvMeAtA3LFgDzkrxZJjSgSnfckjBJuBkr3qBUYIHBQFLXYp5Nksh8U"}}}}}}},"401":{"description":"Unauthorized | TokenAlreadyUsed","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/UnauthorizedEncoded"},{"$ref":"#/components/schemas/TokenAlreadyUsedEncoded"}]}}}},"402":{"description":"SubscriptionRequired","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SubscriptionRequiredEncoded"}}}},"403":{"description":"TenantRequired | ScopeRequired | PlatformAdminRequired","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/TenantRequiredEncoded"},{"$ref":"#/components/schemas/ScopeRequiredEncoded"},{"$ref":"#/components/schemas/PlatformAdminRequiredEncoded"}]}}}},"409":{"description":"MirroredFromSource","content":{"application/json":{"schema":{"$ref":"#/components/schemas/MirroredFromSourceEncoded"}}}},"503":{"description":"RequestLogUnavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RequestLogUnavailableEncoded"}}}}},"description":"How a browser registers for push on this deployment: `provider` `fcm` with the Firebase web app (`web`) it asks for a token from, or `fake` on a local stack, where any token the browser makes up is accepted and nothing is delivered. Public values only; the service account stays with the service.\n\nRequires a signed-in session: the push service's public web app settings, the same for every signed-in person","x-mcp-withheld":"The push service's web app settings are what the admin hands the browser it registers; an agent has no browser to register.","x-requires":{"kind":"signed-in","reason":"the push service's public web app settings, the same for every signed-in person"},"x-example-source":{"origin":"contract"}}},"/me/push/devices":{"get":{"tags":["push"],"operationId":"push.devices","parameters":[],"security":[{"bearer":[]}],"responses":{"200":{"description":"PushDeviceList","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PushDeviceListEncoded"},"examples":{"contract":{"summary":"push.devices","value":{"items":[{"id":"pdv_01a15c20-4d5e-7f6a-8b9c-0d1e2f3a4b5c","label":"Sam's iPhone","platform":"ios","base":"/admin","registeredAt":"2026-10-29T01:12:00.000Z","lastSeenAt":"2026-10-29T01:12:00.000Z"}]}}}}}},"401":{"description":"Unauthorized | TokenAlreadyUsed","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/UnauthorizedEncoded"},{"$ref":"#/components/schemas/TokenAlreadyUsedEncoded"}]}}}},"402":{"description":"SubscriptionRequired","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SubscriptionRequiredEncoded"}}}},"403":{"description":"PushNeedsPerson | TenantRequired | ScopeRequired | PlatformAdminRequired","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/PushNeedsPersonEncoded"},{"$ref":"#/components/schemas/TenantRequiredEncoded"},{"$ref":"#/components/schemas/ScopeRequiredEncoded"},{"$ref":"#/components/schemas/PlatformAdminRequiredEncoded"}]}}}},"409":{"description":"MirroredFromSource","content":{"application/json":{"schema":{"$ref":"#/components/schemas/MirroredFromSourceEncoded"}}}},"503":{"description":"RequestLogUnavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RequestLogUnavailableEncoded"}}}}},"description":"The caller's own devices push goes to in this organization — each browser or installed admin they registered, with its label, the place the admin opens in it and when it was last seen — most recently seen first. 403 `PushNeedsPerson` for an app's or a background run's token.\n\nRequires a signed-in session: a person's own devices and preferences: the route reads and changes only the caller's","x-mcp-withheld":"A person's devices are theirs to see and remove under Settings › Push notifications; an agent tells people through notifications_notify_members.","x-requires":{"kind":"signed-in","reason":"a person's own devices and preferences: the route reads and changes only the caller's"},"x-example-source":{"origin":"contract"}},"put":{"tags":["push"],"operationId":"push.registerDevice","parameters":[],"security":[{"bearer":[]}],"responses":{"200":{"description":"PushDevice","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PushDeviceEncoded"},"examples":{"contract":{"summary":"push.registerDevice","value":{"id":"pdv_01a15c20-4d5e-7f6a-8b9c-0d1e2f3a4b5c","label":"Sam's iPhone","platform":"ios","base":"/admin","registeredAt":"2026-10-29T01:12:00.000Z","lastSeenAt":"2026-10-29T01:12:00.000Z"}}}}}},"401":{"description":"Unauthorized | TokenAlreadyUsed","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/UnauthorizedEncoded"},{"$ref":"#/components/schemas/TokenAlreadyUsedEncoded"}]}}}},"402":{"description":"SubscriptionRequired","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SubscriptionRequiredEncoded"}}}},"403":{"description":"PushNeedsPerson | TenantRequired | ScopeRequired | PlatformAdminRequired","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/PushNeedsPersonEncoded"},{"$ref":"#/components/schemas/TenantRequiredEncoded"},{"$ref":"#/components/schemas/ScopeRequiredEncoded"},{"$ref":"#/components/schemas/PlatformAdminRequiredEncoded"}]}}}},"409":{"description":"MirroredFromSource","content":{"application/json":{"schema":{"$ref":"#/components/schemas/MirroredFromSourceEncoded"}}}},"503":{"description":"RequestLogUnavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RequestLogUnavailableEncoded"}}}}},"description":"Register this browser, or the Manifold app on this phone, for push to the caller, with the token the push service gave it (Firebase's `getToken`), what the caller calls it (`label`), what it is (`platform`: `web`, `ios` or `android` — the app's are shown by the phone itself) and where the admin is mounted in it (`base`: `\"\"` on its own host, `/admin` in the Manifold app). Push goes only to the organization's own people: a device is registered by a signed-in person and belongs to them, never to an app or a background run (403 `PushNeedsPerson`). Appends `notifications.push-device-registered`. Idempotent by state: the token is the device, so registering it again appends nothing unless its label, its platform, its place or its person changed, or it was last seen more than a day ago — which is how last-seen moves; a token another person registered becomes the caller's.\n\nRequires a signed-in session: a person's own devices and preferences: the route reads and changes only the caller's","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RegisterPushDeviceEncoded"},"example":{"token":"fGq2k8x0TcS:APA91bHqv7oNfake-token-for-the-example","label":"Sam's iPhone","platform":"ios","base":"/admin"}}},"required":true},"x-mcp-withheld":"A device is the browser a person allowed to show notifications, registered by the admin with the push service's token; an agent has no such token.","x-requires":{"kind":"signed-in","reason":"a person's own devices and preferences: the route reads and changes only the caller's"},"x-example-source":{"origin":"contract"}}},"/me/push/devices/{deviceId}":{"delete":{"tags":["push"],"operationId":"push.removeDevice","parameters":[{"name":"deviceId","in":"path","schema":{"$ref":"#/components/schemas/PdvId"},"required":true,"example":"pdv_01a15c20-4d5e-7f6a-8b9c-0d1e2f3a4b5c"}],"security":[{"bearer":[]}],"responses":{"200":{"description":"PushDeviceList","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PushDeviceListEncoded"},"examples":{"contract":{"summary":"push.removeDevice","value":{"items":[]}}}}}},"401":{"description":"Unauthorized | TokenAlreadyUsed","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/UnauthorizedEncoded"},{"$ref":"#/components/schemas/TokenAlreadyUsedEncoded"}]}}}},"402":{"description":"SubscriptionRequired","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SubscriptionRequiredEncoded"}}}},"403":{"description":"PushNeedsPerson | TenantRequired | ScopeRequired | PlatformAdminRequired","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/PushNeedsPersonEncoded"},{"$ref":"#/components/schemas/TenantRequiredEncoded"},{"$ref":"#/components/schemas/ScopeRequiredEncoded"},{"$ref":"#/components/schemas/PlatformAdminRequiredEncoded"}]}}}},"404":{"description":"PushDeviceNotFound","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PushDeviceNotFoundEncoded"}}}},"409":{"description":"MirroredFromSource","content":{"application/json":{"schema":{"$ref":"#/components/schemas/MirroredFromSourceEncoded"}}}},"503":{"description":"RequestLogUnavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RequestLogUnavailableEncoded"}}}}},"description":"Stop pushing to one of the caller's devices, and answer the devices that remain. Appends `notifications.push-device-removed`. Idempotent by state: a device is removed once, and a retry meets 404 `PushDeviceNotFound` (as does another person's device) and appends nothing.\n\nRequires a signed-in session: a person's own devices and preferences: the route reads and changes only the caller's","x-mcp-withheld":"A person removes their own devices under Settings › Push notifications; an agent never stops someone else's notifications.","x-requires":{"kind":"signed-in","reason":"a person's own devices and preferences: the route reads and changes only the caller's"},"x-example-source":{"origin":"contract"}}},"/me/push/devices/{deviceId}/test":{"post":{"tags":["push"],"operationId":"push.testDevice","parameters":[{"name":"deviceId","in":"path","schema":{"$ref":"#/components/schemas/PdvId"},"required":true,"example":"pdv_01a15c20-4d5e-7f6a-8b9c-0d1e2f3a4b5c"}],"security":[{"bearer":[]}],"responses":{"200":{"description":"Notification","content":{"application/json":{"schema":{"$ref":"#/components/schemas/NotificationEncoded"},"examples":{"contract":{"summary":"push.testDevice","value":{"id":"ntf_01a15c42-6f7a-7b8c-9d0e-1f2a3b4c5d6e","kind":"push-test","channel":"push","status":"sent","to":["pdv_01a15c20-4d5e-7f6a-8b9c-0d1e2f3a4b5c"],"cc":[],"from":"Manifold","subject":"Push works","source":{"kind":"push-device","id":"pdv_01a15c20-4d5e-7f6a-8b9c-0d1e2f3a4b5c"},"requestedBy":{"_tag":"user","id":"usr_01a15709-7582-7646-b491-261a138f0650"},"requestedAt":"2026-10-29T01:13:00.000Z","recipient":{"user":"usr_01a15709-7582-7646-b491-261a138f0650"},"push":{"body":"Notifications reach Sam's iPhone. Tap to open your devices.","path":"/settings/push","actions":[]},"sentAt":"2026-10-29T01:13:01.000Z","providerMessageId":"projects/manifold-508900/messages/0:1761700381000000%e2b7c1f9e2b7c1f9","steps":[{"status":"requested","at":"2026-10-29T01:13:00.000Z"},{"status":"sent","at":"2026-10-29T01:13:01.000Z"}]}}}}}},"401":{"description":"Unauthorized | TokenAlreadyUsed","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/UnauthorizedEncoded"},{"$ref":"#/components/schemas/TokenAlreadyUsedEncoded"}]}}}},"402":{"description":"SubscriptionRequired","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SubscriptionRequiredEncoded"}}}},"403":{"description":"PushNeedsPerson | TenantRequired | ScopeRequired | PlatformAdminRequired","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/PushNeedsPersonEncoded"},{"$ref":"#/components/schemas/TenantRequiredEncoded"},{"$ref":"#/components/schemas/ScopeRequiredEncoded"},{"$ref":"#/components/schemas/PlatformAdminRequiredEncoded"}]}}}},"404":{"description":"PushDeviceNotFound","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PushDeviceNotFoundEncoded"}}}},"409":{"description":"MirroredFromSource","content":{"application/json":{"schema":{"$ref":"#/components/schemas/MirroredFromSourceEncoded"}}}},"503":{"description":"RequestLogUnavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RequestLogUnavailableEncoded"}}}}},"description":"Push a test to one of the caller's own devices, now — whatever kinds they switched off and whatever their quiet hours say, since they asked — to see that it arrives. Appends `notifications.requested`, then `notifications.sent` or `notifications.failed`; a token the push service no longer knows also appends `notifications.push-device-removed`. 404 `PushDeviceNotFound` for a device that is not the caller's. Keyed on `notificationId`, the caller-minted `ntf_` id: a retry answers the push as recorded and never pushes twice.\n\nRequires a signed-in session: a person's own devices and preferences: the route reads and changes only the caller's","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SendPushTestEncoded"},"example":{"notificationId":"ntf_01a15c42-6f7a-7b8c-9d0e-1f2a3b4c5d6e"}}},"required":true},"x-mcp-withheld":"A test push is how a person sees their own phone light up under Settings › Push notifications; there is nothing for an agent to see.","x-requires":{"kind":"signed-in","reason":"a person's own devices and preferences: the route reads and changes only the caller's"},"x-example-source":{"origin":"contract"}}},"/me/push/preferences":{"get":{"tags":["push"],"operationId":"push.preferences","parameters":[],"security":[{"bearer":[]}],"responses":{"200":{"description":"PushPreferences","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PushPreferencesEncoded"},"examples":{"contract":{"summary":"push.preferences","value":{"kinds":[{"kind":"approval-request","enabled":true},{"kind":"staff-alert","enabled":false}],"quietHours":{"start":"21:00","end":"07:00","timeZone":"Australia/Sydney"}}}}}}},"401":{"description":"Unauthorized | TokenAlreadyUsed","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/UnauthorizedEncoded"},{"$ref":"#/components/schemas/TokenAlreadyUsedEncoded"}]}}}},"402":{"description":"SubscriptionRequired","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SubscriptionRequiredEncoded"}}}},"403":{"description":"PushNeedsPerson | TenantRequired | ScopeRequired | PlatformAdminRequired","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/PushNeedsPersonEncoded"},{"$ref":"#/components/schemas/TenantRequiredEncoded"},{"$ref":"#/components/schemas/ScopeRequiredEncoded"},{"$ref":"#/components/schemas/PlatformAdminRequiredEncoded"}]}}}},"409":{"description":"MirroredFromSource","content":{"application/json":{"schema":{"$ref":"#/components/schemas/MirroredFromSourceEncoded"}}}},"503":{"description":"RequestLogUnavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RequestLogUnavailableEncoded"}}}}},"description":"Which kinds of push reach the caller's devices — every kind, on unless they switched it off — and the hours their devices stay quiet, when they set some.\n\nRequires a signed-in session: a person's own devices and preferences: the route reads and changes only the caller's","x-mcp-withheld":"A person chooses what reaches their devices and when they are quiet under Settings › Push notifications; an agent's raise is held to those choices.","x-requires":{"kind":"signed-in","reason":"a person's own devices and preferences: the route reads and changes only the caller's"},"x-example-source":{"origin":"contract"}},"put":{"tags":["push"],"operationId":"push.savePreferences","parameters":[],"security":[{"bearer":[]}],"responses":{"200":{"description":"PushPreferences","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PushPreferencesEncoded"},"examples":{"contract":{"summary":"push.savePreferences","value":{"kinds":[{"kind":"approval-request","enabled":true},{"kind":"staff-alert","enabled":false}],"quietHours":{"start":"21:00","end":"07:00","timeZone":"Australia/Sydney"}}}}}}},"401":{"description":"Unauthorized | TokenAlreadyUsed","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/UnauthorizedEncoded"},{"$ref":"#/components/schemas/TokenAlreadyUsedEncoded"}]}}}},"402":{"description":"SubscriptionRequired","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SubscriptionRequiredEncoded"}}}},"403":{"description":"PushNeedsPerson | TenantRequired | ScopeRequired | PlatformAdminRequired","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/PushNeedsPersonEncoded"},{"$ref":"#/components/schemas/TenantRequiredEncoded"},{"$ref":"#/components/schemas/ScopeRequiredEncoded"},{"$ref":"#/components/schemas/PlatformAdminRequiredEncoded"}]}}}},"409":{"description":"MirroredFromSource","content":{"application/json":{"schema":{"$ref":"#/components/schemas/MirroredFromSourceEncoded"}}}},"503":{"description":"RequestLogUnavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RequestLogUnavailableEncoded"}}}}},"description":"Replace the caller's push preferences: the kinds that reach their devices (`enabled`, every other kind off) and, optionally, quiet hours (`start` and `end` on a 24-hour clock in `timeZone`; an end before the start runs overnight). A push raised in quiet hours waits for their end. Appends `notifications.push-preferences-saved`. Idempotent by content: saving what is held appends nothing.\n\nRequires a signed-in session: a person's own devices and preferences: the route reads and changes only the caller's","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SavePushPreferencesEncoded"},"example":{"enabled":["approval-request"],"quietHours":{"start":"21:00","end":"07:00","timeZone":"Australia/Sydney"}}}},"required":true},"x-mcp-withheld":"What reaches a person's phone and when it stays quiet is that person's choice under Settings › Push notifications, never an agent's.","x-requires":{"kind":"signed-in","reason":"a person's own devices and preferences: the route reads and changes only the caller's"},"x-example-source":{"origin":"contract"}}},"/push":{"post":{"tags":["push"],"operationId":"push.notify","parameters":[],"security":[{"bearer":[]}],"responses":{"200":{"description":"PushRaise","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PushRaiseEncoded"},"examples":{"contract":{"summary":"push.notify","value":{"reference":"margin-approval:apr_7f2a","kind":"approval-request","notifications":[{"id":"ntf_01a15c42-6f7a-7b8c-9d0e-1f2a3b4c5d6e","kind":"approval-request","channel":"push","status":"sent","to":["pdv_01a15c20-4d5e-7f6a-8b9c-0d1e2f3a4b5c"],"cc":[],"from":"Manifold","subject":"Approve a price below margin","source":{"kind":"push","id":"margin-approval:apr_7f2a"},"requestedBy":{"_tag":"user","id":"usr_01a15709-7582-7646-b491-261a138f0650"},"requestedAt":"2026-10-29T01:13:00.000Z","recipient":{"user":"usr_01a15c31-5e6f-7a8b-9c0d-1e2f3a4b5c6d"},"push":{"body":"Sam asks to sell 12 × Trail tent 2P at 14% margin (minimum 22%) on SO-19203.","path":"/orders/ord_01a15a3c-7e21-7c4d-9b0e-5f6a7b8c9d0e?margin-approval=apr_7f2a","actions":[{"id":"approve","title":"Approve","path":"/orders/ord_01a15a3c-7e21-7c4d-9b0e-5f6a7b8c9d0e?margin-approval=apr_7f2a&decide=approve"},{"id":"decline","title":"Decline","path":"/orders/ord_01a15a3c-7e21-7c4d-9b0e-5f6a7b8c9d0e?margin-approval=apr_7f2a&decide=decline"}]},"sentAt":"2026-10-29T01:13:01.000Z","providerMessageId":"projects/manifold-508900/messages/0:1761700381000000%e2b7c1f9e2b7c1f9","steps":[{"status":"requested","at":"2026-10-29T01:13:00.000Z"},{"status":"sent","at":"2026-10-29T01:13:01.000Z"}]}],"skipped":[{"userId":"usr_01a15c53-7a8b-7c9d-8e0f-2a3b4c5d6e7f","reason":"no-device"}]}}}}}},"401":{"description":"Unauthorized | TokenAlreadyUsed","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/UnauthorizedEncoded"},{"$ref":"#/components/schemas/TokenAlreadyUsedEncoded"}]}}}},"402":{"description":"SubscriptionRequired","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SubscriptionRequiredEncoded"}}}},"403":{"description":"TenantRequired | ScopeRequired | PlatformAdminRequired","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/TenantRequiredEncoded"},{"$ref":"#/components/schemas/ScopeRequiredEncoded"},{"$ref":"#/components/schemas/PlatformAdminRequiredEncoded"}]}}}},"409":{"description":"MirroredFromSource","content":{"application/json":{"schema":{"$ref":"#/components/schemas/MirroredFromSourceEncoded"}}}},"503":{"description":"AudienceUnavailable | RequestLogUnavailable","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/AudienceUnavailableEncoded"},{"$ref":"#/components/schemas/RequestLogUnavailableEncoded"}]}}}}},"description":"Push to the organization's own people, never a customer: every active member holding one of `audience.roles`, or the members in `audience.users` (at most 50). Each person with `kind` on is pushed on every device they registered — `title`, `body`, the page `path` opens and up to two `actions`, each opening its own page, where the person's session confirms it (a tap is no authorisation); quiet hours hold it till they end. Appends `notifications.push-raised` (who it reached, who not) and a `notifications.requested` per device, then `notifications.sent` or `notifications.failed`. Not held by read-only mode; free. 503 `AudienceUnavailable` when roles cannot be read. Keyed on `reference`: a retry answers the raise as recorded and pushes no one twice.\n\nRequires `notifications:write`.","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/NotifyMembersEncoded"},"example":{"reference":"margin-approval:apr_7f2a","kind":"approval-request","audience":{"roles":["owner","admin"]},"title":"Approve a price below margin","body":"Sam asks to sell 12 × Trail tent 2P at 14% margin (minimum 22%) on SO-19203.","path":"/orders/ord_01a15a3c-7e21-7c4d-9b0e-5f6a7b8c9d0e?margin-approval=apr_7f2a","actions":[{"id":"approve","title":"Approve","path":"/orders/ord_01a15a3c-7e21-7c4d-9b0e-5f6a7b8c9d0e?margin-approval=apr_7f2a&decide=approve"},{"id":"decline","title":"Decline","path":"/orders/ord_01a15a3c-7e21-7c4d-9b0e-5f6a7b8c9d0e?margin-approval=apr_7f2a&decide=decline"}]}}},"required":true},"x-mcp-tool":{"name":"notifications_notify_members","title":"Notifications: Push to people in the organization","toolset":"notifications","readOnlyHint":false,"destructiveHint":false,"idempotentHint":true,"openWorldHint":true},"x-required-scopes":["notifications:write"],"x-example-source":{"origin":"contract"}}},"/me/alert-preferences":{"get":{"tags":["alerts"],"operationId":"alerts.preferences","parameters":[],"security":[{"bearer":[]}],"responses":{"200":{"description":"AlertPreferences","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AlertPreferencesEncoded"},"examples":{"contract":{"summary":"alerts.preferences","value":{"categories":[{"category":"integrations","enabled":true,"mandatory":false},{"category":"sync-problems","enabled":false,"mandatory":false},{"category":"books","enabled":true,"mandatory":false},{"category":"billing","enabled":true,"mandatory":true}]}}}}}},"401":{"description":"Unauthorized | TokenAlreadyUsed","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/UnauthorizedEncoded"},{"$ref":"#/components/schemas/TokenAlreadyUsedEncoded"}]}}}},"402":{"description":"SubscriptionRequired","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SubscriptionRequiredEncoded"}}}},"403":{"description":"PushNeedsPerson | TenantRequired | ScopeRequired | PlatformAdminRequired","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/PushNeedsPersonEncoded"},{"$ref":"#/components/schemas/TenantRequiredEncoded"},{"$ref":"#/components/schemas/ScopeRequiredEncoded"},{"$ref":"#/components/schemas/PlatformAdminRequiredEncoded"}]}}}},"409":{"description":"MirroredFromSource","content":{"application/json":{"schema":{"$ref":"#/components/schemas/MirroredFromSourceEncoded"}}}},"503":{"description":"RequestLogUnavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RequestLogUnavailableEncoded"}}}}},"description":"Which operational emails reach the caller as one of the organization's owners or admins — an integration disconnected, the daily sync digest, a ledger that refused a journal, and billing's binding notices: each category on unless they switched it off, and `mandatory` for the ones that cannot be (billing). 403 `PushNeedsPerson` for any session that is not the person: an AI agent acting for them, an app, a background run, an impersonating administrator, a station.\n\nRequires a signed-in session: a person's own email alert switches: the route reads and changes only the caller's, and refuses any session that is not the person (an agent, an app, a background run, an impersonating administrator, a station)","x-mcp-withheld":"A person chooses which operational emails about the organization reach them under Settings › Email alerts; an agent has no inbox of its own to tune.","x-requires":{"kind":"signed-in","reason":"a person's own email alert switches: the route reads and changes only the caller's, and refuses any session that is not the person (an agent, an app, a background run, an impersonating administrator, a station)"},"x-example-source":{"origin":"contract"}},"put":{"tags":["alerts"],"operationId":"alerts.savePreferences","parameters":[],"security":[{"bearer":[]}],"responses":{"200":{"description":"AlertPreferences","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AlertPreferencesEncoded"},"examples":{"contract":{"summary":"alerts.savePreferences","value":{"categories":[{"category":"integrations","enabled":true,"mandatory":false},{"category":"sync-problems","enabled":false,"mandatory":false},{"category":"books","enabled":true,"mandatory":false},{"category":"billing","enabled":true,"mandatory":true}]}}}}}},"401":{"description":"Unauthorized | TokenAlreadyUsed","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/UnauthorizedEncoded"},{"$ref":"#/components/schemas/TokenAlreadyUsedEncoded"}]}}}},"402":{"description":"SubscriptionRequired","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SubscriptionRequiredEncoded"}}}},"403":{"description":"PushNeedsPerson | TenantRequired | ScopeRequired | PlatformAdminRequired","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/PushNeedsPersonEncoded"},{"$ref":"#/components/schemas/TenantRequiredEncoded"},{"$ref":"#/components/schemas/ScopeRequiredEncoded"},{"$ref":"#/components/schemas/PlatformAdminRequiredEncoded"}]}}}},"409":{"description":"MirroredFromSource","content":{"application/json":{"schema":{"$ref":"#/components/schemas/MirroredFromSourceEncoded"}}}},"503":{"description":"RequestLogUnavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RequestLogUnavailableEncoded"}}}}},"description":"Replace the operational-email categories the caller switched off (`muted`, every other on); a binding category (`billing`) cannot be listed. Only the person sets them: 403 `PushNeedsPerson` for an AI agent acting for them (whatever it was granted), an app, a background run, an impersonating administrator or a station. Appends `notifications.alert-preferences-saved`. Idempotent by content: saving what is held appends nothing.\n\nRequires a signed-in session: a person's own email alert switches: the route reads and changes only the caller's, and refuses any session that is not the person (an agent, an app, a background run, an impersonating administrator, a station)","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SaveAlertPreferencesEncoded"},"example":{"muted":["sync-problems"]}}},"required":true},"x-mcp-withheld":"Which operational emails reach a person is that person's own choice under Settings › Email alerts, never an agent's.","x-requires":{"kind":"signed-in","reason":"a person's own email alert switches: the route reads and changes only the caller's, and refuses any session that is not the person (an agent, an app, a background run, an impersonating administrator, a station)"},"x-example-source":{"origin":"contract"}}},"/events":{"get":{"tags":["events"],"operationId":"events.list","parameters":[{"name":"since","in":"query","schema":{"type":"string"},"required":false,"example":"41"},{"name":"limit","in":"query","schema":{"type":"string"},"required":false,"example":"500"},{"name":"upTo","in":"query","schema":{"type":"string"},"required":false}],"security":[{"bearer":[]}],"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"type":"array","items":{"anyOf":[{"$ref":"#/components/schemas/notifications.sender-savedEncoded"},{"$ref":"#/components/schemas/notifications.sending-domain-addedEncoded"},{"$ref":"#/components/schemas/notifications.sending-domain-verifiedEncoded"},{"$ref":"#/components/schemas/notifications.sending-domain-failedEncoded"},{"$ref":"#/components/schemas/notifications.sending-domain-removedEncoded"},{"$ref":"#/components/schemas/notifications.sms-sender-savedEncoded"},{"$ref":"#/components/schemas/notifications.sms-sender-country-changedEncoded"},{"$ref":"#/components/schemas/notifications.sms-sender-removedEncoded"},{"$ref":"#/components/schemas/notifications.requestedEncoded"},{"$ref":"#/components/schemas/notifications.sentEncoded"},{"$ref":"#/components/schemas/notifications.failedEncoded"},{"$ref":"#/components/schemas/notifications.deliveredEncoded"},{"$ref":"#/components/schemas/notifications.delayedEncoded"},{"$ref":"#/components/schemas/notifications.bouncedEncoded"},{"$ref":"#/components/schemas/notifications.complainedEncoded"},{"$ref":"#/components/schemas/notifications.openedEncoded"},{"$ref":"#/components/schemas/notifications.clickedEncoded"},{"$ref":"#/components/schemas/notifications.opted-outEncoded"},{"$ref":"#/components/schemas/notifications.address-suppressedEncoded"},{"$ref":"#/components/schemas/notifications.suppression-liftedEncoded"},{"$ref":"#/components/schemas/notifications.tracking-setEncoded"},{"$ref":"#/components/schemas/notifications.template-savedEncoded"},{"$ref":"#/components/schemas/notifications.template-archivedEncoded"},{"$ref":"#/components/schemas/notifications.template-activatedEncoded"},{"$ref":"#/components/schemas/notifications.template-style-chosenEncoded"},{"$ref":"#/components/schemas/notifications.brand-savedEncoded"},{"$ref":"#/components/schemas/notifications.brand-logo-savedEncoded"},{"$ref":"#/components/schemas/notifications.brand-logo-removedEncoded"},{"$ref":"#/components/schemas/notifications.push-device-registeredEncoded"},{"$ref":"#/components/schemas/notifications.push-device-removedEncoded"},{"$ref":"#/components/schemas/notifications.push-preferences-savedEncoded"},{"$ref":"#/components/schemas/notifications.push-raisedEncoded"},{"$ref":"#/components/schemas/notifications.pages-domain-requestedEncoded"},{"$ref":"#/components/schemas/notifications.pages-domain-registeredEncoded"},{"$ref":"#/components/schemas/notifications.pages-domain-refusedEncoded"},{"$ref":"#/components/schemas/notifications.pages-domain-verifiedEncoded"},{"$ref":"#/components/schemas/notifications.pages-domain-liveEncoded"},{"$ref":"#/components/schemas/notifications.pages-domain-lapsedEncoded"},{"$ref":"#/components/schemas/notifications.pages-domain-removedEncoded"},{"$ref":"#/components/schemas/notifications.alert-preferences-savedEncoded"},{"$ref":"#/components/schemas/notifications.sync-problem-notedEncoded"}]}},"examples":{"contract":{"summary":"events.list","value":[{"_tag":"notifications.requested","eventId":"evt_01a1581c-208c-763f-a253-ebed1feb2268","txId":"tx_01a15853-0f8e-757f-9a34-afad80e0abf5","tenantId":"org_01a156d2-8680-7738-ab2e-ff985e454887","sequence":41,"occurredAt":"2026-10-20T05:40:11.000Z","source":"notifications-manager","version":1,"actor":{"_tag":"user","id":"usr_01a15709-7582-7646-b491-261a138f0650"},"correlationId":"req_01a157e5-318a-7e8f-92b2-a2a1bd882b0f","payload":{"notificationId":"ntf_01a157ae-4288-7f3b-bb14-41f2affd24eb","kind":"sending-test","channel":"email","to":["ops@ridgeline-outdoor.example"],"cc":[],"from":"\"Ridgeline Outdoor\" <accounts@ridgeline-outdoor.example>","replyTo":"accounts@ridgeline-outdoor.example","subject":"Test message from Ridgeline Outdoor","source":{"kind":"settings","id":"sender"}}},{"_tag":"notifications.sent","eventId":"evt_01a15889-fe90-7c50-8c80-064cc824f438","txId":"tx_01a158c0-ed92-7a97-baae-49c3a7e8454e","tenantId":"org_01a156d2-8680-7738-ab2e-ff985e454887","sequence":42,"occurredAt":"2026-10-20T05:40:12.000Z","source":"notifications-manager","version":1,"actor":{"_tag":"system","id":"notifications-manager:send"},"correlationId":"req_01a157e5-318a-7e8f-92b2-a2a1bd882b0f","causationId":"evt_01a1581c-208c-763f-a253-ebed1feb2268","payload":{"notificationId":"ntf_01a157ae-4288-7f3b-bb14-41f2affd24eb","providerMessageId":"0108019a2b3c4d5e-01a1587e-cd9b-7f2a-9b3c-4d5e6f7a8b9c-000000"}}]}}}}},"401":{"description":"Unauthorized | TokenAlreadyUsed","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/UnauthorizedEncoded"},{"$ref":"#/components/schemas/TokenAlreadyUsedEncoded"}]}}}},"402":{"description":"SubscriptionRequired","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SubscriptionRequiredEncoded"}}}},"403":{"description":"TenantRequired | ScopeRequired | PlatformAdminRequired","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/TenantRequiredEncoded"},{"$ref":"#/components/schemas/ScopeRequiredEncoded"},{"$ref":"#/components/schemas/PlatformAdminRequiredEncoded"}]}}}},"409":{"description":"MirroredFromSource","content":{"application/json":{"schema":{"$ref":"#/components/schemas/MirroredFromSourceEncoded"}}}},"503":{"description":"RequestLogUnavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RequestLogUnavailableEncoded"}}}}},"description":"Replay committed notifications events at-or-after `since` (a journal sequence number), oldest first: the sender saved, the sending domain added, verified, failed and removed, the SMS sender ID saved, moved in a country and removed, every notification requested, sent and failed and what the provider reported of it — delivered, delayed, bounced, marked as spam, opened, clicked (a customer opening the page its message linked to among them), opted out — every address suppressed and lifted, tracking switched, every email template saved, archived and activated, the email style chosen, the brand saved and its logo saved and removed, the customer pages' own host requested, verified, gone live, lapsed and removed, every push device registered and removed, push preferences saved, every push raised, alert preferences saved and every sync problem noted for the daily digest. One response is a page: `limit` defaults to 500 and is capped at 5000 (an over-cap request is clamped). Pages are `sequence`-ordered and the boundary is stable — repeat with `since=<last event's sequence + 1>` until a page comes back smaller than `limit` to replay the journal exactly once. `upTo` (inclusive) ends the replay at a sequence instead of the journal's head — with `GET /events/head` it replays the journal as it stood at a moment. Appends nothing: a read of facts already journalled.\n\nRequires `notifications:read` or `activity:read`.","x-mcp-withheld":"The journal replay a consumer pages through to build its projection; agents read the projections the list and get tools serve, and the audit trail (`audit_trail`) for history.","x-required-scopes":["notifications:read","activity:read"],"x-example-source":{"origin":"contract"}}},"/events/head":{"get":{"tags":["events"],"operationId":"events.head","parameters":[{"name":"at","in":"query","schema":{"type":"string"},"required":true,"example":"2026-10-20T06:00:00.000Z"}],"security":[{"bearer":[]}],"responses":{"200":{"description":"Where a tenant's journal stood at a moment.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/JournalHead"},"examples":{"contract":{"summary":"events.head","value":{"at":"2026-10-20T06:00:00.000Z","sequence":42}}}}}},"401":{"description":"Unauthorized | TokenAlreadyUsed","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/UnauthorizedEncoded"},{"$ref":"#/components/schemas/TokenAlreadyUsedEncoded"}]}}}},"402":{"description":"SubscriptionRequired","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SubscriptionRequiredEncoded"}}}},"403":{"description":"TenantRequired | ScopeRequired | PlatformAdminRequired","content":{"application/json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/TenantRequiredEncoded"},{"$ref":"#/components/schemas/ScopeRequiredEncoded"},{"$ref":"#/components/schemas/PlatformAdminRequiredEncoded"}]}}}},"409":{"description":"MirroredFromSource","content":{"application/json":{"schema":{"$ref":"#/components/schemas/MirroredFromSourceEncoded"}}}},"503":{"description":"RequestLogUnavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RequestLogUnavailableEncoded"}}}}},"description":"The journal's position at a moment: the last `sequence` the database had recorded for this tenant at `at` (absent when it held nothing yet), by the database's own clock rather than the service's. Replaying with `upTo=<sequence>` then gives the journal exactly as it stood then; a set of heads taken at one `at` is a consistent cut across journals. Appends nothing: a read of facts already journalled.\n\nRequires `notifications:read` or `activity:read`.","x-mcp-withheld":"Where a journal stood at a moment, for a consumer cutting journals to replay them as of then; agents read history through the audit trail (`audit_trail`).","x-required-scopes":["notifications:read","activity:read"],"x-example-source":{"origin":"contract"}}}},"components":{"schemas":{"SdmId":{"type":"string","pattern":"^sdm_[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$","description":"A sdm-prefixed uuid, e.g. sdm_9f8c1c2e-0000-4000-8000-000000000000"},"SendingDomainStatus":{"type":"string","enum":["pending","verified","failed"],"description":"`pending` — added; mail keeps going from Manifold's address until the DNS records are found; `verified` — the DKIM records are found and mail goes from the tenant's own address; `failed` — the provider gave up looking (records missing for 72 hours): check the records and look again."},"DnsRecordPurpose":{"type":"string","enum":["dkim","mail-from-mx","mail-from-spf","dmarc"],"description":"What a record is for: `dkim` — one of three keys that sign the mail (required); `mail-from-mx` and `mail-from-spf` — the bounce subdomain, so the envelope sender aligns with the From address; `dmarc` — the domain's DMARC policy (recommended when the domain has none)."},"DnsRecordType":{"type":"string","enum":["CNAME","MX","TXT"],"description":"The DNS record type to create: `CNAME`, `MX` or `TXT`."},"DnsRecordState":{"type":"string","enum":["found","missing","mismatch","unchecked"],"description":"What the last lookup found: `found` — the record resolves to the value asked for; `missing` — nothing at that name; `mismatch` — something else is there; `unchecked` — not looked up yet."},"CountryCode":{"type":"string","pattern":"^[A-Z]{2}$","description":"ISO 3166-1 alpha-2, upper case"},"SmsSenderCountryStatus":{"type":"string","enum":["requested","active","unsupported","failed"],"description":"Where the sender ID stands in a country: `requested` — asked of the SMS provider and waiting on the country's registration (texts to that country are refused until it is active); `active` — texts to the country arrive from the sender ID; `unsupported` — the country's carriers accept no alphanumeric sender IDs (the United States, Canada): texts there go from Manifold's own number with the sender's name first, where Manifold has one; `failed` — the provider refused the sender ID there, with the reason."},"NotificationSettingsEncoded":{"type":"object","properties":{"sender":{"type":"object","properties":{"senderName":{"type":"string","minLength":1,"maxLength":120},"accountsEmail":{"type":"string"}},"required":["senderName","accountsEmail"],"additionalProperties":false},"domain":{"type":"object","properties":{"id":{"$ref":"#/components/schemas/SdmId"},"domain":{"type":"string"},"status":{"$ref":"#/components/schemas/SendingDomainStatus"},"mailFromDomain":{"type":"string"},"records":{"type":"array","items":{"type":"object","properties":{"purpose":{"$ref":"#/components/schemas/DnsRecordPurpose"},"type":{"$ref":"#/components/schemas/DnsRecordType"},"name":{"type":"string"},"value":{"type":"string"},"required":{"type":"boolean"},"state":{"$ref":"#/components/schemas/DnsRecordState"},"found":{"type":"string"}},"required":["purpose","type","name","value","required"],"additionalProperties":false}},"reason":{"type":"string"},"addedAt":{"type":"string"},"verifiedAt":{"type":"string"},"checkedAt":{"type":"string"}},"required":["id","domain","status","mailFromDomain","records","addedAt"],"additionalProperties":false},"sms":{"type":"object","properties":{"senderId":{"type":"string"},"countries":{"type":"array","items":{"type":"object","properties":{"country":{"$ref":"#/components/schemas/CountryCode"},"status":{"$ref":"#/components/schemas/SmsSenderCountryStatus"},"reason":{"type":"string"}},"required":["country","status"],"additionalProperties":false}}},"required":["senderId","countries"],"additionalProperties":false},"tracking":{"type":"boolean"},"fromAddress":{"type":"string"},"platformFromAddress":{"type":"string"}},"required":["tracking","fromAddress","platformFromAddress"],"additionalProperties":false},"UnauthorizedEncoded":{"type":"object","properties":{"_tag":{"type":"string","enum":["Unauthorized"]},"reason":{"type":"string"}},"required":["_tag","reason"],"additionalProperties":false},"TokenAlreadyUsedEncoded":{"type":"object","properties":{"_tag":{"type":"string","enum":["TokenAlreadyUsed"]},"tokenId":{"type":"string"}},"required":["_tag","tokenId"],"additionalProperties":false},"RequestLogUnavailableEncoded":{"type":"object","properties":{"_tag":{"type":"string","enum":["RequestLogUnavailable"]},"tokenId":{"type":"string"},"reason":{"type":"string"}},"required":["_tag","tokenId","reason"],"additionalProperties":false},"TenantRequiredEncoded":{"type":"object","properties":{"_tag":{"type":"string","enum":["TenantRequired"]},"userId":{"type":"string"}},"required":["_tag","userId"],"additionalProperties":false},"ScopeRequiredEncoded":{"type":"object","properties":{"_tag":{"type":"string","enum":["ScopeRequired"]},"required":{"type":"array","items":{"type":"string"}}},"required":["_tag","required"],"additionalProperties":false},"PlatformAdminRequiredEncoded":{"type":"object","properties":{"_tag":{"type":"string","enum":["PlatformAdminRequired"]},"userId":{"type":"string"}},"required":["_tag","userId"],"additionalProperties":false},"SubscriptionRequiredEncoded":{"type":"object","properties":{"_tag":{"type":"string","enum":["SubscriptionRequired"]},"status":{"type":"string"}},"required":["_tag","status"],"additionalProperties":false},"MirroredFromSourceEncoded":{"type":"object","properties":{"_tag":{"type":"string","enum":["MirroredFromSource"]},"source":{"type":"string"}},"required":["_tag","source"],"additionalProperties":false},"EmailEncoded":{"type":"string"},"SaveSenderSettingsEncoded":{"type":"object","properties":{"senderName":{"type":"string","minLength":1,"maxLength":120},"accountsEmail":{"$ref":"#/components/schemas/EmailEncoded"}},"required":["senderName","accountsEmail"],"additionalProperties":false},"DomainNameEncoded":{"type":"string"},"AddSendingDomainEncoded":{"type":"object","properties":{"domain":{"$ref":"#/components/schemas/DomainNameEncoded"}},"required":["domain"],"additionalProperties":false},"SendingDomainExistsEncoded":{"type":"object","properties":{"_tag":{"type":"string","enum":["SendingDomainExists"]},"domain":{"type":"string"}},"required":["_tag","domain"],"additionalProperties":false},"SendingDomainUnavailableEncoded":{"type":"object","properties":{"_tag":{"type":"string","enum":["SendingDomainUnavailable"]},"domain":{"type":"string"},"reason":{"type":"string"}},"required":["_tag","domain","reason"],"additionalProperties":false},"MailProviderUnavailableEncoded":{"type":"object","properties":{"_tag":{"type":"string","enum":["MailProviderUnavailable"]},"reason":{"type":"string"}},"required":["_tag","reason"],"additionalProperties":false},"SendingDomainNotFoundEncoded":{"type":"object","properties":{"_tag":{"type":"string","enum":["SendingDomainNotFound"]},"reason":{"type":"string"}},"required":["_tag","reason"],"additionalProperties":false},"SmsSenderIdEncoded":{"type":"string"},"SaveSmsSenderEncoded":{"type":"object","properties":{"senderId":{"$ref":"#/components/schemas/SmsSenderIdEncoded"},"countries":{"type":"array","items":{"$ref":"#/components/schemas/CountryCode"},"minItems":1,"maxItems":30}},"required":["senderId","countries"],"additionalProperties":false},"SmsProviderUnavailableEncoded":{"type":"object","properties":{"_tag":{"type":"string","enum":["SmsProviderUnavailable"]},"reason":{"type":"string"}},"required":["_tag","reason"],"additionalProperties":false},"SmsSenderNotFoundEncoded":{"type":"object","properties":{"_tag":{"type":"string","enum":["SmsSenderNotFound"]},"reason":{"type":"string"}},"required":["_tag","reason"],"additionalProperties":false},"SaveTrackingEncoded":{"type":"object","properties":{"enabled":{"type":"boolean"}},"required":["enabled"],"additionalProperties":false},"HexColour":{"type":"string","pattern":"^#[0-9a-f]{6}$","description":"A colour as `#rrggbb`, lower case"},"BrandContact":{"type":"object","properties":{"email":{"type":"string"},"phone":{"type":"string"},"website":{"type":"string","maxLength":200,"pattern":"^https:\\/\\/[^\\s<>\"']+$"},"address":{"type":"string"}},"additionalProperties":false,"description":"How the tenant's customers reach it: email, phone, website and address."},"BrandLogoType":{"type":"string","enum":["image/png","image/jpeg"],"description":"A logo's media type: `image/png` or `image/jpeg` (SVG can carry script, so it is refused)"},"BrandLogo":{"type":"object","properties":{"reference":{"type":"string","minLength":1},"contentType":{"$ref":"#/components/schemas/BrandLogoType"},"size":{"type":"integer","exclusiveMinimum":0},"version":{"type":"integer","exclusiveMinimum":0},"storedAt":{"type":"string"}},"required":["reference","contentType","size","version","storedAt"],"additionalProperties":false},"BrandEncoded":{"type":"object","properties":{"businessName":{"type":"string"},"brandColour":{"$ref":"#/components/schemas/HexColour"},"accentColour":{"$ref":"#/components/schemas/HexColour"},"contact":{"$ref":"#/components/schemas/BrandContact"},"footer":{"type":"string"},"terms":{"type":"string"},"onBrandColour":{"$ref":"#/components/schemas/HexColour"},"logo":{"$ref":"#/components/schemas/BrandLogo"}},"required":["businessName","brandColour","accentColour","onBrandColour"],"additionalProperties":false},"BrandNotFoundEncoded":{"type":"object","properties":{"_tag":{"type":"string","enum":["BrandNotFound"]}},"required":["_tag"],"additionalProperties":false},"SaveBrandEncoded":{"type":"object","properties":{"businessName":{"type":"string"},"brandColour":{"$ref":"#/components/schemas/HexColour"},"accentColour":{"$ref":"#/components/schemas/HexColour"},"contact":{"$ref":"#/components/schemas/BrandContact"},"footer":{"type":"string"},"terms":{"type":"string"}},"required":["businessName","brandColour","accentColour"],"additionalProperties":false},"BrandColourContrastEncoded":{"type":"object","properties":{"_tag":{"type":"string","enum":["BrandColourContrast"]},"colour":{"$ref":"#/components/schemas/HexColour"},"ratio":{"anyOf":[{"type":"number"},{"type":"string","enum":["Infinity","-Infinity","NaN"]}]},"minimum":{"anyOf":[{"type":"number"},{"type":"string","enum":["Infinity","-Infinity","NaN"]}]}},"required":["_tag","colour","ratio","minimum"],"additionalProperties":false},"BrandLogoRefusedEncoded":{"type":"object","properties":{"_tag":{"type":"string","enum":["BrandLogoRefused"]},"reason":{"type":"string"}},"required":["_tag","reason"],"additionalProperties":false},"BrandLogoUnavailableEncoded":{"type":"object","properties":{"_tag":{"type":"string","enum":["BrandLogoUnavailable"]},"reason":{"type":"string"}},"required":["_tag","reason"],"additionalProperties":false},"PgdId":{"type":"string","pattern":"^pgd_[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$","description":"A pgd-prefixed uuid, e.g. pgd_9f8c1c2e-0000-4000-8000-000000000000"},"PagesDomainStatus":{"type":"string","enum":["pending","verified","live","lapsed","refused"],"description":"`pending` — requested; pages stay on Manifold's host until the name is routed to Manifold; `refused` — the edge would not take the host (its `reason` says why): remove it and add another; `verified` — the edge found the name routed to it and is issuing its certificate; `live` — every new link and message names the tenant's host; `lapsed` — it was live but no longer reaches Manifold, so links name Manifold's host until it is restored."},"PagesDnsRecordPurpose":{"type":"string","enum":["route","ownership","certificate"],"description":"What a record is for: `route` — the `CNAME` that sends the name to Manifold (required, kept while the host is used); `ownership` — a `TXT` proving the name before the `CNAME` moves (optional); `certificate` — a `TXT` the certificate authority asks for when it cannot check over the `CNAME`."},"PagesDnsRecordType":{"type":"string","enum":["CNAME","TXT"],"description":"The DNS record type to create for the pages host: `CNAME` or `TXT`."},"PagesDnsRecord":{"type":"object","properties":{"purpose":{"$ref":"#/components/schemas/PagesDnsRecordPurpose"},"type":{"$ref":"#/components/schemas/PagesDnsRecordType"},"name":{"type":"string"},"value":{"type":"string"},"required":{"type":"boolean"}},"required":["purpose","type","name","value","required"],"additionalProperties":false,"description":"One DNS record to create for the pages host."},"PagesDomainSettingsEncoded":{"type":"object","properties":{"domain":{"type":"object","properties":{"id":{"$ref":"#/components/schemas/PgdId"},"hostname":{"type":"string"},"status":{"$ref":"#/components/schemas/PagesDomainStatus"},"records":{"type":"array","items":{"$ref":"#/components/schemas/PagesDnsRecord"}},"edgeId":{"type":"string"},"requestedAt":{"type":"string"},"verifiedAt":{"type":"string"},"liveAt":{"type":"string"},"lapsedAt":{"type":"string"},"reason":{"type":"string"},"problems":{"type":"array","items":{"type":"string"}},"checkedAt":{"type":"string"}},"required":["id","hostname","status","records","requestedAt"],"additionalProperties":false},"available":{"type":"boolean"},"target":{"type":"string"},"origin":{"type":"string"}},"required":["available","target","origin"],"additionalProperties":false},"PagesHostnameEncoded":{"type":"string"},"AddPagesDomainEncoded":{"type":"object","properties":{"hostname":{"$ref":"#/components/schemas/PagesHostnameEncoded"}},"required":["hostname"],"additionalProperties":false},"PagesDomainExistsEncoded":{"type":"object","properties":{"_tag":{"type":"string","enum":["PagesDomainExists"]},"hostname":{"type":"string"}},"required":["_tag","hostname"],"additionalProperties":false},"PagesDomainUnavailableEncoded":{"type":"object","properties":{"_tag":{"type":"string","enum":["PagesDomainUnavailable"]},"hostname":{"type":"string"},"reason":{"type":"string"}},"required":["_tag","hostname","reason"],"additionalProperties":false},"PagesEdgeUnavailableEncoded":{"type":"object","properties":{"_tag":{"type":"string","enum":["PagesEdgeUnavailable"]},"reason":{"type":"string"}},"required":["_tag","reason"],"additionalProperties":false},"PagesDomainNotFoundEncoded":{"type":"object","properties":{"_tag":{"type":"string","enum":["PagesDomainNotFound"]},"reason":{"type":"string"}},"required":["_tag","reason"],"additionalProperties":false},"NotificationStatus":{"type":"string","enum":["requested","sent","delivered","opened","clicked","failed","bounced","complained"],"description":"Where a notification stands: `requested` — recorded and on its way to the provider; `sent` — the provider accepted it (its message id is kept); `delivered` — the recipient's mail server, or the phone's carrier, took it; `opened` — the recipient opened the email (tracked customer mail only, and only the first open is recorded); `clicked` — the recipient followed a link in it (tracked customer mail only, the first click); `failed` — refused before or at the provider, with the reason; `bounced` — sent, but the address or number could not be reached, with the provider's diagnostic; `complained` — the recipient marked it as spam."},"NotificationKind":{"type":"string","enum":["sending-test","quote","template-test","carrier-quotes-degraded","supplier-alert","push-test","approval-request","staff-alert","gift-card","pages-domain-lapsed","integration-disconnected","sync-digest","ledger-blocked","payment-failed","subscription-lapsed"],"description":"What a notification is. `sending-test` — a test message an operator sends to check the tenant's sender; `quote` — an issued quote sent to the customer, its lines and total as issued; `template-test` — one of the tenant's email templates rendered with its kind's sample data and sent to the operator who asked; `carrier-quotes-degraded` — an alert to the tenant's own owners and admins that one of its carrier accounts is missing its live quotes, so checkouts are not showing its services (sent when it starts, and as a reminder at most daily while it lasts); `supplier-alert` — an alert to the tenant's own owners and admins that a supplier's damage or lateness crossed the threshold the tenant set (`purchasing.supplier-alert-raised`, at most once a month per supplier and rate); `push-test` — a push a person sends to one of their own devices to see it arrive; `approval-request` — a push asking one of the tenant's people to approve or decline something; `staff-alert` — a push telling one of the tenant's people something now; `gift-card` — a gift card's code, to its recipient; `pages-domain-lapsed` — an alert to the tenant's own owners and admins that its own host for customer pages no longer reaches Manifold, so customer links name Manifold's pages host until it is restored; `integration-disconnected` — an operational email to the tenant's own owners and admins that a sales channel, carrier account or ledger stopped working for it, with where to reconnect; `sync-digest` — the daily digest to the owners and admins of the sync problems heard since the last one (orders not brought in, imports that failed), never sent for a day with nothing new; `ledger-blocked` — an operational email to the owners and admins that a ledger refused a journal Manifold sent it (at most once a day per ledger); `payment-failed` — the binding notice to the owners and admins that the subscription's payment failed and it is past due; `subscription-lapsed` — the binding notice that the subscription ended, so the account is read-only until it is restored."},"NotificationChannel":{"type":"string","enum":["email","sms","push"],"description":"How a notification travels: `email` — through the mail provider, from the tenant's sender; `sms` — a text message to a mobile number, under the tenant's SMS sender ID; `push` — to one registered device of one of the tenant's own people, through the push service."},"NtfId":{"type":"string","pattern":"^ntf_[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$","description":"A ntf-prefixed uuid, e.g. ntf_9f8c1c2e-0000-4000-8000-000000000000"},"NotificationAddress":{"type":"string","pattern":"^(?:[^\\s@A-Z]+@[^\\s@A-Z]+\\.[^\\s@A-Z]+|\\+[1-9][0-9]{6,14}|pdv_[0-9a-f-]{36})$","description":"A recipient as recorded: an email address, lower-cased, an E.164 phone number (`+61412345678`), or the `pdv_` device a push went to."},"SmsOrigin":{"type":"string","enum":["sender-id","platform-number"],"description":"What a text message goes out from: `sender-id` — the tenant's alphanumeric sender ID; `platform-number` — Manifold's own number, the sender's name starting the text, for a country that accepts no sender IDs."},"EtpId":{"type":"string","pattern":"^etp_[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$","description":"A etp-prefixed uuid, e.g. etp_9f8c1c2e-0000-4000-8000-000000000000"},"NotificationTemplate":{"anyOf":[{"type":"object","properties":{"templateId":{"$ref":"#/components/schemas/EtpId"},"version":{"type":"integer","exclusiveMinimum":0},"layout":{"type":"object","properties":{"templateId":{"$ref":"#/components/schemas/EtpId"},"version":{"type":"integer","exclusiveMinimum":0}},"required":["templateId","version"],"additionalProperties":false}},"required":["templateId","version"],"additionalProperties":false},{"type":"object","properties":{"starterId":{"type":"string","pattern":"^[a-z0-9]+(?:-[a-z0-9]+)*$","maxLength":60},"layout":{"type":"object","properties":{"templateId":{"$ref":"#/components/schemas/EtpId"},"version":{"type":"integer","exclusiveMinimum":0}},"required":["templateId","version"],"additionalProperties":false}},"required":["starterId"],"additionalProperties":false}],"description":"The email template a notification rendered: the tenant's own (`templateId`, `version`) or one of Manifold's starters (`starterId`), with the custom style's `layout` it drew."},"UsrId":{"type":"string","pattern":"^usr_[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$","description":"A usr-prefixed uuid, e.g. usr_9f8c1c2e-0000-4000-8000-000000000000"},"AppId":{"type":"string","pattern":"^app_[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$","description":"A app-prefixed uuid, e.g. app_9f8c1c2e-0000-4000-8000-000000000000"},"InsId":{"type":"string","pattern":"^ins_[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$","description":"A ins-prefixed uuid, e.g. ins_9f8c1c2e-0000-4000-8000-000000000000"},"CplId":{"type":"string","pattern":"^cpl_[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$","description":"A cpl-prefixed uuid, e.g. cpl_9f8c1c2e-0000-4000-8000-000000000000"},"Actor":{"anyOf":[{"type":"object","properties":{"_tag":{"type":"string","enum":["user"]},"id":{"$ref":"#/components/schemas/UsrId"},"impersonatedBy":{"type":"string","minLength":1},"viaPartner":{"type":"string","minLength":1}},"required":["_tag","id"],"additionalProperties":false},{"type":"object","properties":{"_tag":{"type":"string","enum":["system"]},"id":{"type":"string","minLength":1}},"required":["_tag","id"],"additionalProperties":false},{"type":"object","properties":{"_tag":{"type":"string","enum":["app"]},"id":{"$ref":"#/components/schemas/AppId"},"installationId":{"$ref":"#/components/schemas/InsId"}},"required":["_tag","id","installationId"],"additionalProperties":false},{"type":"object","properties":{"_tag":{"type":"string","enum":["customer"]},"id":{"$ref":"#/components/schemas/CplId"}},"required":["_tag","id"],"additionalProperties":false}]},"LocalPath":{"type":"string","maxLength":512,"pattern":"^\\/(?![/\\\\])[^\\s]*$","description":"A path in the admin, starting with `/` (`/orders/ord_…`): never a URL."},"BounceType":{"type":"string","enum":["permanent","transient","undetermined","rejected"],"description":"Why a message bounced: `permanent` — the address or number does not exist or refuses mail for good (the address is suppressed); `transient` — the mailbox was full, the server or carrier unreachable, and the provider gave up retrying; `undetermined` — the provider could not tell; `rejected` — the provider refused to deliver it (a virus scan, for one)."},"NotificationStepStatus":{"type":"string","enum":["requested","sent","delivered","delayed","opened","clicked","failed","bounced","complained","opted-out"],"description":"What happened at one step of a notification's life: any `NotificationStatus`, or `delayed` — the recipient's server deferred it and the provider is still trying (the first delay only) — or `opted-out` — the number had asked to receive no more texts, so the address is now suppressed."},"NotificationStepEncoded":{"type":"object","properties":{"status":{"$ref":"#/components/schemas/NotificationStepStatus"},"at":{"type":"string"},"detail":{"type":"string"}},"required":["status","at"],"additionalProperties":false},"NotificationEncoded":{"type":"object","properties":{"id":{"$ref":"#/components/schemas/NtfId"},"kind":{"$ref":"#/components/schemas/NotificationKind"},"channel":{"$ref":"#/components/schemas/NotificationChannel"},"status":{"$ref":"#/components/schemas/NotificationStatus"},"to":{"type":"array","items":{"$ref":"#/components/schemas/NotificationAddress"}},"cc":{"type":"array","items":{"$ref":"#/components/schemas/EmailEncoded"}},"from":{"type":"string"},"smsOrigin":{"$ref":"#/components/schemas/SmsOrigin"},"replyTo":{"type":"string"},"subject":{"type":"string"},"source":{"type":"object","properties":{"kind":{"type":"string","minLength":1},"id":{"type":"string","minLength":1}},"required":["kind","id"],"additionalProperties":false},"template":{"$ref":"#/components/schemas/NotificationTemplate"},"requestedBy":{"$ref":"#/components/schemas/Actor"},"requestedAt":{"type":"string"},"recipient":{"type":"object","properties":{"user":{"$ref":"#/components/schemas/UsrId"}},"required":["user"],"additionalProperties":false},"push":{"type":"object","properties":{"body":{"type":"string"},"path":{"$ref":"#/components/schemas/LocalPath"},"actions":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string","pattern":"^[a-z][a-z0-9-]{0,31}$"},"title":{"type":"string"},"path":{"$ref":"#/components/schemas/LocalPath"}},"required":["id","title","path"],"additionalProperties":false}}},"required":["body","path","actions"],"additionalProperties":false},"notBefore":{"type":"string"},"sentAt":{"type":"string"},"providerMessageId":{"type":"string"},"tracked":{"type":"boolean"},"deliveredAt":{"type":"string"},"openedAt":{"type":"string"},"clickedAt":{"type":"string"},"bounceType":{"$ref":"#/components/schemas/BounceType"},"reason":{"type":"string"},"steps":{"type":"array","items":{"$ref":"#/components/schemas/NotificationStepEncoded"}}},"required":["id","kind","channel","status","to","from","subject","requestedBy","requestedAt","steps"],"additionalProperties":false},"NotificationListEncoded":{"type":"object","properties":{"items":{"type":"array","items":{"$ref":"#/components/schemas/NotificationEncoded"}},"next":{"type":"string"}},"required":["items"],"additionalProperties":false},"NotificationNotFoundEncoded":{"type":"object","properties":{"_tag":{"type":"string","enum":["NotificationNotFound"]},"notificationId":{"type":"string"}},"required":["_tag","notificationId"],"additionalProperties":false},"ContactChannel":{"type":"string","enum":["email","sms"],"description":"How a message to an address travels: `email` — through the mail provider, from the tenant's sender; `sms` — a text message to a mobile number, under the tenant's SMS sender ID."},"SendTestNotificationEncoded":{"type":"object","properties":{"notificationId":{"$ref":"#/components/schemas/NtfId"},"channel":{"$ref":"#/components/schemas/ContactChannel"},"to":{"type":"string","minLength":1,"maxLength":254}},"required":["notificationId","channel","to"],"additionalProperties":false},"RecipientInvalidEncoded":{"type":"object","properties":{"_tag":{"type":"string","enum":["RecipientInvalid"]},"channel":{"$ref":"#/components/schemas/NotificationChannel"},"to":{"type":"string"},"reason":{"type":"string"}},"required":["_tag","channel","to","reason"],"additionalProperties":false},"SupId":{"type":"string","pattern":"^sup_[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$","description":"A sup-prefixed uuid, e.g. sup_9f8c1c2e-0000-4000-8000-000000000000"},"SuppressionReason":{"type":"string","enum":["bounced","complained","opted-out"],"description":"Why the tenant no longer sends to an address: `bounced` — a message to it bounced permanently; `complained` — its owner marked one as spam; `opted-out` — the number asked to receive no more texts."},"RecipientSuppressedEncoded":{"type":"object","properties":{"_tag":{"type":"string","enum":["RecipientSuppressed"]},"to":{"type":"string"},"suppressionId":{"$ref":"#/components/schemas/SupId"},"reason":{"$ref":"#/components/schemas/SuppressionReason"}},"required":["_tag","to","suppressionId","reason"],"additionalProperties":false},"SenderNotConfiguredEncoded":{"type":"object","properties":{"_tag":{"type":"string","enum":["SenderNotConfigured"]},"reason":{"type":"string"}},"required":["_tag","reason"],"additionalProperties":false},"SmsNotSendableEncoded":{"type":"object","properties":{"_tag":{"type":"string","enum":["SmsNotSendable"]},"to":{"type":"string"},"country":{"type":"string"},"reason":{"type":"string"}},"required":["_tag","to","reason"],"additionalProperties":false},"OrdId":{"type":"string","pattern":"^ord_[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$","description":"A ord-prefixed uuid, e.g. ord_9f8c1c2e-0000-4000-8000-000000000000"},"SendQuoteEncoded":{"type":"object","properties":{"notificationId":{"$ref":"#/components/schemas/NtfId"},"orderId":{"$ref":"#/components/schemas/OrdId"},"channel":{"$ref":"#/components/schemas/ContactChannel"},"to":{"type":"string","minLength":1,"maxLength":254}},"required":["notificationId","orderId","channel","to"],"additionalProperties":false},"QuoteNotSendableEncoded":{"type":"object","properties":{"_tag":{"type":"string","enum":["QuoteNotSendable"]},"orderId":{"type":"string"},"reason":{"type":"string"}},"required":["_tag","orderId","reason"],"additionalProperties":false},"QuotesDisabledEncoded":{"type":"object","properties":{"_tag":{"type":"string","enum":["QuotesDisabled"]},"orderId":{"type":"string"}},"required":["_tag","orderId"],"additionalProperties":false},"TemplateProblemStage":{"type":"string","enum":["compile","run","output"],"description":"Where a template failed: `compile` — the TSX does not parse; `run` — its code threw, or ran past the sandbox's time or memory; `output` — what it returned is not an email the dialect allows (an element, attribute or link it may not carry), or is empty or too large."},"TemplateInvalidEncoded":{"type":"object","properties":{"_tag":{"type":"string","enum":["TemplateInvalid"]},"stage":{"$ref":"#/components/schemas/TemplateProblemStage"},"reason":{"type":"string"},"line":{"type":"integer","exclusiveMinimum":0},"column":{"type":"integer","minimum":0}},"required":["_tag","stage","reason"],"additionalProperties":false},"ComposeSourceUnavailableEncoded":{"type":"object","properties":{"_tag":{"type":"string","enum":["ComposeSourceUnavailable"]},"reason":{"type":"string"}},"required":["_tag","reason"],"additionalProperties":false},"SuppressionEncoded":{"type":"object","properties":{"id":{"$ref":"#/components/schemas/SupId"},"address":{"$ref":"#/components/schemas/NotificationAddress"},"channel":{"$ref":"#/components/schemas/NotificationChannel"},"reason":{"$ref":"#/components/schemas/SuppressionReason"},"notificationId":{"$ref":"#/components/schemas/NtfId"},"detail":{"type":"string"},"suppressedAt":{"type":"string"}},"required":["id","address","channel","reason","notificationId","suppressedAt"],"additionalProperties":false},"SuppressionListEncoded":{"type":"object","properties":{"items":{"type":"array","items":{"$ref":"#/components/schemas/SuppressionEncoded"}}},"required":["items"],"additionalProperties":false},"SuppressionNotFoundEncoded":{"type":"object","properties":{"_tag":{"type":"string","enum":["SuppressionNotFound"]},"suppressionId":{"type":"string"}},"required":["_tag","suppressionId"],"additionalProperties":false},"EmailTemplateStyle":{"type":"string","enum":["classic","bold","minimal","custom"],"description":"A look applied across every kind of email: `classic` — a white card with the shop's name as letterhead, every line and the totals; `bold` — the figure that matters set large on a colour band; `minimal` — a short plain letter; `custom` — the tenant's own layout (a template of kind `layout`) around each kind's body."},"EmailTemplateStyleInfoEncoded":{"type":"object","properties":{"style":{"$ref":"#/components/schemas/EmailTemplateStyle"},"name":{"type":"string","minLength":1},"description":{"type":"string","minLength":1}},"required":["style","name","description"],"additionalProperties":false},"EmailTemplateKind":{"type":"string","enum":["invoice","quote","order-confirmation","purchase-order"],"description":"What an email template is for, and so the template data it renders (`InvoiceTemplateData`, `QuoteTemplateData`, …)."},"EmailTemplateKindInfoEncoded":{"type":"object","properties":{"kind":{"$ref":"#/components/schemas/EmailTemplateKind"},"description":{"type":"string","minLength":1},"dataSchema":{"type":"string","minLength":1},"sample":{},"activeTemplateId":{"$ref":"#/components/schemas/EtpId"},"starterId":{"type":"string","pattern":"^[a-z0-9]+(?:-[a-z0-9]+)*$","maxLength":60}},"required":["kind","description","dataSchema","sample","starterId"],"additionalProperties":false},"EmailTemplatePurpose":{"type":"string","enum":["invoice","quote","order-confirmation","purchase-order","layout"],"description":"A kind's email (`EmailTemplateKind`), or `layout`: the custom style's page."},"EmailTemplateSource":{"type":"string","minLength":1,"maxLength":100000,"description":"A template's TSX module, as written: up to 100,000 characters."},"StarterTemplateEncoded":{"type":"object","properties":{"id":{"type":"string","pattern":"^[a-z0-9]+(?:-[a-z0-9]+)*$","maxLength":60},"kind":{"$ref":"#/components/schemas/EmailTemplatePurpose"},"style":{"$ref":"#/components/schemas/EmailTemplateStyle"},"name":{"type":"string","minLength":1},"description":{"type":"string","minLength":1},"default":{"type":"boolean"},"source":{"$ref":"#/components/schemas/EmailTemplateSource"}},"required":["id","kind","style","name","description","default","source"],"additionalProperties":false},"EmailTemplateCatalogEncoded":{"type":"object","properties":{"style":{"$ref":"#/components/schemas/EmailTemplateStyle"},"layoutTemplateId":{"$ref":"#/components/schemas/EtpId"},"styles":{"type":"array","items":{"$ref":"#/components/schemas/EmailTemplateStyleInfoEncoded"}},"kinds":{"type":"array","items":{"$ref":"#/components/schemas/EmailTemplateKindInfoEncoded"}},"starters":{"type":"array","items":{"$ref":"#/components/schemas/StarterTemplateEncoded"}},"typings":{"type":"string"}},"required":["styles","kinds","starters","typings"],"additionalProperties":false},"BooleanString":{"type":"string","enum":["true","false"],"description":"A boolean as a query string spells it: `true` or `false`."},"EmailTemplateEncoded":{"type":"object","properties":{"id":{"$ref":"#/components/schemas/EtpId"},"kind":{"$ref":"#/components/schemas/EmailTemplatePurpose"},"name":{"type":"string"},"source":{"$ref":"#/components/schemas/EmailTemplateSource"},"version":{"type":"integer","exclusiveMinimum":0},"basedOn":{"type":"string","pattern":"^[a-z0-9]+(?:-[a-z0-9]+)*$","maxLength":60},"active":{"type":"boolean"},"archived":{"type":"boolean"},"createdAt":{"type":"string"},"savedAt":{"type":"string"},"savedBy":{"$ref":"#/components/schemas/Actor"}},"required":["id","kind","name","source","version","active","archived","createdAt","savedAt","savedBy"],"additionalProperties":false},"EmailTemplateListEncoded":{"type":"object","properties":{"items":{"type":"array","items":{"$ref":"#/components/schemas/EmailTemplateEncoded"}}},"required":["items"],"additionalProperties":false},"EmailTemplateNotFoundEncoded":{"type":"object","properties":{"_tag":{"type":"string","enum":["EmailTemplateNotFound"]},"templateId":{"type":"string"}},"required":["_tag","templateId"],"additionalProperties":false},"SaveEmailTemplateEncoded":{"type":"object","properties":{"kind":{"$ref":"#/components/schemas/EmailTemplatePurpose"},"name":{"type":"string"},"source":{"$ref":"#/components/schemas/EmailTemplateSource"},"basedOn":{"type":"string","pattern":"^[a-z0-9]+(?:-[a-z0-9]+)*$","maxLength":60}},"required":["kind","name","source"],"additionalProperties":false},"EmailTemplateConflictEncoded":{"type":"object","properties":{"_tag":{"type":"string","enum":["EmailTemplateConflict"]},"templateId":{"type":"string"},"reason":{"type":"string"}},"required":["_tag","templateId","reason"],"additionalProperties":false},"ActivateEmailTemplateEncoded":{"type":"object","properties":{"templateId":{"$ref":"#/components/schemas/EtpId"}},"additionalProperties":false},"ChooseEmailTemplateStyleEncoded":{"type":"object","properties":{"style":{"$ref":"#/components/schemas/EmailTemplateStyle"},"layoutTemplateId":{"$ref":"#/components/schemas/EtpId"}},"required":["style"],"additionalProperties":false},"RenderEmailTemplateEncoded":{"type":"object","properties":{"kind":{"$ref":"#/components/schemas/EmailTemplatePurpose"},"source":{"$ref":"#/components/schemas/EmailTemplateSource"},"previewKind":{"$ref":"#/components/schemas/EmailTemplateKind"},"data":{}},"required":["kind","source"],"additionalProperties":false},"RenderedEmailTemplateEncoded":{"type":"object","properties":{"subject":{"type":"string"},"preview":{"type":"string"},"html":{"type":"string"},"text":{"type":"string"},"durationMs":{"type":"integer","minimum":0}},"required":["subject","html","text","durationMs"],"additionalProperties":false},"SendTemplateTestEncoded":{"type":"object","properties":{"notificationId":{"$ref":"#/components/schemas/NtfId"}},"required":["notificationId"],"additionalProperties":false},"TenantId":{"type":"string","pattern":"^org_(test_)?[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$","description":"An org-prefixed uuid, e.g. org_9f8c1c2e-0000-4000-8000-000000000000; a sandbox tenant is org_test_<uuid>"},"PublicBrandEncoded":{"type":"object","properties":{"tenantId":{"$ref":"#/components/schemas/TenantId"},"businessName":{"type":"string","minLength":1},"brandColour":{"$ref":"#/components/schemas/HexColour"},"onBrandColour":{"$ref":"#/components/schemas/HexColour"},"accentColour":{"$ref":"#/components/schemas/HexColour"},"contact":{"$ref":"#/components/schemas/BrandContact"},"footer":{"type":"string"},"terms":{"type":"string"},"logoUrl":{"type":"string"},"logoVersion":{"type":"string","minLength":1}},"required":["tenantId","businessName","brandColour","onBrandColour","accentColour"],"additionalProperties":false},"PagesHostStatus":{"type":"string","enum":["live","lapsed"],"description":"`live` — the host serves the tenant's pages; `lapsed` — it no longer reaches Manifold, and a request that still arrives is sent to Manifold's host."},"PagesHostEncoded":{"type":"object","properties":{"hostname":{"$ref":"#/components/schemas/PagesHostnameEncoded"},"tenantId":{"$ref":"#/components/schemas/TenantId"},"status":{"$ref":"#/components/schemas/PagesHostStatus"}},"required":["hostname","tenantId","status"],"additionalProperties":false},"PagesHostNotFoundEncoded":{"type":"object","properties":{"_tag":{"type":"string","enum":["PagesHostNotFound"]}},"required":["_tag"],"additionalProperties":false},"TenantPagesHostEncoded":{"type":"object","properties":{"tenantId":{"$ref":"#/components/schemas/TenantId"},"hostname":{"type":"string"}},"required":["tenantId"],"additionalProperties":false},"PushProviderKind":{"type":"string","enum":["fcm","fake","none"],"description":"The push service behind this deployment: `fcm` — Firebase Cloud Messaging, which the browser registers with using `web`; `fake` — a local stack's stand-in, which takes any token the browser makes up and delivers nothing; `none` — push is not set up on this deployment yet: a push is recorded and fails with that reason."},"PushConfigEncoded":{"type":"object","properties":{"provider":{"$ref":"#/components/schemas/PushProviderKind"},"web":{"type":"object","properties":{"apiKey":{"type":"string"},"projectId":{"type":"string"},"appId":{"type":"string"},"messagingSenderId":{"type":"string"},"vapidKey":{"type":"string"}},"required":["apiKey","projectId","appId","messagingSenderId","vapidKey"],"additionalProperties":false}},"required":["provider"],"additionalProperties":false},"PdvId":{"type":"string","pattern":"^pdv_[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$","description":"A pdv-prefixed uuid, e.g. pdv_9f8c1c2e-0000-4000-8000-000000000000"},"PushDevicePlatform":{"type":"string","enum":["web","ios","android"],"description":"What a device is: `web` — a browser or the installed admin, whose service worker shows every push itself (data only); `ios` — the Manifold app on an iPhone or iPad, and `android` — the Manifold app on Android, whose operating system shows the push (title and body) and hands the page it names to the app when tapped."},"MountBase":{"type":"string","maxLength":64,"pattern":"^(?:\\/[a-z0-9-]+)*$","description":"Where the admin is mounted in the app the device opens: `\"\"` on its own host, `/admin` under the hub."},"PushDeviceEncoded":{"type":"object","properties":{"id":{"$ref":"#/components/schemas/PdvId"},"label":{"type":"string"},"platform":{"$ref":"#/components/schemas/PushDevicePlatform"},"base":{"$ref":"#/components/schemas/MountBase"},"registeredAt":{"type":"string"},"lastSeenAt":{"type":"string"}},"required":["id","label","platform","base","registeredAt","lastSeenAt"],"additionalProperties":false},"PushDeviceListEncoded":{"type":"object","properties":{"items":{"type":"array","items":{"$ref":"#/components/schemas/PushDeviceEncoded"}}},"required":["items"],"additionalProperties":false},"PushNeedsPersonEncoded":{"type":"object","properties":{"_tag":{"type":"string","enum":["PushNeedsPerson"]},"reason":{"type":"string"}},"required":["_tag","reason"],"additionalProperties":false},"RegisterPushDeviceEncoded":{"type":"object","properties":{"token":{"type":"string","minLength":8,"maxLength":4096},"label":{"type":"string"},"platform":{"$ref":"#/components/schemas/PushDevicePlatform"},"base":{"$ref":"#/components/schemas/MountBase"}},"required":["token","label","platform","base"],"additionalProperties":false},"PushDeviceNotFoundEncoded":{"type":"object","properties":{"_tag":{"type":"string","enum":["PushDeviceNotFound"]},"deviceId":{"type":"string"}},"required":["_tag","deviceId"],"additionalProperties":false},"SendPushTestEncoded":{"type":"object","properties":{"notificationId":{"$ref":"#/components/schemas/NtfId"}},"required":["notificationId"],"additionalProperties":false},"PushKind":{"type":"string","enum":["approval-request","staff-alert"],"description":"What a push to a tenant's people is. `approval-request` — someone asks the recipient to approve or decline something (a line below its minimum margin), with the actions to do it; `staff-alert` — something a colleague or Manifold wants the recipient to know now."},"PushKindSettingEncoded":{"type":"object","properties":{"kind":{"$ref":"#/components/schemas/PushKind"},"enabled":{"type":"boolean"}},"required":["kind","enabled"],"additionalProperties":false},"PushPreferencesEncoded":{"type":"object","properties":{"kinds":{"type":"array","items":{"$ref":"#/components/schemas/PushKindSettingEncoded"}},"quietHours":{"type":"object","properties":{"start":{"type":"string","pattern":"^(?:[01][0-9]|2[0-3]):[0-5][0-9]$"},"end":{"type":"string","pattern":"^(?:[01][0-9]|2[0-3]):[0-5][0-9]$"},"timeZone":{"type":"string"}},"required":["start","end","timeZone"],"additionalProperties":false}},"required":["kinds"],"additionalProperties":false},"SavePushPreferencesEncoded":{"type":"object","properties":{"enabled":{"type":"array","items":{"$ref":"#/components/schemas/PushKind"}},"quietHours":{"type":"object","properties":{"start":{"type":"string","pattern":"^(?:[01][0-9]|2[0-3]):[0-5][0-9]$"},"end":{"type":"string","pattern":"^(?:[01][0-9]|2[0-3]):[0-5][0-9]$"},"timeZone":{"type":"string"}},"required":["start","end","timeZone"],"additionalProperties":false}},"required":["enabled"],"additionalProperties":false},"Role":{"type":"string","enum":["owner","admin","fulfilment","receiving","stock-control","purchasing","merchandising","finance","store","wholesale-rep","sales-manager","analyst","data-migration","support","ops-lead"],"description":"A fixed bundle of scopes and views. `owner` and `admin` come from membership and hold everything; the rest (fulfilment, receiving, stock-control, purchasing, merchandising, finance, store, wholesale-rep, sales-manager, analyst, data-migration, support, ops-lead) are assigned."},"PushAudience":{"anyOf":[{"type":"object","properties":{"roles":{"type":"array","items":{"$ref":"#/components/schemas/Role"},"minItems":1,"maxItems":20}},"required":["roles"],"additionalProperties":false},{"type":"object","properties":{"users":{"type":"array","items":{"$ref":"#/components/schemas/UsrId"},"minItems":1,"maxItems":50}},"required":["users"],"additionalProperties":false}],"description":"Who a push is for: `roles` — every active member holding one of them (`owner`, `admin`, `wholesale-rep` …); `users` — the active members named, at most 50."},"PushActionEncoded":{"type":"object","properties":{"id":{"type":"string","pattern":"^[a-z][a-z0-9-]{0,31}$"},"title":{"type":"string"},"path":{"$ref":"#/components/schemas/LocalPath"}},"required":["id","title","path"],"additionalProperties":false},"NotifyMembersEncoded":{"type":"object","properties":{"reference":{"type":"string","minLength":1,"maxLength":200},"kind":{"$ref":"#/components/schemas/PushKind"},"audience":{"$ref":"#/components/schemas/PushAudience"},"title":{"type":"string"},"body":{"type":"string"},"path":{"$ref":"#/components/schemas/LocalPath"},"actions":{"anyOf":[{"type":"array","items":{"$ref":"#/components/schemas/PushActionEncoded"},"maxItems":2},{"type":"null"}]}},"required":["reference","kind","audience","title","body","path"],"additionalProperties":false},"PushSkipReason":{"type":"string","enum":["opted-out","no-device"],"description":"Why a person a raise named was not pushed: `opted-out` — they switched the kind off; `no-device` — they have registered no device."},"PushSkipEncoded":{"type":"object","properties":{"userId":{"$ref":"#/components/schemas/UsrId"},"reason":{"$ref":"#/components/schemas/PushSkipReason"}},"required":["userId","reason"],"additionalProperties":false},"PushRaiseEncoded":{"type":"object","properties":{"reference":{"type":"string"},"kind":{"$ref":"#/components/schemas/PushKind"},"notifications":{"type":"array","items":{"$ref":"#/components/schemas/NotificationEncoded"}},"skipped":{"type":"array","items":{"$ref":"#/components/schemas/PushSkipEncoded"}}},"required":["reference","kind","notifications","skipped"],"additionalProperties":false},"AudienceUnavailableEncoded":{"type":"object","properties":{"_tag":{"type":"string","enum":["AudienceUnavailable"]},"reason":{"type":"string"}},"required":["_tag","reason"],"additionalProperties":false},"AlertCategory":{"type":"string","enum":["integrations","sync-problems","books","billing"],"description":"What an operational email to a tenant's owners and admins is about: `integrations` — a sales channel, carrier or ledger app stopped working for the tenant; `sync-problems` — the daily digest of orders not brought in and imports that failed; `books` — a ledger refused what Manifold sent it; `billing` — a payment failed or the plan lapsed (binding: it cannot be switched off)."},"AlertCategorySettingEncoded":{"type":"object","properties":{"category":{"$ref":"#/components/schemas/AlertCategory"},"enabled":{"type":"boolean"},"mandatory":{"type":"boolean"}},"required":["category","enabled","mandatory"],"additionalProperties":false},"AlertPreferencesEncoded":{"type":"object","properties":{"categories":{"type":"array","items":{"$ref":"#/components/schemas/AlertCategorySettingEncoded"}}},"required":["categories"],"additionalProperties":false},"SaveAlertPreferencesEncoded":{"type":"object","properties":{"muted":{"type":"array","items":{"$ref":"#/components/schemas/AlertCategory"}}},"required":["muted"],"additionalProperties":false},"EvtId":{"type":"string","pattern":"^evt_[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$","description":"A evt-prefixed uuid, e.g. evt_9f8c1c2e-0000-4000-8000-000000000000"},"TxId":{"type":"string","pattern":"^tx_[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$","description":"A tx-prefixed uuid, e.g. tx_9f8c1c2e-0000-4000-8000-000000000000"},"SenderSettingsEncoded":{"type":"object","properties":{"senderName":{"type":"string","minLength":1,"maxLength":120},"accountsEmail":{"$ref":"#/components/schemas/EmailEncoded"}},"required":["senderName","accountsEmail"],"additionalProperties":false},"notifications.sender-savedEncoded":{"type":"object","properties":{"_tag":{"type":"string","enum":["notifications.sender-saved"]},"eventId":{"$ref":"#/components/schemas/EvtId"},"txId":{"$ref":"#/components/schemas/TxId"},"tenantId":{"$ref":"#/components/schemas/TenantId"},"sequence":{"type":"integer","minimum":0},"occurredAt":{"type":"string"},"source":{"type":"string","minLength":1},"version":{"type":"number","enum":[1]},"actor":{"$ref":"#/components/schemas/Actor"},"correlationId":{"type":"string","minLength":1},"causationId":{"type":"string","minLength":1},"payload":{"type":"object","properties":{"sender":{"$ref":"#/components/schemas/SenderSettingsEncoded"}},"required":["sender"],"additionalProperties":false}},"required":["_tag","eventId","txId","tenantId","sequence","occurredAt","source","version","actor","correlationId","payload"],"additionalProperties":false},"DnsRecordState_1":{"type":"string","enum":["found","missing","mismatch","unchecked"],"description":"What the last lookup found: `found` — the record resolves to the value asked for; `missing` — nothing at that name; `mismatch` — something else is there; `unchecked` — not looked up yet."},"DnsRecordEncoded":{"type":"object","properties":{"purpose":{"$ref":"#/components/schemas/DnsRecordPurpose"},"type":{"$ref":"#/components/schemas/DnsRecordType"},"name":{"type":"string"},"value":{"type":"string"},"required":{"type":"boolean"},"state":{"$ref":"#/components/schemas/DnsRecordState_1"},"found":{"type":"string"}},"required":["purpose","type","name","value","required"],"additionalProperties":false},"notifications.sending-domain-addedEncoded":{"type":"object","properties":{"_tag":{"type":"string","enum":["notifications.sending-domain-added"]},"eventId":{"$ref":"#/components/schemas/EvtId"},"txId":{"$ref":"#/components/schemas/TxId"},"tenantId":{"$ref":"#/components/schemas/TenantId"},"sequence":{"type":"integer","minimum":0},"occurredAt":{"type":"string"},"source":{"type":"string","minLength":1},"version":{"type":"number","enum":[1]},"actor":{"$ref":"#/components/schemas/Actor"},"correlationId":{"type":"string","minLength":1},"causationId":{"type":"string","minLength":1},"payload":{"type":"object","properties":{"domainId":{"$ref":"#/components/schemas/SdmId"},"domain":{"$ref":"#/components/schemas/DomainNameEncoded"},"mailFromDomain":{"type":"string"},"records":{"type":"array","items":{"$ref":"#/components/schemas/DnsRecordEncoded"}}},"required":["domainId","domain","mailFromDomain","records"],"additionalProperties":false}},"required":["_tag","eventId","txId","tenantId","sequence","occurredAt","source","version","actor","correlationId","payload"],"additionalProperties":false},"notifications.sending-domain-verifiedEncoded":{"type":"object","properties":{"_tag":{"type":"string","enum":["notifications.sending-domain-verified"]},"eventId":{"$ref":"#/components/schemas/EvtId"},"txId":{"$ref":"#/components/schemas/TxId"},"tenantId":{"$ref":"#/components/schemas/TenantId"},"sequence":{"type":"integer","minimum":0},"occurredAt":{"type":"string"},"source":{"type":"string","minLength":1},"version":{"type":"number","enum":[1]},"actor":{"$ref":"#/components/schemas/Actor"},"correlationId":{"type":"string","minLength":1},"causationId":{"type":"string","minLength":1},"payload":{"type":"object","properties":{"domainId":{"$ref":"#/components/schemas/SdmId"},"domain":{"$ref":"#/components/schemas/DomainNameEncoded"}},"required":["domainId","domain"],"additionalProperties":false}},"required":["_tag","eventId","txId","tenantId","sequence","occurredAt","source","version","actor","correlationId","payload"],"additionalProperties":false},"notifications.sending-domain-failedEncoded":{"type":"object","properties":{"_tag":{"type":"string","enum":["notifications.sending-domain-failed"]},"eventId":{"$ref":"#/components/schemas/EvtId"},"txId":{"$ref":"#/components/schemas/TxId"},"tenantId":{"$ref":"#/components/schemas/TenantId"},"sequence":{"type":"integer","minimum":0},"occurredAt":{"type":"string"},"source":{"type":"string","minLength":1},"version":{"type":"number","enum":[1]},"actor":{"$ref":"#/components/schemas/Actor"},"correlationId":{"type":"string","minLength":1},"causationId":{"type":"string","minLength":1},"payload":{"type":"object","properties":{"domainId":{"$ref":"#/components/schemas/SdmId"},"domain":{"$ref":"#/components/schemas/DomainNameEncoded"},"reason":{"type":"string"}},"required":["domainId","domain","reason"],"additionalProperties":false}},"required":["_tag","eventId","txId","tenantId","sequence","occurredAt","source","version","actor","correlationId","payload"],"additionalProperties":false},"notifications.sending-domain-removedEncoded":{"type":"object","properties":{"_tag":{"type":"string","enum":["notifications.sending-domain-removed"]},"eventId":{"$ref":"#/components/schemas/EvtId"},"txId":{"$ref":"#/components/schemas/TxId"},"tenantId":{"$ref":"#/components/schemas/TenantId"},"sequence":{"type":"integer","minimum":0},"occurredAt":{"type":"string"},"source":{"type":"string","minLength":1},"version":{"type":"number","enum":[1]},"actor":{"$ref":"#/components/schemas/Actor"},"correlationId":{"type":"string","minLength":1},"causationId":{"type":"string","minLength":1},"payload":{"type":"object","properties":{"domainId":{"$ref":"#/components/schemas/SdmId"},"domain":{"$ref":"#/components/schemas/DomainNameEncoded"}},"required":["domainId","domain"],"additionalProperties":false}},"required":["_tag","eventId","txId","tenantId","sequence","occurredAt","source","version","actor","correlationId","payload"],"additionalProperties":false},"SmsSenderCountryEncoded":{"type":"object","properties":{"country":{"$ref":"#/components/schemas/CountryCode"},"status":{"$ref":"#/components/schemas/SmsSenderCountryStatus"},"reason":{"type":"string"}},"required":["country","status"],"additionalProperties":false},"SmsSenderEncoded":{"type":"object","properties":{"senderId":{"$ref":"#/components/schemas/SmsSenderIdEncoded"},"countries":{"type":"array","items":{"$ref":"#/components/schemas/SmsSenderCountryEncoded"}}},"required":["senderId","countries"],"additionalProperties":false},"notifications.sms-sender-savedEncoded":{"type":"object","properties":{"_tag":{"type":"string","enum":["notifications.sms-sender-saved"]},"eventId":{"$ref":"#/components/schemas/EvtId"},"txId":{"$ref":"#/components/schemas/TxId"},"tenantId":{"$ref":"#/components/schemas/TenantId"},"sequence":{"type":"integer","minimum":0},"occurredAt":{"type":"string"},"source":{"type":"string","minLength":1},"version":{"type":"number","enum":[1]},"actor":{"$ref":"#/components/schemas/Actor"},"correlationId":{"type":"string","minLength":1},"causationId":{"type":"string","minLength":1},"payload":{"type":"object","properties":{"sms":{"$ref":"#/components/schemas/SmsSenderEncoded"}},"required":["sms"],"additionalProperties":false}},"required":["_tag","eventId","txId","tenantId","sequence","occurredAt","source","version","actor","correlationId","payload"],"additionalProperties":false},"notifications.sms-sender-country-changedEncoded":{"type":"object","properties":{"_tag":{"type":"string","enum":["notifications.sms-sender-country-changed"]},"eventId":{"$ref":"#/components/schemas/EvtId"},"txId":{"$ref":"#/components/schemas/TxId"},"tenantId":{"$ref":"#/components/schemas/TenantId"},"sequence":{"type":"integer","minimum":0},"occurredAt":{"type":"string"},"source":{"type":"string","minLength":1},"version":{"type":"number","enum":[1]},"actor":{"$ref":"#/components/schemas/Actor"},"correlationId":{"type":"string","minLength":1},"causationId":{"type":"string","minLength":1},"payload":{"type":"object","properties":{"senderId":{"$ref":"#/components/schemas/SmsSenderIdEncoded"},"country":{"$ref":"#/components/schemas/SmsSenderCountryEncoded"}},"required":["senderId","country"],"additionalProperties":false}},"required":["_tag","eventId","txId","tenantId","sequence","occurredAt","source","version","actor","correlationId","payload"],"additionalProperties":false},"notifications.sms-sender-removedEncoded":{"type":"object","properties":{"_tag":{"type":"string","enum":["notifications.sms-sender-removed"]},"eventId":{"$ref":"#/components/schemas/EvtId"},"txId":{"$ref":"#/components/schemas/TxId"},"tenantId":{"$ref":"#/components/schemas/TenantId"},"sequence":{"type":"integer","minimum":0},"occurredAt":{"type":"string"},"source":{"type":"string","minLength":1},"version":{"type":"number","enum":[1]},"actor":{"$ref":"#/components/schemas/Actor"},"correlationId":{"type":"string","minLength":1},"causationId":{"type":"string","minLength":1},"payload":{"type":"object","properties":{"senderId":{"$ref":"#/components/schemas/SmsSenderIdEncoded"}},"required":["senderId"],"additionalProperties":false}},"required":["_tag","eventId","txId","tenantId","sequence","occurredAt","source","version","actor","correlationId","payload"],"additionalProperties":false},"notifications.requestedEncoded":{"type":"object","properties":{"_tag":{"type":"string","enum":["notifications.requested"]},"eventId":{"$ref":"#/components/schemas/EvtId"},"txId":{"$ref":"#/components/schemas/TxId"},"tenantId":{"$ref":"#/components/schemas/TenantId"},"sequence":{"type":"integer","minimum":0},"occurredAt":{"type":"string"},"source":{"type":"string","minLength":1},"version":{"type":"number","enum":[1]},"actor":{"$ref":"#/components/schemas/Actor"},"correlationId":{"type":"string","minLength":1},"causationId":{"type":"string","minLength":1},"payload":{"type":"object","properties":{"notificationId":{"$ref":"#/components/schemas/NtfId"},"kind":{"$ref":"#/components/schemas/NotificationKind"},"channel":{"$ref":"#/components/schemas/NotificationChannel"},"to":{"type":"array","items":{"$ref":"#/components/schemas/NotificationAddress"}},"cc":{"type":"array","items":{"$ref":"#/components/schemas/EmailEncoded"}},"from":{"type":"string"},"smsOrigin":{"$ref":"#/components/schemas/SmsOrigin"},"replyTo":{"type":"string"},"subject":{"type":"string"},"source":{"type":"object","properties":{"kind":{"type":"string","minLength":1},"id":{"type":"string","minLength":1}},"required":["kind","id"],"additionalProperties":false},"template":{"$ref":"#/components/schemas/NotificationTemplate"},"tracked":{"type":"boolean"},"recipient":{"type":"object","properties":{"user":{"$ref":"#/components/schemas/UsrId"}},"required":["user"],"additionalProperties":false},"push":{"type":"object","properties":{"body":{"type":"string"},"path":{"$ref":"#/components/schemas/LocalPath"},"actions":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string","pattern":"^[a-z][a-z0-9-]{0,31}$"},"title":{"type":"string"},"path":{"$ref":"#/components/schemas/LocalPath"}},"required":["id","title","path"],"additionalProperties":false}}},"required":["body","path","actions"],"additionalProperties":false},"notBefore":{"type":"string"}},"required":["notificationId","kind","channel","to","cc","from","subject"],"additionalProperties":false}},"required":["_tag","eventId","txId","tenantId","sequence","occurredAt","source","version","actor","correlationId","payload"],"additionalProperties":false},"notifications.sentEncoded":{"type":"object","properties":{"_tag":{"type":"string","enum":["notifications.sent"]},"eventId":{"$ref":"#/components/schemas/EvtId"},"txId":{"$ref":"#/components/schemas/TxId"},"tenantId":{"$ref":"#/components/schemas/TenantId"},"sequence":{"type":"integer","minimum":0},"occurredAt":{"type":"string"},"source":{"type":"string","minLength":1},"version":{"type":"number","enum":[1]},"actor":{"$ref":"#/components/schemas/Actor"},"correlationId":{"type":"string","minLength":1},"causationId":{"type":"string","minLength":1},"payload":{"type":"object","properties":{"notificationId":{"$ref":"#/components/schemas/NtfId"},"providerMessageId":{"type":"string"}},"required":["notificationId","providerMessageId"],"additionalProperties":false}},"required":["_tag","eventId","txId","tenantId","sequence","occurredAt","source","version","actor","correlationId","payload"],"additionalProperties":false},"notifications.failedEncoded":{"type":"object","properties":{"_tag":{"type":"string","enum":["notifications.failed"]},"eventId":{"$ref":"#/components/schemas/EvtId"},"txId":{"$ref":"#/components/schemas/TxId"},"tenantId":{"$ref":"#/components/schemas/TenantId"},"sequence":{"type":"integer","minimum":0},"occurredAt":{"type":"string"},"source":{"type":"string","minLength":1},"version":{"type":"number","enum":[1]},"actor":{"$ref":"#/components/schemas/Actor"},"correlationId":{"type":"string","minLength":1},"causationId":{"type":"string","minLength":1},"payload":{"type":"object","properties":{"notificationId":{"$ref":"#/components/schemas/NtfId"},"reason":{"type":"string"}},"required":["notificationId","reason"],"additionalProperties":false}},"required":["_tag","eventId","txId","tenantId","sequence","occurredAt","source","version","actor","correlationId","payload"],"additionalProperties":false},"notifications.deliveredEncoded":{"type":"object","properties":{"_tag":{"type":"string","enum":["notifications.delivered"]},"eventId":{"$ref":"#/components/schemas/EvtId"},"txId":{"$ref":"#/components/schemas/TxId"},"tenantId":{"$ref":"#/components/schemas/TenantId"},"sequence":{"type":"integer","minimum":0},"occurredAt":{"type":"string"},"source":{"type":"string","minLength":1},"version":{"type":"number","enum":[1]},"actor":{"$ref":"#/components/schemas/Actor"},"correlationId":{"type":"string","minLength":1},"causationId":{"type":"string","minLength":1},"payload":{"type":"object","properties":{"notificationId":{"$ref":"#/components/schemas/NtfId"},"providerEventId":{"type":"string","minLength":1,"maxLength":512},"at":{"type":"string"}},"required":["notificationId","providerEventId","at"],"additionalProperties":false}},"required":["_tag","eventId","txId","tenantId","sequence","occurredAt","source","version","actor","correlationId","payload"],"additionalProperties":false},"notifications.delayedEncoded":{"type":"object","properties":{"_tag":{"type":"string","enum":["notifications.delayed"]},"eventId":{"$ref":"#/components/schemas/EvtId"},"txId":{"$ref":"#/components/schemas/TxId"},"tenantId":{"$ref":"#/components/schemas/TenantId"},"sequence":{"type":"integer","minimum":0},"occurredAt":{"type":"string"},"source":{"type":"string","minLength":1},"version":{"type":"number","enum":[1]},"actor":{"$ref":"#/components/schemas/Actor"},"correlationId":{"type":"string","minLength":1},"causationId":{"type":"string","minLength":1},"payload":{"type":"object","properties":{"notificationId":{"$ref":"#/components/schemas/NtfId"},"providerEventId":{"type":"string","minLength":1,"maxLength":512},"at":{"type":"string"},"detail":{"type":"string"}},"required":["notificationId","providerEventId","at"],"additionalProperties":false}},"required":["_tag","eventId","txId","tenantId","sequence","occurredAt","source","version","actor","correlationId","payload"],"additionalProperties":false},"notifications.bouncedEncoded":{"type":"object","properties":{"_tag":{"type":"string","enum":["notifications.bounced"]},"eventId":{"$ref":"#/components/schemas/EvtId"},"txId":{"$ref":"#/components/schemas/TxId"},"tenantId":{"$ref":"#/components/schemas/TenantId"},"sequence":{"type":"integer","minimum":0},"occurredAt":{"type":"string"},"source":{"type":"string","minLength":1},"version":{"type":"number","enum":[1]},"actor":{"$ref":"#/components/schemas/Actor"},"correlationId":{"type":"string","minLength":1},"causationId":{"type":"string","minLength":1},"payload":{"type":"object","properties":{"notificationId":{"$ref":"#/components/schemas/NtfId"},"providerEventId":{"type":"string","minLength":1,"maxLength":512},"at":{"type":"string"},"bounceType":{"$ref":"#/components/schemas/BounceType"},"recipients":{"type":"array","items":{"$ref":"#/components/schemas/NotificationAddress"}},"detail":{"type":"string"}},"required":["notificationId","providerEventId","at","bounceType","recipients"],"additionalProperties":false}},"required":["_tag","eventId","txId","tenantId","sequence","occurredAt","source","version","actor","correlationId","payload"],"additionalProperties":false},"notifications.complainedEncoded":{"type":"object","properties":{"_tag":{"type":"string","enum":["notifications.complained"]},"eventId":{"$ref":"#/components/schemas/EvtId"},"txId":{"$ref":"#/components/schemas/TxId"},"tenantId":{"$ref":"#/components/schemas/TenantId"},"sequence":{"type":"integer","minimum":0},"occurredAt":{"type":"string"},"source":{"type":"string","minLength":1},"version":{"type":"number","enum":[1]},"actor":{"$ref":"#/components/schemas/Actor"},"correlationId":{"type":"string","minLength":1},"causationId":{"type":"string","minLength":1},"payload":{"type":"object","properties":{"notificationId":{"$ref":"#/components/schemas/NtfId"},"providerEventId":{"type":"string","minLength":1,"maxLength":512},"at":{"type":"string"},"recipients":{"type":"array","items":{"$ref":"#/components/schemas/NotificationAddress"}},"detail":{"type":"string"}},"required":["notificationId","providerEventId","at","recipients"],"additionalProperties":false}},"required":["_tag","eventId","txId","tenantId","sequence","occurredAt","source","version","actor","correlationId","payload"],"additionalProperties":false},"notifications.openedEncoded":{"type":"object","properties":{"_tag":{"type":"string","enum":["notifications.opened"]},"eventId":{"$ref":"#/components/schemas/EvtId"},"txId":{"$ref":"#/components/schemas/TxId"},"tenantId":{"$ref":"#/components/schemas/TenantId"},"sequence":{"type":"integer","minimum":0},"occurredAt":{"type":"string"},"source":{"type":"string","minLength":1},"version":{"type":"number","enum":[1]},"actor":{"$ref":"#/components/schemas/Actor"},"correlationId":{"type":"string","minLength":1},"causationId":{"type":"string","minLength":1},"payload":{"type":"object","properties":{"notificationId":{"$ref":"#/components/schemas/NtfId"},"providerEventId":{"type":"string","minLength":1,"maxLength":512},"at":{"type":"string"}},"required":["notificationId","providerEventId","at"],"additionalProperties":false}},"required":["_tag","eventId","txId","tenantId","sequence","occurredAt","source","version","actor","correlationId","payload"],"additionalProperties":false},"notifications.clickedEncoded":{"type":"object","properties":{"_tag":{"type":"string","enum":["notifications.clicked"]},"eventId":{"$ref":"#/components/schemas/EvtId"},"txId":{"$ref":"#/components/schemas/TxId"},"tenantId":{"$ref":"#/components/schemas/TenantId"},"sequence":{"type":"integer","minimum":0},"occurredAt":{"type":"string"},"source":{"type":"string","minLength":1},"version":{"type":"number","enum":[1]},"actor":{"$ref":"#/components/schemas/Actor"},"correlationId":{"type":"string","minLength":1},"causationId":{"type":"string","minLength":1},"payload":{"type":"object","properties":{"notificationId":{"$ref":"#/components/schemas/NtfId"},"providerEventId":{"type":"string","minLength":1,"maxLength":512},"at":{"type":"string"},"link":{"type":"string"}},"required":["notificationId","providerEventId","at"],"additionalProperties":false}},"required":["_tag","eventId","txId","tenantId","sequence","occurredAt","source","version","actor","correlationId","payload"],"additionalProperties":false},"notifications.opted-outEncoded":{"type":"object","properties":{"_tag":{"type":"string","enum":["notifications.opted-out"]},"eventId":{"$ref":"#/components/schemas/EvtId"},"txId":{"$ref":"#/components/schemas/TxId"},"tenantId":{"$ref":"#/components/schemas/TenantId"},"sequence":{"type":"integer","minimum":0},"occurredAt":{"type":"string"},"source":{"type":"string","minLength":1},"version":{"type":"number","enum":[1]},"actor":{"$ref":"#/components/schemas/Actor"},"correlationId":{"type":"string","minLength":1},"causationId":{"type":"string","minLength":1},"payload":{"type":"object","properties":{"notificationId":{"$ref":"#/components/schemas/NtfId"},"providerEventId":{"type":"string","minLength":1,"maxLength":512},"at":{"type":"string"},"address":{"$ref":"#/components/schemas/NotificationAddress"}},"required":["notificationId","providerEventId","at","address"],"additionalProperties":false}},"required":["_tag","eventId","txId","tenantId","sequence","occurredAt","source","version","actor","correlationId","payload"],"additionalProperties":false},"notifications.address-suppressedEncoded":{"type":"object","properties":{"_tag":{"type":"string","enum":["notifications.address-suppressed"]},"eventId":{"$ref":"#/components/schemas/EvtId"},"txId":{"$ref":"#/components/schemas/TxId"},"tenantId":{"$ref":"#/components/schemas/TenantId"},"sequence":{"type":"integer","minimum":0},"occurredAt":{"type":"string"},"source":{"type":"string","minLength":1},"version":{"type":"number","enum":[1]},"actor":{"$ref":"#/components/schemas/Actor"},"correlationId":{"type":"string","minLength":1},"causationId":{"type":"string","minLength":1},"payload":{"type":"object","properties":{"suppressionId":{"$ref":"#/components/schemas/SupId"},"address":{"$ref":"#/components/schemas/NotificationAddress"},"channel":{"$ref":"#/components/schemas/NotificationChannel"},"reason":{"$ref":"#/components/schemas/SuppressionReason"},"notificationId":{"$ref":"#/components/schemas/NtfId"},"detail":{"type":"string"}},"required":["suppressionId","address","channel","reason","notificationId"],"additionalProperties":false}},"required":["_tag","eventId","txId","tenantId","sequence","occurredAt","source","version","actor","correlationId","payload"],"additionalProperties":false},"notifications.suppression-liftedEncoded":{"type":"object","properties":{"_tag":{"type":"string","enum":["notifications.suppression-lifted"]},"eventId":{"$ref":"#/components/schemas/EvtId"},"txId":{"$ref":"#/components/schemas/TxId"},"tenantId":{"$ref":"#/components/schemas/TenantId"},"sequence":{"type":"integer","minimum":0},"occurredAt":{"type":"string"},"source":{"type":"string","minLength":1},"version":{"type":"number","enum":[1]},"actor":{"$ref":"#/components/schemas/Actor"},"correlationId":{"type":"string","minLength":1},"causationId":{"type":"string","minLength":1},"payload":{"type":"object","properties":{"suppressionId":{"$ref":"#/components/schemas/SupId"},"address":{"$ref":"#/components/schemas/NotificationAddress"}},"required":["suppressionId","address"],"additionalProperties":false}},"required":["_tag","eventId","txId","tenantId","sequence","occurredAt","source","version","actor","correlationId","payload"],"additionalProperties":false},"notifications.tracking-setEncoded":{"type":"object","properties":{"_tag":{"type":"string","enum":["notifications.tracking-set"]},"eventId":{"$ref":"#/components/schemas/EvtId"},"txId":{"$ref":"#/components/schemas/TxId"},"tenantId":{"$ref":"#/components/schemas/TenantId"},"sequence":{"type":"integer","minimum":0},"occurredAt":{"type":"string"},"source":{"type":"string","minLength":1},"version":{"type":"number","enum":[1]},"actor":{"$ref":"#/components/schemas/Actor"},"correlationId":{"type":"string","minLength":1},"causationId":{"type":"string","minLength":1},"payload":{"type":"object","properties":{"enabled":{"type":"boolean"}},"required":["enabled"],"additionalProperties":false}},"required":["_tag","eventId","txId","tenantId","sequence","occurredAt","source","version","actor","correlationId","payload"],"additionalProperties":false},"notifications.template-savedEncoded":{"type":"object","properties":{"_tag":{"type":"string","enum":["notifications.template-saved"]},"eventId":{"$ref":"#/components/schemas/EvtId"},"txId":{"$ref":"#/components/schemas/TxId"},"tenantId":{"$ref":"#/components/schemas/TenantId"},"sequence":{"type":"integer","minimum":0},"occurredAt":{"type":"string"},"source":{"type":"string","minLength":1},"version":{"type":"number","enum":[1]},"actor":{"$ref":"#/components/schemas/Actor"},"correlationId":{"type":"string","minLength":1},"causationId":{"type":"string","minLength":1},"payload":{"type":"object","properties":{"templateId":{"$ref":"#/components/schemas/EtpId"},"kind":{"$ref":"#/components/schemas/EmailTemplatePurpose"},"name":{"type":"string"},"source":{"$ref":"#/components/schemas/EmailTemplateSource"},"version":{"type":"integer","exclusiveMinimum":0},"basedOn":{"type":"string","pattern":"^[a-z0-9]+(?:-[a-z0-9]+)*$","maxLength":60}},"required":["templateId","kind","name","source","version"],"additionalProperties":false}},"required":["_tag","eventId","txId","tenantId","sequence","occurredAt","source","version","actor","correlationId","payload"],"additionalProperties":false},"notifications.template-archivedEncoded":{"type":"object","properties":{"_tag":{"type":"string","enum":["notifications.template-archived"]},"eventId":{"$ref":"#/components/schemas/EvtId"},"txId":{"$ref":"#/components/schemas/TxId"},"tenantId":{"$ref":"#/components/schemas/TenantId"},"sequence":{"type":"integer","minimum":0},"occurredAt":{"type":"string"},"source":{"type":"string","minLength":1},"version":{"type":"number","enum":[1]},"actor":{"$ref":"#/components/schemas/Actor"},"correlationId":{"type":"string","minLength":1},"causationId":{"type":"string","minLength":1},"payload":{"type":"object","properties":{"templateId":{"$ref":"#/components/schemas/EtpId"},"kind":{"$ref":"#/components/schemas/EmailTemplatePurpose"}},"required":["templateId","kind"],"additionalProperties":false}},"required":["_tag","eventId","txId","tenantId","sequence","occurredAt","source","version","actor","correlationId","payload"],"additionalProperties":false},"notifications.template-activatedEncoded":{"type":"object","properties":{"_tag":{"type":"string","enum":["notifications.template-activated"]},"eventId":{"$ref":"#/components/schemas/EvtId"},"txId":{"$ref":"#/components/schemas/TxId"},"tenantId":{"$ref":"#/components/schemas/TenantId"},"sequence":{"type":"integer","minimum":0},"occurredAt":{"type":"string"},"source":{"type":"string","minLength":1},"version":{"type":"number","enum":[1]},"actor":{"$ref":"#/components/schemas/Actor"},"correlationId":{"type":"string","minLength":1},"causationId":{"type":"string","minLength":1},"payload":{"type":"object","properties":{"kind":{"$ref":"#/components/schemas/EmailTemplateKind"},"templateId":{"$ref":"#/components/schemas/EtpId"}},"required":["kind"],"additionalProperties":false}},"required":["_tag","eventId","txId","tenantId","sequence","occurredAt","source","version","actor","correlationId","payload"],"additionalProperties":false},"notifications.template-style-chosenEncoded":{"type":"object","properties":{"_tag":{"type":"string","enum":["notifications.template-style-chosen"]},"eventId":{"$ref":"#/components/schemas/EvtId"},"txId":{"$ref":"#/components/schemas/TxId"},"tenantId":{"$ref":"#/components/schemas/TenantId"},"sequence":{"type":"integer","minimum":0},"occurredAt":{"type":"string"},"source":{"type":"string","minLength":1},"version":{"type":"number","enum":[1]},"actor":{"$ref":"#/components/schemas/Actor"},"correlationId":{"type":"string","minLength":1},"causationId":{"type":"string","minLength":1},"payload":{"type":"object","properties":{"style":{"$ref":"#/components/schemas/EmailTemplateStyle"},"layoutTemplateId":{"$ref":"#/components/schemas/EtpId"}},"required":["style"],"additionalProperties":false}},"required":["_tag","eventId","txId","tenantId","sequence","occurredAt","source","version","actor","correlationId","payload"],"additionalProperties":false},"notifications.brand-savedEncoded":{"type":"object","properties":{"_tag":{"type":"string","enum":["notifications.brand-saved"]},"eventId":{"$ref":"#/components/schemas/EvtId"},"txId":{"$ref":"#/components/schemas/TxId"},"tenantId":{"$ref":"#/components/schemas/TenantId"},"sequence":{"type":"integer","minimum":0},"occurredAt":{"type":"string"},"source":{"type":"string","minLength":1},"version":{"type":"number","enum":[1]},"actor":{"$ref":"#/components/schemas/Actor"},"correlationId":{"type":"string","minLength":1},"causationId":{"type":"string","minLength":1},"payload":{"type":"object","properties":{"brand":{"$ref":"#/components/schemas/SaveBrandEncoded"}},"required":["brand"],"additionalProperties":false}},"required":["_tag","eventId","txId","tenantId","sequence","occurredAt","source","version","actor","correlationId","payload"],"additionalProperties":false},"notifications.brand-logo-savedEncoded":{"type":"object","properties":{"_tag":{"type":"string","enum":["notifications.brand-logo-saved"]},"eventId":{"$ref":"#/components/schemas/EvtId"},"txId":{"$ref":"#/components/schemas/TxId"},"tenantId":{"$ref":"#/components/schemas/TenantId"},"sequence":{"type":"integer","minimum":0},"occurredAt":{"type":"string"},"source":{"type":"string","minLength":1},"version":{"type":"number","enum":[1]},"actor":{"$ref":"#/components/schemas/Actor"},"correlationId":{"type":"string","minLength":1},"causationId":{"type":"string","minLength":1},"payload":{"type":"object","properties":{"reference":{"type":"string","minLength":1},"contentType":{"$ref":"#/components/schemas/BrandLogoType"},"size":{"type":"integer","exclusiveMinimum":0},"version":{"type":"integer","exclusiveMinimum":0}},"required":["reference","contentType","size","version"],"additionalProperties":false}},"required":["_tag","eventId","txId","tenantId","sequence","occurredAt","source","version","actor","correlationId","payload"],"additionalProperties":false},"notifications.brand-logo-removedEncoded":{"type":"object","properties":{"_tag":{"type":"string","enum":["notifications.brand-logo-removed"]},"eventId":{"$ref":"#/components/schemas/EvtId"},"txId":{"$ref":"#/components/schemas/TxId"},"tenantId":{"$ref":"#/components/schemas/TenantId"},"sequence":{"type":"integer","minimum":0},"occurredAt":{"type":"string"},"source":{"type":"string","minLength":1},"version":{"type":"number","enum":[1]},"actor":{"$ref":"#/components/schemas/Actor"},"correlationId":{"type":"string","minLength":1},"causationId":{"type":"string","minLength":1},"payload":{"anyOf":[{"type":"object"},{"type":"array"}]}},"required":["_tag","eventId","txId","tenantId","sequence","occurredAt","source","version","actor","correlationId","payload"],"additionalProperties":false},"notifications.push-device-registeredEncoded":{"type":"object","properties":{"_tag":{"type":"string","enum":["notifications.push-device-registered"]},"eventId":{"$ref":"#/components/schemas/EvtId"},"txId":{"$ref":"#/components/schemas/TxId"},"tenantId":{"$ref":"#/components/schemas/TenantId"},"sequence":{"type":"integer","minimum":0},"occurredAt":{"type":"string"},"source":{"type":"string","minLength":1},"version":{"type":"number","enum":[1]},"actor":{"$ref":"#/components/schemas/Actor"},"correlationId":{"type":"string","minLength":1},"causationId":{"type":"string","minLength":1},"payload":{"type":"object","properties":{"deviceId":{"$ref":"#/components/schemas/PdvId"},"userId":{"$ref":"#/components/schemas/UsrId"},"label":{"type":"string"},"platform":{"$ref":"#/components/schemas/PushDevicePlatform"},"base":{"$ref":"#/components/schemas/MountBase"},"token":{"type":"string"}},"required":["deviceId","userId","label","platform","base","token"],"additionalProperties":false}},"required":["_tag","eventId","txId","tenantId","sequence","occurredAt","source","version","actor","correlationId","payload"],"additionalProperties":false},"PushDeviceRemoval":{"type":"string","enum":["removed","expired"],"description":"Why a device was let go: `removed` — its person removed it; `expired` — the push service answered that its token is no longer registered (the browser's permission was withdrawn, the app was uninstalled, or the token was replaced)."},"notifications.push-device-removedEncoded":{"type":"object","properties":{"_tag":{"type":"string","enum":["notifications.push-device-removed"]},"eventId":{"$ref":"#/components/schemas/EvtId"},"txId":{"$ref":"#/components/schemas/TxId"},"tenantId":{"$ref":"#/components/schemas/TenantId"},"sequence":{"type":"integer","minimum":0},"occurredAt":{"type":"string"},"source":{"type":"string","minLength":1},"version":{"type":"number","enum":[1]},"actor":{"$ref":"#/components/schemas/Actor"},"correlationId":{"type":"string","minLength":1},"causationId":{"type":"string","minLength":1},"payload":{"type":"object","properties":{"deviceId":{"$ref":"#/components/schemas/PdvId"},"userId":{"$ref":"#/components/schemas/UsrId"},"reason":{"$ref":"#/components/schemas/PushDeviceRemoval"}},"required":["deviceId","userId","reason"],"additionalProperties":false}},"required":["_tag","eventId","txId","tenantId","sequence","occurredAt","source","version","actor","correlationId","payload"],"additionalProperties":false},"notifications.push-preferences-savedEncoded":{"type":"object","properties":{"_tag":{"type":"string","enum":["notifications.push-preferences-saved"]},"eventId":{"$ref":"#/components/schemas/EvtId"},"txId":{"$ref":"#/components/schemas/TxId"},"tenantId":{"$ref":"#/components/schemas/TenantId"},"sequence":{"type":"integer","minimum":0},"occurredAt":{"type":"string"},"source":{"type":"string","minLength":1},"version":{"type":"number","enum":[1]},"actor":{"$ref":"#/components/schemas/Actor"},"correlationId":{"type":"string","minLength":1},"causationId":{"type":"string","minLength":1},"payload":{"type":"object","properties":{"userId":{"$ref":"#/components/schemas/UsrId"},"enabled":{"type":"array","items":{"$ref":"#/components/schemas/PushKind"}},"quietHours":{"type":"object","properties":{"start":{"type":"string","pattern":"^(?:[01][0-9]|2[0-3]):[0-5][0-9]$"},"end":{"type":"string","pattern":"^(?:[01][0-9]|2[0-3]):[0-5][0-9]$"},"timeZone":{"type":"string"}},"required":["start","end","timeZone"],"additionalProperties":false}},"required":["userId","enabled"],"additionalProperties":false}},"required":["_tag","eventId","txId","tenantId","sequence","occurredAt","source","version","actor","correlationId","payload"],"additionalProperties":false},"PushDeliveryEncoded":{"type":"object","properties":{"notificationId":{"type":"string"},"userId":{"$ref":"#/components/schemas/UsrId"},"deviceId":{"$ref":"#/components/schemas/PdvId"}},"required":["notificationId","userId","deviceId"],"additionalProperties":false},"notifications.push-raisedEncoded":{"type":"object","properties":{"_tag":{"type":"string","enum":["notifications.push-raised"]},"eventId":{"$ref":"#/components/schemas/EvtId"},"txId":{"$ref":"#/components/schemas/TxId"},"tenantId":{"$ref":"#/components/schemas/TenantId"},"sequence":{"type":"integer","minimum":0},"occurredAt":{"type":"string"},"source":{"type":"string","minLength":1},"version":{"type":"number","enum":[1]},"actor":{"$ref":"#/components/schemas/Actor"},"correlationId":{"type":"string","minLength":1},"causationId":{"type":"string","minLength":1},"payload":{"type":"object","properties":{"reference":{"type":"string"},"kind":{"$ref":"#/components/schemas/PushKind"},"audience":{"$ref":"#/components/schemas/PushAudience"},"deliveries":{"type":"array","items":{"$ref":"#/components/schemas/PushDeliveryEncoded"}},"skipped":{"type":"array","items":{"$ref":"#/components/schemas/PushSkipEncoded"}}},"required":["reference","kind","audience","deliveries","skipped"],"additionalProperties":false}},"required":["_tag","eventId","txId","tenantId","sequence","occurredAt","source","version","actor","correlationId","payload"],"additionalProperties":false},"notifications.pages-domain-requestedEncoded":{"type":"object","properties":{"_tag":{"type":"string","enum":["notifications.pages-domain-requested"]},"eventId":{"$ref":"#/components/schemas/EvtId"},"txId":{"$ref":"#/components/schemas/TxId"},"tenantId":{"$ref":"#/components/schemas/TenantId"},"sequence":{"type":"integer","minimum":0},"occurredAt":{"type":"string"},"source":{"type":"string","minLength":1},"version":{"type":"number","enum":[1]},"actor":{"$ref":"#/components/schemas/Actor"},"correlationId":{"type":"string","minLength":1},"causationId":{"type":"string","minLength":1},"payload":{"type":"object","properties":{"domainId":{"$ref":"#/components/schemas/PgdId"},"hostname":{"$ref":"#/components/schemas/PagesHostnameEncoded"},"records":{"type":"array","items":{"$ref":"#/components/schemas/PagesDnsRecord"}}},"required":["domainId","hostname","records"],"additionalProperties":false}},"required":["_tag","eventId","txId","tenantId","sequence","occurredAt","source","version","actor","correlationId","payload"],"additionalProperties":false},"notifications.pages-domain-registeredEncoded":{"type":"object","properties":{"_tag":{"type":"string","enum":["notifications.pages-domain-registered"]},"eventId":{"$ref":"#/components/schemas/EvtId"},"txId":{"$ref":"#/components/schemas/TxId"},"tenantId":{"$ref":"#/components/schemas/TenantId"},"sequence":{"type":"integer","minimum":0},"occurredAt":{"type":"string"},"source":{"type":"string","minLength":1},"version":{"type":"number","enum":[1]},"actor":{"$ref":"#/components/schemas/Actor"},"correlationId":{"type":"string","minLength":1},"causationId":{"type":"string","minLength":1},"payload":{"type":"object","properties":{"domainId":{"$ref":"#/components/schemas/PgdId"},"hostname":{"$ref":"#/components/schemas/PagesHostnameEncoded"},"edgeId":{"type":"string"},"records":{"type":"array","items":{"$ref":"#/components/schemas/PagesDnsRecord"}}},"required":["domainId","hostname","edgeId","records"],"additionalProperties":false}},"required":["_tag","eventId","txId","tenantId","sequence","occurredAt","source","version","actor","correlationId","payload"],"additionalProperties":false},"notifications.pages-domain-refusedEncoded":{"type":"object","properties":{"_tag":{"type":"string","enum":["notifications.pages-domain-refused"]},"eventId":{"$ref":"#/components/schemas/EvtId"},"txId":{"$ref":"#/components/schemas/TxId"},"tenantId":{"$ref":"#/components/schemas/TenantId"},"sequence":{"type":"integer","minimum":0},"occurredAt":{"type":"string"},"source":{"type":"string","minLength":1},"version":{"type":"number","enum":[1]},"actor":{"$ref":"#/components/schemas/Actor"},"correlationId":{"type":"string","minLength":1},"causationId":{"type":"string","minLength":1},"payload":{"type":"object","properties":{"domainId":{"$ref":"#/components/schemas/PgdId"},"hostname":{"$ref":"#/components/schemas/PagesHostnameEncoded"},"reason":{"type":"string"}},"required":["domainId","hostname","reason"],"additionalProperties":false}},"required":["_tag","eventId","txId","tenantId","sequence","occurredAt","source","version","actor","correlationId","payload"],"additionalProperties":false},"notifications.pages-domain-verifiedEncoded":{"type":"object","properties":{"_tag":{"type":"string","enum":["notifications.pages-domain-verified"]},"eventId":{"$ref":"#/components/schemas/EvtId"},"txId":{"$ref":"#/components/schemas/TxId"},"tenantId":{"$ref":"#/components/schemas/TenantId"},"sequence":{"type":"integer","minimum":0},"occurredAt":{"type":"string"},"source":{"type":"string","minLength":1},"version":{"type":"number","enum":[1]},"actor":{"$ref":"#/components/schemas/Actor"},"correlationId":{"type":"string","minLength":1},"causationId":{"type":"string","minLength":1},"payload":{"type":"object","properties":{"domainId":{"$ref":"#/components/schemas/PgdId"},"hostname":{"$ref":"#/components/schemas/PagesHostnameEncoded"}},"required":["domainId","hostname"],"additionalProperties":false}},"required":["_tag","eventId","txId","tenantId","sequence","occurredAt","source","version","actor","correlationId","payload"],"additionalProperties":false},"notifications.pages-domain-liveEncoded":{"type":"object","properties":{"_tag":{"type":"string","enum":["notifications.pages-domain-live"]},"eventId":{"$ref":"#/components/schemas/EvtId"},"txId":{"$ref":"#/components/schemas/TxId"},"tenantId":{"$ref":"#/components/schemas/TenantId"},"sequence":{"type":"integer","minimum":0},"occurredAt":{"type":"string"},"source":{"type":"string","minLength":1},"version":{"type":"number","enum":[1]},"actor":{"$ref":"#/components/schemas/Actor"},"correlationId":{"type":"string","minLength":1},"causationId":{"type":"string","minLength":1},"payload":{"type":"object","properties":{"domainId":{"$ref":"#/components/schemas/PgdId"},"hostname":{"$ref":"#/components/schemas/PagesHostnameEncoded"}},"required":["domainId","hostname"],"additionalProperties":false}},"required":["_tag","eventId","txId","tenantId","sequence","occurredAt","source","version","actor","correlationId","payload"],"additionalProperties":false},"notifications.pages-domain-lapsedEncoded":{"type":"object","properties":{"_tag":{"type":"string","enum":["notifications.pages-domain-lapsed"]},"eventId":{"$ref":"#/components/schemas/EvtId"},"txId":{"$ref":"#/components/schemas/TxId"},"tenantId":{"$ref":"#/components/schemas/TenantId"},"sequence":{"type":"integer","minimum":0},"occurredAt":{"type":"string"},"source":{"type":"string","minLength":1},"version":{"type":"number","enum":[1]},"actor":{"$ref":"#/components/schemas/Actor"},"correlationId":{"type":"string","minLength":1},"causationId":{"type":"string","minLength":1},"payload":{"type":"object","properties":{"domainId":{"$ref":"#/components/schemas/PgdId"},"hostname":{"$ref":"#/components/schemas/PagesHostnameEncoded"},"reason":{"type":"string"}},"required":["domainId","hostname","reason"],"additionalProperties":false}},"required":["_tag","eventId","txId","tenantId","sequence","occurredAt","source","version","actor","correlationId","payload"],"additionalProperties":false},"notifications.pages-domain-removedEncoded":{"type":"object","properties":{"_tag":{"type":"string","enum":["notifications.pages-domain-removed"]},"eventId":{"$ref":"#/components/schemas/EvtId"},"txId":{"$ref":"#/components/schemas/TxId"},"tenantId":{"$ref":"#/components/schemas/TenantId"},"sequence":{"type":"integer","minimum":0},"occurredAt":{"type":"string"},"source":{"type":"string","minLength":1},"version":{"type":"number","enum":[1]},"actor":{"$ref":"#/components/schemas/Actor"},"correlationId":{"type":"string","minLength":1},"causationId":{"type":"string","minLength":1},"payload":{"type":"object","properties":{"domainId":{"$ref":"#/components/schemas/PgdId"},"hostname":{"$ref":"#/components/schemas/PagesHostnameEncoded"},"edgeId":{"type":"string"}},"required":["domainId","hostname"],"additionalProperties":false}},"required":["_tag","eventId","txId","tenantId","sequence","occurredAt","source","version","actor","correlationId","payload"],"additionalProperties":false},"notifications.alert-preferences-savedEncoded":{"type":"object","properties":{"_tag":{"type":"string","enum":["notifications.alert-preferences-saved"]},"eventId":{"$ref":"#/components/schemas/EvtId"},"txId":{"$ref":"#/components/schemas/TxId"},"tenantId":{"$ref":"#/components/schemas/TenantId"},"sequence":{"type":"integer","minimum":0},"occurredAt":{"type":"string"},"source":{"type":"string","minLength":1},"version":{"type":"number","enum":[1]},"actor":{"$ref":"#/components/schemas/Actor"},"correlationId":{"type":"string","minLength":1},"causationId":{"type":"string","minLength":1},"payload":{"type":"object","properties":{"userId":{"$ref":"#/components/schemas/UsrId"},"muted":{"type":"array","items":{"$ref":"#/components/schemas/AlertCategory"}}},"required":["userId","muted"],"additionalProperties":false}},"required":["_tag","eventId","txId","tenantId","sequence","occurredAt","source","version","actor","correlationId","payload"],"additionalProperties":false},"SyncProblemKind":{"type":"string","enum":["orders-not-brought-in","migration-failed"],"description":"What went wrong in a sync, as the daily digest lists it: `orders-not-brought-in` — a sales channel's app reported orders it could not create in Manifold (`inventory.channel-intake-reported`); `migration-failed` — an import from the system the tenant came from, or a sync cycle of its link, failed (`onboarding.migration-failed`)."},"notifications.sync-problem-notedEncoded":{"type":"object","properties":{"_tag":{"type":"string","enum":["notifications.sync-problem-noted"]},"eventId":{"$ref":"#/components/schemas/EvtId"},"txId":{"$ref":"#/components/schemas/TxId"},"tenantId":{"$ref":"#/components/schemas/TenantId"},"sequence":{"type":"integer","minimum":0},"occurredAt":{"type":"string"},"source":{"type":"string","minLength":1},"version":{"type":"number","enum":[1]},"actor":{"$ref":"#/components/schemas/Actor"},"correlationId":{"type":"string","minLength":1},"causationId":{"type":"string","minLength":1},"payload":{"type":"object","properties":{"reference":{"type":"string","minLength":1},"problem":{"$ref":"#/components/schemas/SyncProblemKind"},"subjectId":{"type":"string","minLength":1},"detail":{"type":"string","maxLength":500},"count":{"type":"integer","minimum":0}},"required":["reference","problem","subjectId","detail"],"additionalProperties":false}},"required":["_tag","eventId","txId","tenantId","sequence","occurredAt","source","version","actor","correlationId","payload"],"additionalProperties":false},"JournalHead":{"type":"object","properties":{"at":{"type":"string"},"sequence":{"type":"integer","minimum":0}},"required":["at"],"additionalProperties":false,"description":"Where a tenant's journal stood at a moment."}},"securitySchemes":{"bearer":{"type":"http","scheme":"bearer","bearerFormat":"JWT","description":"A tenant JWT: sign in through the auth service, choose the organization, then `GET /api/auth/token`. Tokens last 15 minutes."}}},"security":[],"tags":[{"name":"settings","description":"Who the tenant's mail and text messages go out as, the domain its mail sends from, its brand, and the host its customer pages are served on."},{"name":"notifications","description":"The record of every message sent for the tenant."},{"name":"suppressions","description":"The addresses the tenant no longer sends to, because they bounced, complained or opted out."},{"name":"templates","description":"The tenant's own designs for the emails Manifold sends, written in react-email's dialect and rendered in a sandbox."},{"name":"brands","description":"The brand a tenant's customer pages wear, and the host they are served on."},{"name":"push","description":"Push to the organization's own people, on their phones and in their browsers: their devices, what reaches them, and raising one."},{"name":"alerts","description":"A person's own choice of which operational emails about the organization reach them."},{"name":"events","description":"The notifications service's append-only event log."}],"servers":[{"url":"https://notifications.getmanifold.io","description":"Production"}]}