{"openapi":"3.1.0","info":{"title":"Rezolve Brief API","version":"1.0.0","description":"Operator API for configuring sources, generating and inspecting saved intelligence digests, and explicitly sending a saved edition. All /v1 operations require a Bearer operator key. Read-only requests do not collect sources or send email. Generation and sending are separate paid actions. Start with /llms.txt and /docs/api.md for the agent workflow. No user accounts or editorial approval endpoint are implemented."},"servers":[{"url":"/","description":"This service origin"}],"tags":[{"name":"Health","description":"Public process and storage probes."},{"name":"Configuration","description":"Read and replace the complete non-secret configuration using optimistic concurrency."},{"name":"Digests","description":"Create one durable asynchronous run, poll it and inspect the saved edition."},{"name":"Delivery","description":"Explicit per-recipient sending and read-only saved outcome inspection."}],"paths":{"/health/live":{"get":{"operationId":"getLiveness","tags":["Health"],"summary":"Check process liveness","security":[],"responses":{"200":{"description":"Process answers HTTP.","content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"required":["status"],"properties":{"status":{"type":"string","const":"ok"}}}}}}}}},"/health/ready":{"get":{"operationId":"getReadiness","tags":["Health"],"summary":"Check storage readiness","security":[],"description":"Checks PostgreSQL readiness or file-store read/write access. This probe does not verify provider credentials, source coverage, worker progress or email delivery.","responses":{"200":{"description":"Ready for API requests.","content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"required":["status"],"properties":{"status":{"type":"string","const":"ready"}}}}}},"503":{"description":"STORAGE_UNAVAILABLE or SHUTTING_DOWN.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/config":{"get":{"security":[{"bearerAuth":[]}],"operationId":"getConfig","tags":["Configuration"],"summary":"Read the current configuration","description":"Returns {config, version} and a quoted ETag. To update, modify config and PUT only that object with If-Match set to the ETag.","responses":{"200":{"description":"Current non-secret configuration.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/StoredConfig"}}},"headers":{"ETag":{"description":"Quoted current configuration version, to return unchanged in If-Match.","schema":{"type":"string","pattern":"^\"[a-f0-9]{64}\"$"},"example":"\"9dcd53d4b3a53977e6dcc7c6a93ff8238ed6bf38c18b70f0900eeaeb1ac0b5c7\""}}},"401":{"description":"UNAUTHORIZED: missing or invalid Bearer token.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"WWW-Authenticate":{"schema":{"type":"string"},"example":"Bearer"}}},"413":{"description":"BODY_TOO_LARGE: request body exceeds 256 KiB.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Server/storage failure, e.g. OPERATION_FAILED. Inspect the sanitized server log; do not automatically repeat a paid operation.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"put":{"security":[{"bearerAuth":[]}],"operationId":"replaceConfig","tags":["Configuration"],"summary":"Replace the complete configuration","description":"Atomic full replacement, not a patch. Existing runs retain their saved config and version. Unknown fields and active credential values are rejected. On 409, reread and reconcile; do not blindly overwrite. Config updates do not enable the schedule or change membership of a Signals list.","parameters":[{"name":"If-Match","in":"header","required":true,"description":"Use the quoted ETag from GET /v1/config. Bare SHA-256 is also accepted.","schema":{"type":"string","pattern":"^\"?[a-f0-9]{64}\"?$"},"example":"\"9dcd53d4b3a53977e6dcc7c6a93ff8238ed6bf38c18b70f0900eeaeb1ac0b5c7\""}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppConfig"}}}},"responses":{"200":{"description":"Saved configuration and new version.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/StoredConfig"}}},"headers":{"ETag":{"description":"Quoted current configuration version, to return unchanged in If-Match.","schema":{"type":"string","pattern":"^\"[a-f0-9]{64}\"$"},"example":"\"9dcd53d4b3a53977e6dcc7c6a93ff8238ed6bf38c18b70f0900eeaeb1ac0b5c7\""}}},"400":{"description":"INVALID_JSON, INVALID_CONFIG_VERSION, INVALID_CONFIG or SECRET_IN_CONFIG.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"UNAUTHORIZED: missing or invalid Bearer token.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"WWW-Authenticate":{"schema":{"type":"string"},"example":"Bearer"}}},"409":{"description":"CONFIG_VERSION_CONFLICT: configuration changed since it was read.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"413":{"description":"BODY_TOO_LARGE: request body exceeds 256 KiB.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"415":{"description":"JSON_REQUIRED: use Content-Type: application/json.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"428":{"description":"CONFIG_VERSION_REQUIRED: If-Match is missing.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Server/storage failure, e.g. OPERATION_FAILED. Inspect the sanitized server log; do not automatically repeat a paid operation.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"SHUTTING_DOWN or service unavailable. A request timeout/failure does not prove no work occurred; reconcile using the existing idempotency key.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/digests":{"post":{"security":[{"bearerAuth":[]}],"operationId":"createDigest","tags":["Digests"],"summary":"Create or replay a digest generation request","description":"Paid operation. A new request persists ID, exact window and a config snapshot before provider calls. PostgreSQL run+job are committed atomically and processed by the worker; files mode starts work in-process. The same key and semantically equivalent request returns the same run, even after restart/current-config changes. A different request with the same key returns 409. Only one running or worker-pending run is allowed; no backlog is accumulated. After transport ambiguity, replay the same key/body. A new key means a new paid run. This endpoint never sends email or marks stories as shown.","parameters":[{"name":"Idempotency-Key","in":"header","required":true,"schema":{"type":"string","minLength":1,"maxLength":128,"pattern":"^[A-Za-z0-9][A-Za-z0-9._:-]{0,127}$"},"example":"agent-preview-2026-10-28-01"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/GenerateInput"},"example":{}}}},"responses":{"200":{"description":"Existing run replayed; no new generation started.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DigestRun"}}},"headers":{"Location":{"description":"Relative URL of this saved run.","schema":{"type":"string"}}}},"202":{"description":"New asynchronous run saved; poll Location or links.self.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DigestRun"}}},"headers":{"Location":{"description":"Relative URL of this saved run.","schema":{"type":"string"}}}},"400":{"description":"INVALID_JSON, INVALID_REQUEST, INVALID_GENERATION_INPUT or INVALID_IDEMPOTENCY_KEY.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"UNAUTHORIZED: missing or invalid Bearer token.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"WWW-Authenticate":{"schema":{"type":"string"},"example":"Bearer"}}},"409":{"description":"IDEMPOTENCY_CONFLICT or GENERATION_BUSY. For busy, inspect the current run and retry explicitly when appropriate.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"413":{"description":"BODY_TOO_LARGE: request body exceeds 256 KiB.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"415":{"description":"JSON_REQUIRED: use Content-Type: application/json.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Server/storage failure, e.g. OPERATION_FAILED. Inspect the sanitized server log; do not automatically repeat a paid operation.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"SHUTTING_DOWN or service unavailable. A request timeout/failure does not prove no work occurred; reconcile using the existing idempotency key.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}},"get":{"security":[{"bearerAuth":[]}],"operationId":"listDigests","tags":["Digests"],"summary":"List saved runs, newest first","parameters":[{"name":"limit","in":"query","required":false,"schema":{"type":"integer","minimum":1,"maximum":100,"default":50}}],"responses":{"200":{"description":"Latest saved runs. No cursor pagination is currently available.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DigestRunList"}}}},"400":{"description":"INVALID_LIMIT: limit must be an integer from 1 to 100.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"UNAUTHORIZED: missing or invalid Bearer token.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"WWW-Authenticate":{"schema":{"type":"string"},"example":"Bearer"}}},"413":{"description":"BODY_TOO_LARGE: request body exceeds 256 KiB.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Server/storage failure, e.g. OPERATION_FAILED. Inspect the sanitized server log; do not automatically repeat a paid operation.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/digests/{id}":{"get":{"security":[{"bearerAuth":[]}],"operationId":"getDigestRun","tags":["Digests"],"summary":"Read a saved run and its status","parameters":[{"name":"id","in":"path","required":true,"description":"Saved API run UUID from POST /v1/digests; not the composition runId or email textHash.","schema":{"type":"string","format":"uuid","pattern":"^[0-9a-f]{8}-[0-9a-f]{4}-4[0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}$"},"example":"11111111-1111-4111-8111-111111111111"}],"description":"Safe to poll. Stops at ready, failed or interrupted. ready does not mean reviewed or approved. Check result.digestStatus, coverage and evidence before any explicit send.","responses":{"200":{"description":"Saved run status and artifact links.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DigestRun"}}}},"401":{"description":"UNAUTHORIZED: missing or invalid Bearer token.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"WWW-Authenticate":{"schema":{"type":"string"},"example":"Bearer"}}},"404":{"description":"RUN_NOT_FOUND: no run with this UUID.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"413":{"description":"BODY_TOO_LARGE: request body exceeds 256 KiB.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Server/storage failure, e.g. OPERATION_FAILED. Inspect the sanitized server log; do not automatically repeat a paid operation.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/digests/{id}/json":{"get":{"security":[{"bearerAuth":[]}],"operationId":"getDigestJson","tags":["Digests"],"summary":"Read structured edition, evidence and diagnostics","parameters":[{"name":"id","in":"path","required":true,"description":"Saved API run UUID from POST /v1/digests; not the composition runId or email textHash.","schema":{"type":"string","format":"uuid","pattern":"^[0-9a-f]{8}-[0-9a-f]{4}-4[0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}$"},"example":"11111111-1111-4111-8111-111111111111"}],"description":"Reads persisted output only. JSON remains available for a held edition; it does not trigger collection, composition or email. Inspect source queries, publication dates, evidence, coverage and costs here.","responses":{"200":{"description":"Structured saved edition.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RenderedDigest"}}}},"401":{"description":"UNAUTHORIZED: missing or invalid Bearer token.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"WWW-Authenticate":{"schema":{"type":"string"},"example":"Bearer"}}},"404":{"description":"RUN_NOT_FOUND: no run with this UUID.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"DIGEST_NOT_READY: generation has not completed successfully.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"413":{"description":"BODY_TOO_LARGE: request body exceeds 256 KiB.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Server/storage failure, e.g. OPERATION_FAILED. Inspect the sanitized server log; do not automatically repeat a paid operation.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/digests/{id}/html":{"get":{"security":[{"bearerAuth":[]}],"operationId":"getDigestHtml","tags":["Digests"],"summary":"Read the final email HTML","parameters":[{"name":"id","in":"path","required":true,"description":"Saved API run UUID from POST /v1/digests; not the composition runId or email textHash.","schema":{"type":"string","format":"uuid","pattern":"^[0-9a-f]{8}-[0-9a-f]{4}-4[0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}$"},"example":"11111111-1111-4111-8111-111111111111"}],"description":"Renders the saved reader-facing edition without sender credentials. A held edition cannot render as an email. This does not send email.","responses":{"200":{"description":"Reader-facing email HTML.","content":{"text/html":{"schema":{"type":"string"}}}},"401":{"description":"UNAUTHORIZED: missing or invalid Bearer token.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"WWW-Authenticate":{"schema":{"type":"string"},"example":"Bearer"}}},"404":{"description":"RUN_NOT_FOUND: no run with this UUID.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"DIGEST_NOT_READY or EMAIL_EDITION_HELD.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"413":{"description":"BODY_TOO_LARGE: request body exceeds 256 KiB.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Server/storage failure, e.g. OPERATION_FAILED. Inspect the sanitized server log; do not automatically repeat a paid operation.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/digests/{id}/text":{"get":{"security":[{"bearerAuth":[]}],"operationId":"getDigestText","tags":["Digests"],"summary":"Read the final email text","parameters":[{"name":"id","in":"path","required":true,"description":"Saved API run UUID from POST /v1/digests; not the composition runId or email textHash.","schema":{"type":"string","format":"uuid","pattern":"^[0-9a-f]{8}-[0-9a-f]{4}-4[0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}$"},"example":"11111111-1111-4111-8111-111111111111"}],"description":"Renders the saved reader-facing edition without sender credentials. A held edition cannot render as an email. This does not send email.","responses":{"200":{"description":"Reader-facing plain-text email.","content":{"text/plain":{"schema":{"type":"string"}}}},"401":{"description":"UNAUTHORIZED: missing or invalid Bearer token.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"WWW-Authenticate":{"schema":{"type":"string"},"example":"Bearer"}}},"404":{"description":"RUN_NOT_FOUND: no run with this UUID.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"DIGEST_NOT_READY or EMAIL_EDITION_HELD.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"413":{"description":"BODY_TOO_LARGE: request body exceeds 256 KiB.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Server/storage failure, e.g. OPERATION_FAILED. Inspect the sanitized server log; do not automatically repeat a paid operation.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/digests/{id}/send":{"post":{"security":[{"bearerAuth":[]}],"operationId":"sendDigest","tags":["Delivery"],"summary":"Explicitly send a saved edition to selected recipients","parameters":[{"name":"id","in":"path","required":true,"description":"Saved API run UUID from POST /v1/digests; not the composition runId or email textHash.","schema":{"type":"string","format":"uuid","pattern":"^[0-9a-f]{8}-[0-9a-f]{4}-4[0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}$"},"example":"11111111-1111-4111-8111-111111111111"}],"description":"External side effect: sends one separate email per address. Obtain operator approval for the specific edition and recipients before using it. Uses saved content and server sender settings. Identity is edition+normalized recipient; accepted/delivered or ambiguous attempts are not automatically resent. A body/sender change on an existing reservation is EMAIL_CONTENT_CHANGED. Per-recipient outcomes may contain failures even with HTTP 200. accepted is not delivered. Unknown results require reconciliation. Explicit retries are allowed only for known rejected attempts with unchanged content; honor retryAt. Sending does not regenerate the edition or mark stories as shown.","requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SendInput"},"example":{"recipients":["reader@example.com"]}}}},"responses":{"200":{"description":"Inspect every recipient outcome; this HTTP status does not guarantee all messages were accepted or delivered.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DeliveryList"}}}},"400":{"description":"INVALID_JSON, INVALID_REQUEST, INVALID_RECIPIENTS, INVALID_EMAIL_CONFIG or an email preparation error.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"UNAUTHORIZED: missing or invalid Bearer token.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"WWW-Authenticate":{"schema":{"type":"string"},"example":"Bearer"}}},"404":{"description":"RUN_NOT_FOUND: no run with this UUID.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"DIGEST_NOT_READY or EMAIL_EDITION_HELD.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"413":{"description":"BODY_TOO_LARGE: request body exceeds 256 KiB.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"415":{"description":"JSON_REQUIRED: use Content-Type: application/json.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Server/storage failure, e.g. OPERATION_FAILED. Inspect the sanitized server log; do not automatically repeat a paid operation.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"RESEND_CONFIG_MISSING or SHUTTING_DOWN.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/digests/{id}/delivery":{"get":{"security":[{"bearerAuth":[]}],"operationId":"getDigestDeliveries","tags":["Delivery"],"summary":"Read saved per-recipient delivery outcomes","parameters":[{"name":"id","in":"path","required":true,"description":"Saved API run UUID from POST /v1/digests; not the composition runId or email textHash.","schema":{"type":"string","format":"uuid","pattern":"^[0-9a-f]{8}-[0-9a-f]{4}-4[0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}$"},"example":"11111111-1111-4111-8111-111111111111"}],"description":"Reads the saved operator ledger, with no request to Resend and no email side effect. The list is empty before the first persisted attempt. accepted alone does not prove delivery; provider status reconciliation is currently an explicit operator CLI action. Read outcomes are suppressed=true and requests=0 because no send is performed.","responses":{"200":{"description":"Saved outcomes for this edition.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DeliveryList"},"example":{"recipients":[{"recipient":"reader@example.com","attemptId":"bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb","status":"accepted","providerId":"22222222-2222-4222-8222-222222222222","suppressed":true,"requests":0,"code":null}]}}}},"400":{"description":"An email ledger validation/read error.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"UNAUTHORIZED: missing or invalid Bearer token.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"WWW-Authenticate":{"schema":{"type":"string"},"example":"Bearer"}}},"404":{"description":"RUN_NOT_FOUND: no run with this UUID.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"DIGEST_NOT_READY: generation has not completed successfully.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"413":{"description":"BODY_TOO_LARGE: request body exceeds 256 KiB.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Server/storage failure, e.g. OPERATION_FAILED. Inspect the sanitized server log; do not automatically repeat a paid operation.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}}},"components":{"securitySchemes":{"bearerAuth":{"type":"http","scheme":"bearer","description":"Operator API_KEY supplied out of band. Use Authorization: Bearer <API_KEY>. Never put it in a URL, documentation, config body or logs. One operator key grants read, config, paid generation and explicit send access; no user roles exist yet."}},"schemas":{"Error":{"type":"object","additionalProperties":false,"required":["error"],"properties":{"error":{"type":"object","additionalProperties":false,"required":["code"],"properties":{"code":{"type":"string","description":"Stable machine-readable error code. Treat unrecognized codes conservatively."}}}}},"RunWindow":{"type":"object","additionalProperties":false,"required":["from","to"],"properties":{"from":{"type":"string","format":"date-time","pattern":"^\\d{4}-\\d{2}-\\d{2}T\\d{2}:\\d{2}:\\d{2}(?:\\.\\d{1,3})?Z$","description":"ISO 8601 UTC timestamp ending in Z; responses use millisecond precision."},"to":{"type":"string","format":"date-time","pattern":"^\\d{4}-\\d{2}-\\d{2}T\\d{2}:\\d{2}:\\d{2}(?:\\.\\d{1,3})?Z$","description":"ISO 8601 UTC timestamp ending in Z; responses use millisecond precision."}},"description":"Collection interval [from, to): from is inclusive, to is exclusive. Both must be valid UTC calendar timestamps and from must precede to. The fixed interval is saved with the run.","example":{"from":"2026-10-27T13:00:00.000Z","to":"2026-10-28T13:00:00.000Z"}},"SearchCompany":{"type":"object","additionalProperties":false,"required":["id","name"],"properties":{"id":{"type":"string","minLength":1,"maxLength":80,"pattern":"^[A-Za-z0-9][A-Za-z0-9_-]*$"},"name":{"type":"string","minLength":1,"maxLength":120,"description":"Nonempty text; control characters are rejected. Configuration text is trimmed."}}},"SearchTopic":{"type":"object","additionalProperties":false,"required":["id","title","description","allowedAnchors","allowedQualifiers","requiredAnchors"],"properties":{"id":{"type":"string","enum":["rezolve","competitors","market"]},"title":{"type":"string","minLength":1,"maxLength":500,"description":"Nonempty text; control characters are rejected. Configuration text is trimmed."},"description":{"type":"string","minLength":1,"maxLength":4000,"description":"Nonempty text; control characters are rejected. Configuration text is trimmed."},"allowedAnchors":{"type":"array","items":{"type":"string","minLength":1,"maxLength":150,"description":"Nonempty text; control characters are rejected. Configuration text is trimmed."},"minItems":1,"maxItems":30,"uniqueItems":true},"allowedQualifiers":{"type":"array","items":{"type":"string","minLength":1,"maxLength":150,"description":"Nonempty text; control characters are rejected. Configuration text is trimmed."},"minItems":1,"maxItems":30,"uniqueItems":true},"requiredAnchors":{"type":"array","items":{"type":"string","minLength":1,"maxLength":150,"description":"Nonempty text; control characters are rejected. Configuration text is trimmed."},"minItems":0,"maxItems":5,"uniqueItems":true},"companies":{"type":"array","items":{"$ref":"#/components/schemas/SearchCompany"},"minItems":1,"maxItems":20},"searchQueries":{"type":"array","items":{"type":"string","minLength":1,"maxLength":150,"description":"Nonempty text; control characters are rejected. Configuration text is trimmed."},"minItems":1,"maxItems":5,"uniqueItems":true,"description":"Exact search phrases: 2–7 words, normalized whitespace, no dates, relative-time words, quotes, Boolean operators, colons or parentheses. Phrases must also be unique after case/whitespace normalization."}},"description":"Exactly one topic per section. Vocabulary values are unique case-insensitively; requiredAnchors must belong to allowedAnchors. Company IDs/names must be unique case-insensitively; names must belong to allowedAnchors and cover requiredAnchors. Companies are not permitted for market. companies and searchQueries are mutually exclusive. Without either, legacy search compiles phrases using the configured vocabulary. Additional search-specific checks occur before collection.","allOf":[{"not":{"required":["companies","searchQueries"]}},{"if":{"properties":{"id":{"const":"market"}},"required":["id"]},"then":{"not":{"required":["companies"]}}}]},"RssSource":{"type":"object","additionalProperties":false,"required":["id","url","section"],"properties":{"id":{"type":"string","minLength":1,"maxLength":80,"pattern":"^[A-Za-z0-9][A-Za-z0-9_-]*$"},"url":{"type":"string","format":"uri","maxLength":2048,"pattern":"^https?://","description":"Public HTTP(S) URL without embedded credentials or secret query parameters."},"section":{"type":"string","enum":["rezolve","competitors","market"]}}},"SignalsSource":{"type":"object","additionalProperties":false,"required":["id","listId","section"],"properties":{"id":{"type":"string","minLength":1,"maxLength":80,"pattern":"^[A-Za-z0-9][A-Za-z0-9_-]*$"},"listId":{"type":"string","minLength":1,"maxLength":80,"pattern":"^[A-Za-z0-9][A-Za-z0-9_-]*$"},"section":{"type":"string","enum":["rezolve","competitors","market"]}},"description":"References an existing external Signals list. Updating listId switches the list used by collection; this API does not edit list membership."},"SerperSettings":{"type":"object","additionalProperties":false,"required":["maxNewsRequests","maxArticleRequests","maxResults","articleTimeoutMs","maxArticleBytes","usdPerCredit"],"properties":{"maxNewsRequests":{"type":"integer","minimum":0,"maximum":20},"maxArticleRequests":{"type":"integer","minimum":0,"maximum":100},"maxResults":{"type":"integer","minimum":1,"maximum":10},"articleTimeoutMs":{"type":"integer","minimum":100,"maximum":30000},"maxArticleBytes":{"type":"integer","minimum":64000,"maximum":2000000},"usdPerCredit":{"type":"number","minimum":0,"maximum":1}}},"CollectionLimits":{"type":"object","additionalProperties":false,"required":["timeoutMs","maxSearchRequests","maxLlmRequests","maxOutputTokens","maxSearchResults"],"properties":{"timeoutMs":{"type":"integer","minimum":100,"maximum":120000},"maxSearchRequests":{"type":"integer","minimum":0,"maximum":20},"maxLlmRequests":{"type":"integer","minimum":0,"maximum":40},"maxOutputTokens":{"type":"integer","minimum":100,"maximum":4000},"maxSearchResults":{"type":"integer","minimum":1,"maximum":20}}},"AppConfig":{"type":"object","additionalProperties":false,"required":["version","name","timezone","sendTime","maxPreviewItems","topics","rss","signals","limits"],"properties":{"version":{"type":"integer","const":1},"name":{"type":"string","minLength":1,"maxLength":500,"description":"Nonempty text; control characters are rejected. Configuration text is trimmed."},"timezone":{"type":"string","minLength":1,"maxLength":100,"description":"Nonempty text; control characters are rejected. Configuration text is trimmed."},"sendTime":{"type":"string","pattern":"^(?:[01]\\d|2[0-3]):[0-5]\\d$","description":"HH:mm local time. This configuration field does not enable or reconfigure the worker schedule; scheduling is managed separately by the operator CLI."},"maxPreviewItems":{"type":"integer","minimum":1,"maximum":50},"topics":{"type":"array","items":{"$ref":"#/components/schemas/SearchTopic"},"minItems":3,"maxItems":3},"rss":{"type":"array","items":{"$ref":"#/components/schemas/RssSource"},"maxItems":10},"signals":{"type":"array","items":{"$ref":"#/components/schemas/SignalsSource"},"maxItems":10},"serper":{"$ref":"#/components/schemas/SerperSettings"},"limits":{"$ref":"#/components/schemas/CollectionLimits"}},"description":"Complete non-secret configuration, not a patch. timezone must be supported by Intl.DateTimeFormat (normally an IANA timezone). topics must contain rezolve, competitors and market exactly once. Source IDs must be unique across rss and signals. Unknown fields and values containing active credentials are rejected. Credentials are managed outside this API.","example":{"version":1,"name":"Example Brief","timezone":"America/Los_Angeles","sendTime":"06:00","maxPreviewItems":8,"topics":[{"id":"rezolve","title":"Company news","description":"Example company announcements.","allowedAnchors":["Example Commerce"],"allowedQualifiers":["news"],"requiredAnchors":["Example Commerce"],"companies":[{"id":"example-commerce","name":"Example Commerce"}]},{"id":"competitors","title":"Competitor news","description":"Example competitor announcements.","allowedAnchors":["Example Search"],"allowedQualifiers":["news"],"requiredAnchors":["Example Search"],"companies":[{"id":"example-search","name":"Example Search"}]},{"id":"market","title":"Market news","description":"Retail technology announcements.","allowedAnchors":["retail technology"],"allowedQualifiers":["news"],"requiredAnchors":["retail technology"],"searchQueries":["retail technology news"]}],"rss":[],"signals":[],"limits":{"timeoutMs":30000,"maxSearchRequests":3,"maxLlmRequests":2,"maxOutputTokens":1200,"maxSearchResults":10}}},"StoredConfig":{"type":"object","additionalProperties":false,"required":["config","version"],"properties":{"config":{"$ref":"#/components/schemas/AppConfig"},"version":{"type":"string","pattern":"^[a-f0-9]{64}$","description":"Lowercase SHA-256 hex."}},"example":{"config":{"version":1,"name":"Example Brief","timezone":"America/Los_Angeles","sendTime":"06:00","maxPreviewItems":8,"topics":[{"id":"rezolve","title":"Company news","description":"Example company announcements.","allowedAnchors":["Example Commerce"],"allowedQualifiers":["news"],"requiredAnchors":["Example Commerce"],"companies":[{"id":"example-commerce","name":"Example Commerce"}]},{"id":"competitors","title":"Competitor news","description":"Example competitor announcements.","allowedAnchors":["Example Search"],"allowedQualifiers":["news"],"requiredAnchors":["Example Search"],"companies":[{"id":"example-search","name":"Example Search"}]},{"id":"market","title":"Market news","description":"Retail technology announcements.","allowedAnchors":["retail technology"],"allowedQualifiers":["news"],"requiredAnchors":["retail technology"],"searchQueries":["retail technology news"]}],"rss":[],"signals":[],"limits":{"timeoutMs":30000,"maxSearchRequests":3,"maxLlmRequests":2,"maxOutputTokens":1200,"maxSearchResults":10}},"version":"9dcd53d4b3a53977e6dcc7c6a93ff8238ed6bf38c18b70f0900eeaeb1ac0b5c7"}},"GenerateInput":{"type":"object","additionalProperties":false,"required":[],"properties":{"window":{"$ref":"#/components/schemas/RunWindow"},"sources":{"type":"array","items":{"type":"string","enum":["perplexity","serper","signals","rss"]},"minItems":1,"maxItems":4,"uniqueItems":true,"default":["perplexity","serper","signals"]},"sections":{"type":"array","items":{"type":"string","enum":["rezolve","competitors","market"]},"minItems":1,"maxItems":3,"uniqueItems":true,"default":["rezolve","competitors","market"]}},"description":"Use {} for the default sources/sections and the preceding 24 hours fixed at the first request. RSS is available only when explicitly requested. A new idempotency key can incur new provider charges. Generation never sends email."},"RunSummary":{"type":"object","additionalProperties":false,"required":["digestStatus","stories","requestCount","costUsd","knownCostUsd"],"properties":{"digestStatus":{"type":"string","enum":["draft","quiet_day","incomplete","held"]},"stories":{"type":"integer","minimum":0,"maximum":8},"requestCount":{"type":"integer","minimum":0},"costUsd":{"anyOf":[{"type":"number","minimum":0},{"type":"null"}]},"knownCostUsd":{"type":"number","minimum":0},"diagnostics":{"type":"array","items":{"type":"string","pattern":"^[A-Za-z0-9_-]{1,80}$"},"maxItems":100}},"description":"costUsd=null means at least part of the final cost is unknown; knownCostUsd is the known subtotal. ready/draft are not editorial approval.","example":{"digestStatus":"draft","stories":4,"requestCount":10,"costUsd":0.1,"knownCostUsd":0.1,"diagnostics":[]}},"RunLinks":{"type":"object","additionalProperties":false,"required":["self","json","html","text","delivery"],"properties":{"self":{"type":"string"},"json":{"type":"string"},"html":{"type":"string"},"text":{"type":"string"},"delivery":{"type":"string"}}},"DigestRun":{"type":"object","additionalProperties":false,"required":["id","status","createdAt","updatedAt","configVersion","window","sources","sections","result","errorCode","links"],"properties":{"id":{"type":"string","format":"uuid","pattern":"^[0-9a-f]{8}-[0-9a-f]{4}-4[0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}$"},"status":{"type":"string","enum":["running","ready","failed","interrupted"]},"createdAt":{"type":"string","format":"date-time","pattern":"^\\d{4}-\\d{2}-\\d{2}T\\d{2}:\\d{2}:\\d{2}(?:\\.\\d{1,3})?Z$","description":"ISO 8601 UTC timestamp ending in Z; responses use millisecond precision."},"updatedAt":{"type":"string","format":"date-time","pattern":"^\\d{4}-\\d{2}-\\d{2}T\\d{2}:\\d{2}:\\d{2}(?:\\.\\d{1,3})?Z$","description":"ISO 8601 UTC timestamp ending in Z; responses use millisecond precision."},"configVersion":{"type":"string","pattern":"^[a-f0-9]{64}$","description":"Lowercase SHA-256 hex."},"window":{"$ref":"#/components/schemas/RunWindow"},"sources":{"type":"array","items":{"type":"string","enum":["perplexity","serper","signals","rss"]}},"sections":{"type":"array","items":{"type":"string","enum":["rezolve","competitors","market"]}},"result":{"anyOf":[{"$ref":"#/components/schemas/RunSummary"},{"type":"null"}]},"errorCode":{"anyOf":[{"type":"string"},{"type":"null"}]},"links":{"$ref":"#/components/schemas/RunLinks"}},"description":"running includes waiting for a PostgreSQL worker. Poll the self link until ready, failed or interrupted. ready means persisted output exists, not editorial approval; inspect result.digestStatus and the edition. failed/interrupted are terminal for this ID. There is no automatic rerun of claimed paid work. A repeated idempotency key returns this run and its saved configuration/window.","example":{"id":"11111111-1111-4111-8111-111111111111","status":"running","createdAt":"2026-10-28T13:00:00.000Z","updatedAt":"2026-10-28T13:00:00.000Z","configVersion":"9dcd53d4b3a53977e6dcc7c6a93ff8238ed6bf38c18b70f0900eeaeb1ac0b5c7","window":{"from":"2026-10-27T13:00:00.000Z","to":"2026-10-28T13:00:00.000Z"},"sources":["perplexity","serper","signals"],"sections":["rezolve","competitors","market"],"result":null,"errorCode":null,"links":{"self":"/v1/digests/11111111-1111-4111-8111-111111111111","json":"/v1/digests/11111111-1111-4111-8111-111111111111/json","html":"/v1/digests/11111111-1111-4111-8111-111111111111/html","text":"/v1/digests/11111111-1111-4111-8111-111111111111/text","delivery":"/v1/digests/11111111-1111-4111-8111-111111111111/delivery"}}},"DigestRunList":{"type":"object","additionalProperties":false,"required":["items"],"properties":{"items":{"type":"array","items":{"$ref":"#/components/schemas/DigestRun"},"maxItems":100}},"example":{"items":[]}},"ProviderUsage":{"type":"object","additionalProperties":false,"required":["requestCount","inputTokens","outputTokens","costUsd"],"properties":{"requestCount":{"type":"integer","minimum":0},"inputTokens":{"anyOf":[{"type":"integer","minimum":0},{"type":"null"}]},"outputTokens":{"anyOf":[{"type":"integer","minimum":0},{"type":"null"}]},"costUsd":{"anyOf":[{"type":"number","minimum":0},{"type":"null"}]},"knownCostUsd":{"type":"number","minimum":0},"estimatedCostUsd":{"type":"number","minimum":0}},"description":"USD values. null cost means unknown; estimatedCostUsd is the part calculated from published/configured rates, not a provider-confirmed invoice. A known subtotal may coexist with an unknown total."},"Diagnostic":{"type":"object","additionalProperties":false,"required":["code","message"],"properties":{"code":{"type":"string"},"message":{"type":"string"}}},"PublicationDate":{"type":"object","additionalProperties":false,"required":["value","precision"],"properties":{"value":{"anyOf":[{"type":"string"},{"type":"null"}]},"precision":{"type":"string","enum":["instant","day","unknown"]}},"description":"instant uses an ISO timestamp; day is YYYY-MM-DD without a known publication time; unknown has value=null. Publication metadata alone does not prove the event happened in the interval."},"CoverageSource":{"type":"object","additionalProperties":false,"required":["sourceId","provider","section","status","diagnostics","usage","elapsedMs"],"properties":{"sourceId":{"type":"string"},"provider":{"type":"string","enum":["perplexity","serper","signals","rss"]},"section":{"type":"string","enum":["rezolve","competitors","market"]},"status":{"type":"string","enum":["ok","empty","partial","unavailable","failed"]},"diagnostics":{"type":"array","items":{"$ref":"#/components/schemas/Diagnostic"}},"usage":{"$ref":"#/components/schemas/ProviderUsage"},"elapsedMs":{"type":"number","minimum":0}}},"CollectionTotals":{"type":"object","additionalProperties":false,"required":["collectedItems","displayedItems","sourceRequests","knownCostUsd","estimatedCostUsd","costUsd","unknownCostSources"],"properties":{"collectedItems":{"type":"integer","minimum":0},"displayedItems":{"type":"integer","minimum":0},"sourceRequests":{"type":"integer","minimum":0},"knownCostUsd":{"type":"number","minimum":0},"estimatedCostUsd":{"type":"number","minimum":0},"costUsd":{"anyOf":[{"type":"number","minimum":0},{"type":"null"}]},"unknownCostSources":{"type":"integer","minimum":0}}},"SupportedText":{"type":"object","additionalProperties":false,"required":["text","evidenceIds"],"properties":{"text":{"type":"string"},"evidenceIds":{"type":"array","items":{"type":"string","pattern":"^e[1-9][0-9]*$"}}},"description":"Evidence IDs reference this story’s evidence array only; they are not an independent guarantee of factual accuracy."},"StoryEvidence":{"type":"object","additionalProperties":false,"required":["id","candidateId","occurrenceId","field","quote","url","publishedAt","publisher"],"properties":{"id":{"type":"string"},"candidateId":{"type":"string"},"occurrenceId":{"type":"string"},"field":{"type":"string","enum":["title","snippet"]},"quote":{"type":"string"},"url":{"type":"string","format":"uri"},"publishedAt":{"$ref":"#/components/schemas/PublicationDate"},"publisher":{"anyOf":[{"type":"string"},{"type":"null"}]}}},"DigestStory":{"type":"object","additionalProperties":false,"required":["storyId","headline","summary","whyItMatters","section","kind","updateOf","sourceKind","url","sourceTitle","publicationDate","dateReviewRequired","evidence"],"properties":{"storyId":{"type":"string"},"headline":{"$ref":"#/components/schemas/SupportedText"},"summary":{"$ref":"#/components/schemas/SupportedText"},"whyItMatters":{"type":"string","description":"Editorial interpretation, not an additional source claim."},"section":{"type":"string","enum":["rezolve","competitors","market"]},"kind":{"type":"string","enum":["new","update"]},"updateOf":{"anyOf":[{"type":"string"},{"type":"null"}]},"sourceKind":{"type":"string","enum":["company_release","industry_press","financial_press","social_post","other"]},"url":{"type":"string","format":"uri"},"sourceTitle":{"type":"string"},"publicationDate":{"$ref":"#/components/schemas/PublicationDate"},"dateReviewRequired":{"type":"boolean"},"evidence":{"type":"array","items":{"$ref":"#/components/schemas/StoryEvidence"}}}},"DigestSection":{"type":"object","additionalProperties":false,"required":["id","title","items"],"properties":{"id":{"type":"string","enum":["rezolve","competitors","market"]},"title":{"type":"string"},"items":{"type":"array","items":{"$ref":"#/components/schemas/DigestStory"},"maxItems":8}}},"SearchRequest":{"type":"object","additionalProperties":false,"required":["provider","sourceId","section","recordingStatus","queries"],"properties":{"provider":{"type":"string","enum":["perplexity","serper"]},"sourceId":{"type":"string"},"section":{"type":"string","enum":["rezolve","competitors","market"]},"recordingStatus":{"type":"string","enum":["recorded","not-recorded"]},"queries":{"anyOf":[{"type":"array","items":{"type":"string"}},{"type":"null"}]}},"description":"Recorded collection request attempts, including unsuccessful attempts. Missing queries are not regenerated. This is historical inspection; reading the endpoint makes no provider request."},"SerperDiscovery":{"type":"object","additionalProperties":false,"required":["url","title","providerDate","publishedAt","status","reason","linkedExistingUrl"],"properties":{"url":{"anyOf":[{"type":"string"},{"type":"null"}]},"title":{"anyOf":[{"type":"string"},{"type":"null"}]},"providerDate":{"anyOf":[{"type":"string"},{"type":"null"}]},"publishedAt":{"$ref":"#/components/schemas/PublicationDate"},"status":{"type":"string","enum":["accepted","duplicate","outside_window","rejected","unrecorded"]},"reason":{"type":"string"},"linkedExistingUrl":{"anyOf":[{"type":"string"},{"type":"null"}]}}},"SerperDiscoverySource":{"type":"object","additionalProperties":false,"required":["sourceId","section","searchRequests","articleRequests","articleCacheHits","credits","costUsd","estimatedCostUsd","discoveries"],"properties":{"sourceId":{"type":"string"},"section":{"type":"string","enum":["rezolve","competitors","market"]},"searchRequests":{"anyOf":[{"type":"integer","minimum":0},{"type":"null"}]},"articleRequests":{"anyOf":[{"type":"integer","minimum":0},{"type":"null"}]},"articleCacheHits":{"anyOf":[{"type":"integer","minimum":0},{"type":"null"}]},"credits":{"anyOf":[{"type":"number","minimum":0},{"type":"null"}]},"costUsd":{"anyOf":[{"type":"number","minimum":0},{"type":"null"}]},"estimatedCostUsd":{"type":"number","minimum":0},"discoveries":{"type":"array","items":{"$ref":"#/components/schemas/SerperDiscovery"}}}},"RenderedDigest":{"type":"object","additionalProperties":false,"required":["version","kind","composerVersion","textVersion","runId","createdAt","mode","status","reviewStatus","language","window","configHash","sourceHashEncoding","sourceSnapshotHash","selectionHash","selectionRunId","originalSelection","originRunId","usage","originalComposition","collectionTotals","coverageIncomplete","coverage","diagnostics","wordCount","wordCountScope","textHashAlgorithm","textHash","bodyText","sections","searchRequestsScope","searchRequests","serperDiscoverySources"],"properties":{"version":{"type":"integer","const":1},"kind":{"type":"string","const":"composed-digest"},"composerVersion":{"type":"string","const":"r1-compose-1"},"textVersion":{"type":"string","const":"r1-digest-text-1"},"runId":{"type":"string","description":"Composition artifact ID; different from the UUID used by /v1/digests/{id}."},"createdAt":{"type":"string","format":"date-time","pattern":"^\\d{4}-\\d{2}-\\d{2}T\\d{2}:\\d{2}:\\d{2}(?:\\.\\d{1,3})?Z$","description":"ISO 8601 UTC timestamp ending in Z; responses use millisecond precision."},"mode":{"type":"string","enum":["live","offline","replay"]},"status":{"type":"string","enum":["draft","quiet_day","incomplete","held"]},"reviewStatus":{"type":"string","const":"unreviewed"},"language":{"type":"string","const":"en"},"window":{"$ref":"#/components/schemas/RunWindow"},"configHash":{"type":"string","pattern":"^[a-f0-9]{64}$","description":"Lowercase SHA-256 hex."},"sourceHashEncoding":{"type":"string","const":"canonical-json-v1"},"sourceSnapshotHash":{"type":"string","pattern":"^[a-f0-9]{64}$","description":"Lowercase SHA-256 hex."},"selectionHash":{"type":"string","pattern":"^[a-f0-9]{64}$","description":"Lowercase SHA-256 hex."},"selectionRunId":{"type":"string"},"originalSelection":{"type":"object","additionalProperties":false,"required":["runId","usage"],"properties":{"runId":{"type":"string"},"usage":{"$ref":"#/components/schemas/ProviderUsage"}}},"originRunId":{"type":"string"},"usage":{"$ref":"#/components/schemas/ProviderUsage"},"originalComposition":{"type":"object","additionalProperties":false,"required":["runId","usage"],"properties":{"runId":{"type":"string"},"usage":{"$ref":"#/components/schemas/ProviderUsage"}}},"collectionTotals":{"$ref":"#/components/schemas/CollectionTotals"},"coverageIncomplete":{"type":"boolean"},"coverage":{"type":"array","items":{"$ref":"#/components/schemas/CoverageSource"}},"diagnostics":{"type":"array","items":{"type":"string"}},"wordCount":{"type":"integer","minimum":0,"maximum":500},"wordCountScope":{"type":"string","const":"reader-edition-excluding-operator-appendix"},"textHashAlgorithm":{"type":"string","const":"sha256"},"textHash":{"type":"string","pattern":"^[a-f0-9]{64}$","description":"Lowercase SHA-256 hex."},"bodyText":{"type":"string"},"sections":{"type":"array","items":{"$ref":"#/components/schemas/DigestSection"},"minItems":3,"maxItems":3},"searchRequestsScope":{"type":"string","enum":["collection","original-collection"]},"searchRequests":{"type":"array","items":{"$ref":"#/components/schemas/SearchRequest"}},"serperDiscoverySources":{"type":"array","items":{"$ref":"#/components/schemas/SerperDiscoverySource"}}},"description":"Structured saved edition with evidence, historical source/query inspection and diagnostics. This is not the complete internal composition bundle. A held edition has no publishable stories; its JSON remains inspectable. The final reader-facing email is returned by /html and /text. All editions require editorial review; the automated validator is not implemented yet."},"SendInput":{"type":"object","additionalProperties":false,"required":["recipients"],"properties":{"recipients":{"type":"array","items":{"type":"string","maxLength":254,"format":"email","description":"ASCII email address. Recipient matching is case-insensitive; surrounding whitespace is rejected."},"minItems":1,"maxItems":20,"uniqueItems":true}},"description":"Explicit recipients for this request. All addresses are validated before the first send; duplicates are rejected after lowercasing. Each recipient gets a separate email. The sender and reply-to come from server environment, not this body."},"DeliveryRecovery":{"type":"object","additionalProperties":false,"required":["attemptId","providerId","status","requests","bodyHash"],"properties":{"attemptId":{"type":"string","pattern":"^[a-f0-9]{64}$","description":"Lowercase SHA-256 hex."},"providerId":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}]},"status":{"type":"string","enum":["prepared","sending","accepted","delivered","failed","unknown"]},"requests":{"type":"integer","const":1},"bodyHash":{"type":"string","pattern":"^[a-f0-9]{64}$","description":"Lowercase SHA-256 hex."}},"description":"Provider receipt available when persisting the result failed. Reconcile manually before any retry; do not treat this as permission to send again."},"DeliveryOutcome":{"type":"object","additionalProperties":false,"required":["recipient","attemptId","status","providerId","suppressed","requests","code"],"properties":{"recipient":{"type":"string","maxLength":254,"format":"email","description":"ASCII email address. Recipient matching is case-insensitive; surrounding whitespace is rejected."},"attemptId":{"type":"string","pattern":"^[a-f0-9]{64}$","description":"Lowercase SHA-256 hex."},"status":{"type":"string","enum":["prepared","sending","accepted","delivered","failed","unknown"]},"providerId":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}]},"suppressed":{"type":"boolean"},"requests":{"type":"integer","minimum":0},"code":{"anyOf":[{"type":"string"},{"type":"null"}]},"retryAt":{"type":"string","format":"date-time","pattern":"^\\d{4}-\\d{2}-\\d{2}T\\d{2}:\\d{2}:\\d{2}(?:\\.\\d{1,3})?Z$","description":"ISO 8601 UTC timestamp ending in Z; responses use millisecond precision."},"recovery":{"$ref":"#/components/schemas/DeliveryRecovery"}},"description":"Outcome per recipient. accepted means accepted by Resend, not delivered. unknown is ambiguous and must not be resent automatically. suppressed means this invocation did not repeat the reserved attempt. retryAt is a persisted cooldown, not an automatic retry schedule.","example":{"recipient":"reader@example.com","attemptId":"bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb","status":"accepted","providerId":"22222222-2222-4222-8222-222222222222","suppressed":false,"requests":1,"code":null}},"DeliveryList":{"type":"object","additionalProperties":false,"required":["recipients"],"properties":{"recipients":{"type":"array","items":{"$ref":"#/components/schemas/DeliveryOutcome"}}},"example":{"recipients":[{"recipient":"reader@example.com","attemptId":"bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb","status":"accepted","providerId":"22222222-2222-4222-8222-222222222222","suppressed":false,"requests":1,"code":null}]}}}}}