Create Consent Challenge
Authentication
Enter your API key with the Bearer prefix, e.g. ‘Bearer sk_…’.
Headers
Request
Full name of the person consenting to have their voice cloned. Speechify binds it to the challenge and stores it with the consent record, so the create that consumes the challenge does not carry it and cannot change it.
At most 120 bytes once UTF-8 encoded, which is 120 characters of
Latin script but around 40 of Chinese, Japanese or Korean. Stated in
bytes rather than as a maxLength because the two only agree on
single-byte scripts, and a character count that never over-accepts
would have to refuse Latin names at 30. A name over the limit comes
back as validation_failed reporting its measured length.
Response headers
Request-rate budget: the maximum number of requests in the current
window (the bucket capacity). The IETF-draft un-prefixed name; the
legacy alias X-RateLimit-Limit carries the same value. Rides every
response.
Request-rate budget: requests left in the current window. Legacy
alias: X-RateLimit-Remaining.
Request-rate budget: integer delta-seconds until the window fully
refills (same unit as Retry-After). Legacy alias:
X-RateLimit-Reset.
Response
Identifier for this challenge, sent back as consent_challenge_id
on the create. Treat it as an opaque string - the format is not part
of the contract and will not stay stable.
The sentence the speaker must read aloud. Show it exactly as returned - the recording is transcribed and matched against this text, so re-wording, re-casing or re-punctuating it will fail the check.
When the challenge stops being usable. This is the only authority on the window - do not hard-code a duration. Past it, create a new challenge and record the new phrase.