{"openapi":"3.1.0","info":{"title":"Giggy Speech API","version":"1.0.0","description":"Giggy provides text-to-speech and speech-to-text APIs for applications and voice agents. Batch uses zero credits with request and queue limits; Fast and Streaming use prepaid credits. STT charges ceil(validated audio milliseconds * credits per audio hour / 3600000). Purchased credits expire one calendar year after purchase. See /api/pricing/policy and /pricing for pack conversions. Compatibility surfaces include OpenAI-style TTS, Vapi and MCP."},"externalDocs":{"description":"Giggy Speech API documentation","url":"https://giggy.ai/docs/speech-api"},"servers":[{"url":"https://api.giggy.ai","description":"Production TTS and STT. Live STT defaults to wss://api.giggy.ai/v1/audio/transcriptions; audio and transcript events share one socket. HTTPS paths below cover recordings and explicit legacy transports. Live guide: https://giggy.ai/docs/speech-api#api-stt-low-latency"},{"url":"https://giggy.ai","description":"Existing integrations remain supported."}],"paths":{"/v1/audio/transcriptions":{"post":{"summary":"Transcribe an uploaded recording or live microphone audio","description":"Default mode is fast. WAV PCM16 mono 16 kHz, minimum 0.5 seconds; Batch maximum 1500 seconds, Fast and uploaded-recording Streaming maximum 12 hours. Batch costs zero credits; Fast 4000 and Streaming 8000 credits per input audio hour, rounded up per request. Binary uploads allow 1,382,400,000 audio bytes plus 1 MiB headers/metadata; complete within 30 minutes without a 60-second idle gap. Legacy JSON data URLs are limited to 40 MiB. Live STT defaults to one authenticated WebSocket at /v1/audio/transcriptions (wss://api.giggy.ai/v1/audio/transcriptions in production): send start with raw mono LINEAR16 at 8000 or 16000 Hz, then binary audio and stop on the same socket; read transcription and input_complete there. Jambonz 8 kHz start/audio/stop and opaque options.callSid are supported; unsupported recognition hints reject. options.endpointing=external gives the caller turn control; otherwise server energy endpointing uses 650 ms silence. Optional start.language sets recognition language. For explicit legacy HTTPS/SSE live input send JSON mode=streaming, microphone=true and no source; wait for microphone_ready, then POST ordered frames to /api/generations/{generationUuid}/stt-input. This recording POST is Giggy-native: raw WAV or JSON data URL, HTTP 202 generation JSON for Batch/Fast, or cumulative transcript SSE for Streaming; it is not an OpenAI multipart transcription adapter. Paid API live sessions accept 0.5 seconds to 12 hours, eight sessions per controller, reserve 96,000 credits and refund the difference from actual-duration billing on successful completion. Browser previews retain a 30-second cap. Closing live SSE cancels unfinished work.","security":[{"apiKeyAuth":[]},{"bearerApiKeyAuth":[]}],"parameters":[{"name":"mode","in":"query","description":"Binary WAV uploads only; JSON requests use the body field.","schema":{"type":"string","enum":["batch","fast","streaming"],"default":"fast"}},{"name":"language","in":"query","description":"Binary WAV uploads only. Omit for automatic language detection.","schema":{"type":"string","enum":["Arabic","Cantonese","Chinese","Czech","Dutch","English","Filipino","French","German","Greek","Hindi","Hungarian","Indonesian","Italian","Japanese","Korean","Malay","Persian","Polish","Portuguese","Romanian","Russian","Spanish","Swedish","Thai","Turkish","Vietnamese"]}},{"name":"client_request_id","in":"query","description":"Optional operation UUID for identical-request replay; binary uploads only.","schema":{"type":"string","format":"uuid"}},{"name":"content_retention_12h","in":"query","description":"Binary WAV only: boolean request for 12-hour content retention. Existing policy remains effective.","schema":{"type":"boolean"}},{"name":"compute_eea_adequate_only","in":"query","description":"Binary WAV only: boolean request for EEA/adequate-country processing. Existing policy remains effective.","schema":{"type":"boolean"}}],"requestBody":{"required":true,"content":{"audio/wav":{"schema":{"type":"string","format":"binary"}},"application/json":{"schema":{"type":"object","additionalProperties":false,"properties":{"mode":{"type":"string","enum":["batch","fast","streaming"],"default":"fast"},"language":{"type":["string","null"],"description":"Omit or use null for automatic detection; live input cannot set a language."},"source_audio_data_url":{"type":"string","description":"Base64 WAV data URL for a completed recording; mutually exclusive with microphone."},"client_request_id":{"type":"string","format":"uuid"},"microphone":{"const":true,"description":"Requires Streaming, no source recording and automatic language detection."},"privacy":{"type":"object","additionalProperties":false,"description":"Optional request preferences, also accepted last in WebSocket start. Omission or false preserves the existing policy. These request preferences are accepted without changing retention or processing location.","properties":{"content_retention_12h":{"type":"boolean","description":"Request 12-hour content retention."},"compute_eea_adequate_only":{"type":"boolean","description":"Request EEA/adequate-country processing."}}}}}}}},"responses":{"200":{"description":"Streaming SSE: generation_created, microphone_ready for live input, cumulative transcript_chunk (replace=true), generation_updated and terminal status. Early transcript text can be revised.","content":{"text/event-stream":{"schema":{"type":"string"}}}},"202":{"description":"Batch or Fast generation metadata. Poll GET /v1/generations/{generationUuid}; the completed result.url points to transcript JSON.","content":{"application/json":{"schema":{"type":"object"}}}},"400":{"description":"Invalid mode, source, language, duration or request UUID"},"401":{"description":"API key required"},"402":{"description":"Insufficient credits or API budget"},"409":{"description":"Request identity conflict"},"413":{"description":"Upload exceeds limit"},"429":{"description":"Rate, queue or live session limit"},"503":{"description":"Service unavailable"}}}},"/api/generations/{generationUuid}/stt-input":{"post":{"summary":"Send ordered live STT microphone frames","description":"Use the input_token from microphone_ready. Send unpadded PCM16 LE mono 16 kHz, at most 32,000 bytes per frame, with contiguous sequence numbers starting at zero. Await each acknowledgement before sending the next frame. Send complete=true with the last short frame, or an empty final frame. Paid API audio is capped at 12 hours; browser previews remain capped at 30 seconds. Finish within the admitted duration plus five seconds of transport grace. Do not pad, reconnect or replay ambiguous frames.","security":[],"parameters":[{"name":"generationUuid","in":"path","required":true,"schema":{"type":"string","format":"uuid"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"required":["input_token","sequence","pcm_base64","complete"],"properties":{"input_token":{"type":"string","pattern":"^[a-f0-9]{64}$","description":"Generation-scoped capability from microphone_ready; keep private."},"sequence":{"type":"integer","minimum":0},"pcm_base64":{"type":"string","maxLength":42668},"complete":{"type":"boolean"}}}}}},"responses":{"200":{"description":"Frame accepted: {ok:true}."},"400":{"description":"Invalid PCM or sequence"},"403":{"description":"Invalid input token"},"409":{"description":"Ownership changed"},"410":{"description":"Session ended"},"429":{"description":"Input queue full"}}}},"/v1/audio/dubbing":{"post":{"summary":"Dub single-speaker audio (V25 development)","description":"Development V25 only; production availability requires separate qualification. Source WAV PCM16 mono 16 kHz, 3Ã¢â‚¬â€œ60 seconds, maximum 3 MiB. Optional source transcript skips ASR; optional output script skips translation. No alignment, background preservation or lip sync. Uses 200,000 credits per source-audio hour; source seconds round up. Poll the returned generation for its MP3 and transcripts.","security":[{"apiKeyAuth":[]}],"parameters":[{"name":"Idempotency-Key","in":"header","schema":{"type":"string"},"description":"Reuse only for the identical intended request."}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"required":["source_audio_data_url","target_language"],"properties":{"source_audio_data_url":{"type":"string"},"target_language":{"type":"string"},"input_text":{"type":"string","minLength":1,"maxLength":1250},"output_text":{"type":"string","minLength":1,"maxLength":1250}}}}}},"responses":{"200":{"description":"Identical idempotent request returns its existing generation."},"202":{"description":"Generation admitted; poll GET /v1/generations/{generationUuid}."},"401":{"description":"Invalid API key"},"402":{"description":"Insufficient credits or API budget"},"409":{"description":"Request identity conflict"},"422":{"description":"Invalid source, language, transcript or idempotency key"},"503":{"description":"Qualified worker unavailable"}}}},"/v1/audio/speech":{"post":{"summary":"OpenAI-compatible Giggy speech synthesis","description":"V25 adapter: MP3 uses Fast completed delivery; PCM uses Streaming PCM16 LE, 24 kHz mono. stream_format=sse is supported only for PCM and wraps its native bytes in base64 deltas. No WAV, mu-law, resampling, incremental text input or instructions. Disable client retries. Interrupted delivery requests canonical cancellation.","security":[{"bearerApiKeyAuth":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"required":["model","input","voice"],"properties":{"model":{"const":"giggyspeech"},"input":{"type":"string","minLength":1,"maxLength":20000},"voice":{"type":"string","format":"uuid"},"speed":{"type":"number","minimum":0.25,"maximum":4,"default":1},"response_format":{"type":"string","enum":["pcm","mp3"],"default":"mp3"},"stream_format":{"type":"string","enum":["audio","sse"],"default":"audio"},"sample_rate":{"type":"integer","enum":[24000],"default":24000},"instructions":{"const":""}}}}}},"responses":{"200":{"description":"Native Streaming PCM16 LE at 24 kHz mono, completed Fast MP3, or an SSE envelope over native Streaming PCM.","headers":{"request-id":{"$ref":"#/components/headers/RequestId"},"x-request-id":{"$ref":"#/components/headers/RequestId"},"character-cost":{"$ref":"#/components/headers/CharacterCost"}},"content":{"application/octet-stream":{"schema":{"type":"string","format":"binary"}},"audio/mpeg":{"schema":{"type":"string","format":"binary"}},"text/event-stream":{"schema":{"type":"string"}}}},"401":{"description":"Invalid or revoked Giggy API key","content":{"application/json":{"schema":{"$ref":"#/components/schemas/OpenAiError"}}}},"402":{"description":"Insufficient credits or API budget","content":{"application/json":{"schema":{"$ref":"#/components/schemas/OpenAiError"}}}},"422":{"description":"Invalid or unsupported input","content":{"application/json":{"schema":{"$ref":"#/components/schemas/OpenAiError"}}}},"429":{"description":"Rate or concurrency limit","content":{"application/json":{"schema":{"$ref":"#/components/schemas/OpenAiError"}}}},"503":{"description":"Canonical service unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/OpenAiError"}}}}}}},"/v1/integrations/vapi/text-to-speech/{voiceId}":{"post":{"summary":"Vapi custom TTS webhook","description":"V25 adapter. Configure this URL with an explicit Giggy voice UUID and Bearer API-key credential. Supports only native PCM16 LE, 24 kHz mono; no server conversion or resampling. Uses canonical paid Streaming admission and cancellation on interrupted delivery. Call and customer metadata is ignored.","security":[{"bearerApiKeyAuth":[]}],"parameters":[{"name":"voiceId","in":"path","required":true,"schema":{"type":"string","format":"uuid"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"required":["message"],"properties":{"message":{"type":"object","additionalProperties":true,"required":["type","text","sampleRate"],"properties":{"type":{"const":"voice-request"},"text":{"type":"string","minLength":1,"maxLength":20000},"sampleRate":{"type":"integer","enum":[24000]}}}}}}}},"responses":{"200":{"description":"Headerless signed PCM16 little-endian, mono, at 24 kHz, streamed progressively.","content":{"application/octet-stream":{"schema":{"type":"string","format":"binary"}}}},"401":{"description":"Invalid API key"},"402":{"description":"Insufficient credits or API budget"},"422":{"description":"Unsupported sample rate or invalid request"},"503":{"description":"Canonical service unavailable"}}}},"/v1/generations/{generationUuid}/cancel":{"post":{"summary":"Cancel an Entity-owned API speech generation","description":"Uses the canonical guarded cancellation and settlement transition. Completed/failed/cancelled operations return their existing status. An ownership race may return 409. No direct worker-slot mutation or separate refund occurs.","security":[{"bearerApiKeyAuth":[]},{"apiKeyAuth":[]}],"parameters":[{"name":"generationUuid","in":"path","required":true,"schema":{"type":"string","format":"uuid"}}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"type":"object","additionalProperties":false}}}},"responses":{"200":{"description":"Canonical resulting status","content":{"application/json":{"schema":{"type":"object","required":["generation_uuid","status"],"additionalProperties":false,"properties":{"generation_uuid":{"type":"string","format":"uuid"},"status":{"type":"string"}}}}}},"401":{"description":"Invalid API key"},"404":{"description":"No API speech generation owned by the key Entity"},"409":{"description":"Cancellation raced an ownership transition"},"422":{"description":"Cancellation takes an empty body"},"503":{"description":"Canonical service unavailable"}}}},"/v1/integrations/voices":{"get":{"summary":"List public Giggy voices for connectors","description":"V25 public catalog only. Language is the existing language_code; private voices are never included. Follow next_offset to discover all pages. This catalog alone does not qualify a Genesys synthesis integration.","security":[{"bearerApiKeyAuth":[]},{"apiKeyAuth":[]}],"parameters":[{"name":"limit","in":"query","schema":{"type":"integer","minimum":1,"maximum":100,"default":100}},{"name":"offset","in":"query","schema":{"type":"integer","minimum":0,"maximum":100000,"default":0}}],"responses":{"200":{"description":"Stable UUID-ordered public catalog with bounded pagination","content":{"application/json":{"schema":{"$ref":"#/components/schemas/IntegrationVoices"}}}},"401":{"description":"Invalid API key"},"422":{"description":"Invalid pagination"},"503":{"description":"Voice library unavailable"}}}},"/v1/credits/balance":{"get":{"summary":"Get shared credit balance","description":"Returns the canonical account-wide shared credit balance after billing settlement. This is not remaining account or API-key budget headroom.","security":[{"apiKeyAuth":[]}],"responses":{"200":{"description":"Current shared credit balance","headers":{"request-id":{"$ref":"#/components/headers/RequestId"},"RateLimit-Limit":{"schema":{"type":"integer"}},"RateLimit-Remaining":{"schema":{"type":"integer"}},"RateLimit-Reset":{"schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreditBalance"}}}},"401":{"description":"Missing or invalid API key","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit exceeded","headers":{"RateLimit-Limit":{"schema":{"type":"integer"}},"RateLimit-Remaining":{"schema":{"type":"integer"}},"RateLimit-Reset":{"schema":{"type":"integer"}},"Retry-After":{"schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Required billing or database service unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/text-to-speech":{"post":{"summary":"Generate speech","description":"Batch and Fast return the canonical MP3 response. Streaming returns progressive audio/pcm (pcm_24000) only.","security":[{"apiKeyAuth":[]}],"parameters":[{"name":"Idempotency-Key","in":"header","required":false,"schema":{"type":"string","minLength":1,"maxLength":100,"pattern":"^[A-Za-z0-9._:-]+$"},"description":"Retry-safe operation key scoped to the calling API key."},{"name":"optimize_streaming_latency","in":"query","required":false,"deprecated":true,"schema":{"type":["integer","null"]},"description":"Deprecated compatibility parameter. It is accepted only when mode=streaming and does not alter inference or streaming latency."}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"required":["text","voice_id"],"properties":{"text":{"type":"string","minLength":1,"maxLength":20000,"description":"Supported Unicode speech text. Fast and Streaming accept up to 20,000 Unicode code points; Batch accepts up to 1,250. Emoji are not accepted."},"voice_id":{"type":"string","format":"uuid","description":"A voice_id returned by /v1/voices or /v1/my-voices."},"model_id":{"type":"string","minLength":1,"maxLength":100,"description":"Accepted for compatibility only; it does not select or otherwise affect GiggySpeech inference."},"mode":{"type":"string","enum":["batch","fast","streaming"],"default":"fast","description":"Selects Batch, Fast, or Streaming generation. Defaults to Fast when omitted."},"output_format":{"type":"string","enum":["mp3_24000_160","pcm_24000"],"description":"Streaming defaults to pcm_24000 and accepts only PCM16 LE, 24 kHz mono. Fast and Batch default to mp3_24000_160 and accept only MP3."},"voice_settings":{"type":["object","null"],"description":"Only speed affects GiggySpeech inference. The remaining settings are accepted for compatibility only.","properties":{"stability":{"type":"number"},"similarity_boost":{"type":"number"},"style":{"type":"number"},"use_speaker_boost":{"type":"boolean"},"speed":{"type":"number","minimum":0.25,"maximum":4,"default":1}},"additionalProperties":true},"language_code":{"type":["string","null"],"minLength":2,"maxLength":12,"pattern":"^[A-Za-z]{2,3}(?:-[A-Za-z0-9]{2,8})?$","description":"Must match the selected voice language; it does not override that language."},"pronunciation_dictionary_locators":{"type":["array","null"],"maxItems":3,"items":{"type":"object"},"description":"Accepted for compatibility only; it has no effect on GiggySpeech inference."},"seed":{"type":["integer","null"],"minimum":0,"maximum":4294967295,"description":"If omitted or null, the server selects a seed for this generation. Retries with the same Idempotency-Key retain the same seed."},"previous_text":{"type":["string","null"],"description":"Accepted for compatibility only; it has no effect on GiggySpeech inference."},"next_text":{"type":["string","null"],"description":"Accepted for compatibility only; it has no effect on GiggySpeech inference."},"previous_request_ids":{"type":["array","null"],"maxItems":3,"items":{"type":"string"},"description":"Accepted for compatibility only; it has no effect on GiggySpeech inference."},"next_request_ids":{"type":["array","null"],"maxItems":3,"items":{"type":"string"},"description":"Accepted for compatibility only; it has no effect on GiggySpeech inference."},"apply_text_normalization":{"type":"string","enum":["auto","on","off"],"default":"auto","description":"Accepted for compatibility only; it has no effect on GiggySpeech inference."},"apply_language_text_normalization":{"type":"boolean","default":false,"description":"Accepted for compatibility only; it has no effect on GiggySpeech inference."},"use_pvc_as_ivc":{"type":"boolean","default":false,"deprecated":true,"description":"Accepted for compatibility only; it has no effect on GiggySpeech inference."},"privacy":{"type":"object","additionalProperties":false,"description":"Optional request preferences, placed last in the JSON body. Omission or false preserves the existing policy. These request preferences are accepted without changing retention or processing location.","properties":{"content_retention_12h":{"type":"boolean","description":"Request 12-hour content retention."},"compute_eea_adequate_only":{"type":"boolean","description":"Request EEA/adequate-country processing."}}}}}}}},"responses":{"200":{"description":"Batch and Fast return completed audio/mpeg. Streaming returns progressive audio/pcm only.","headers":{"request-id":{"$ref":"#/components/headers/RequestId"},"character-cost":{"$ref":"#/components/headers/CharacterCost"},"x-trace-id":{"$ref":"#/components/headers/TraceId"},"RateLimit-Limit":{"schema":{"type":"integer"}},"RateLimit-Remaining":{"schema":{"type":"integer"}},"RateLimit-Reset":{"schema":{"type":"integer"}}},"content":{"audio/mpeg":{"schema":{"type":"string","contentEncoding":"binary"}},"audio/pcm":{"schema":{"type":"string","contentEncoding":"binary"}}}},"400":{"description":"Malformed JSON or malformed request identifier.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid API key","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"Available credits, automatic recharge, or an account or key credit budget prevents generation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Voice unavailable to this account","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"Idempotency key reused with different request parameters","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Invalid request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit exceeded","headers":{"RateLimit-Limit":{"schema":{"type":"integer"}},"RateLimit-Remaining":{"schema":{"type":"integer"}},"RateLimit-Reset":{"schema":{"type":"integer"}},"Retry-After":{"schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Server error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Required API service unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"504":{"description":"Generation did not finish within the synchronous request window","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/generations/{generationUuid}":{"get":{"summary":"Get speech generation","security":[{"apiKeyAuth":[]}],"parameters":[{"name":"generationUuid","in":"path","required":true,"schema":{"type":"string","format":"uuid"}}],"responses":{"200":{"description":"Generation status and signed result when completed","headers":{"RateLimit-Limit":{"schema":{"type":"integer"}},"RateLimit-Remaining":{"schema":{"type":"integer"}},"RateLimit-Reset":{"schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/GenerationEnvelope"}}}},"400":{"description":"Invalid generation UUID","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid API key","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Generation not owned by this account or not created through the Speech API","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit exceeded","headers":{"RateLimit-Limit":{"schema":{"type":"integer"}},"RateLimit-Remaining":{"schema":{"type":"integer"}},"RateLimit-Reset":{"schema":{"type":"integer"}},"Retry-After":{"schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Server error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Required API service unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/generations/{generationUuid}/stream":{"get":{"summary":"Stream speech generation events and ordered PCM chunks","security":[{"apiKeyAuth":[]}],"parameters":[{"name":"generationUuid","in":"path","required":true,"schema":{"type":"string","format":"uuid"}}],"responses":{"200":{"description":"Server-sent events. Event names are heartbeat, generation_updated, audio_chunk, and error. Errors emitted after connection are event-stream messages and do not change the established HTTP 200 response.","headers":{"RateLimit-Limit":{"schema":{"type":"integer"}},"RateLimit-Remaining":{"schema":{"type":"integer"}},"RateLimit-Reset":{"schema":{"type":"integer"}}},"content":{"text/event-stream":{"schema":{"type":"string"}}}},"400":{"description":"Invalid generation UUID","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid API key","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Generation unavailable to this account","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit exceeded","headers":{"RateLimit-Limit":{"schema":{"type":"integer"}},"RateLimit-Remaining":{"schema":{"type":"integer"}},"RateLimit-Reset":{"schema":{"type":"integer"}},"Retry-After":{"schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Server error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Required API service unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/voices":{"get":{"summary":"List and search public voices","security":[{"apiKeyAuth":[]}],"parameters":[{"name":"q","in":"query","schema":{"type":"string","maxLength":80}},{"name":"language","in":"query","schema":{"type":"string","maxLength":80}},{"name":"limit","in":"query","schema":{"type":"integer","minimum":1,"maximum":20,"default":10}},{"name":"offset","in":"query","schema":{"type":"integer","minimum":0,"maximum":10000,"default":0}}],"responses":{"200":{"description":"Bounded list/slice of public voices using limit and offset.","headers":{"RateLimit-Limit":{"schema":{"type":"integer"}},"RateLimit-Remaining":{"schema":{"type":"integer"}},"RateLimit-Reset":{"schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/VoiceList"}}}},"400":{"description":"Invalid pagination or filters","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid API key","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit exceeded","headers":{"RateLimit-Limit":{"schema":{"type":"integer"}},"RateLimit-Remaining":{"schema":{"type":"integer"}},"RateLimit-Reset":{"schema":{"type":"integer"}},"Retry-After":{"schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Server error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Required API service unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/v1/my-voices":{"get":{"summary":"List completed custom voices owned by the account","security":[{"apiKeyAuth":[]}],"parameters":[{"name":"limit","in":"query","schema":{"type":"integer","minimum":1,"maximum":20,"default":10}},{"name":"offset","in":"query","schema":{"type":"integer","minimum":0,"maximum":10000,"default":0}}],"responses":{"200":{"description":"Bounded list/slice of completed custom voices using limit and offset.","headers":{"RateLimit-Limit":{"schema":{"type":"integer"}},"RateLimit-Remaining":{"schema":{"type":"integer"}},"RateLimit-Reset":{"schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/OwnedVoiceList"}}}},"400":{"description":"Invalid pagination","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid API key","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit exceeded","headers":{"RateLimit-Limit":{"schema":{"type":"integer"}},"RateLimit-Remaining":{"schema":{"type":"integer"}},"RateLimit-Reset":{"schema":{"type":"integer"}},"Retry-After":{"schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Server error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Required API service unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}}},"components":{"headers":{"RequestId":{"description":"Correlation identifier for the request. On a successful text-to-speech POST, it contains the resulting generation UUID. On error responses and other endpoints, treat it only as a correlation identifier unless documented otherwise.","schema":{"type":"string","format":"uuid"}},"CharacterCost":{"description":"Number of Unicode code points in the submitted text. This character-count metric is not the number of credits charged.","schema":{"type":"integer","minimum":0}},"TraceId":{"description":"Trace identifier for the completed speech generation.","schema":{"type":"string","format":"uuid"}}},"securitySchemes":{"apiKeyAuth":{"type":"apiKey","in":"header","name":"xi-api-key"},"bearerApiKeyAuth":{"type":"http","scheme":"bearer","bearerFormat":"Giggy API key"}},"schemas":{"OpenAiError":{"type":"object","required":["error"],"additionalProperties":false,"properties":{"error":{"type":"object","required":["message","type","param","code"],"additionalProperties":false,"properties":{"message":{"type":"string"},"type":{"type":"string"},"param":{"type":["string","null"]},"code":{"type":"string"}}}}},"IntegrationVoices":{"type":"object","required":["voices","count","offset","has_more","next_offset"],"additionalProperties":false,"properties":{"voices":{"type":"array","items":{"type":"object","additionalProperties":false,"required":["voice_id","name","language","gender","accent","model_id","output_formats","preview_url"],"properties":{"voice_id":{"type":"string","format":"uuid"},"name":{"type":"string"},"language":{"type":"string"},"gender":{"type":["string","null"]},"accent":{"type":["string","null"]},"model_id":{"const":"giggyspeech"},"output_formats":{"type":"array","items":{"enum":["pcm_24000","mp3_24000_160"]}},"preview_url":{"type":["string","null"]}}}},"count":{"type":"integer"},"offset":{"type":"integer"},"has_more":{"type":"boolean"},"next_offset":{"type":["integer","null"]}}},"CreditBalance":{"type":"object","additionalProperties":false,"required":["credit_balance","currency"],"properties":{"credit_balance":{"type":"integer","minimum":0},"currency":{"const":"credits"}}},"Generation":{"type":"object","additionalProperties":false,"required":["generation_uuid","client_request_id","status","status_label","batch_queue_slot_eligible","queue_position","error_code","tool","model_id","source","format","kind","title","prompt_preview","speed","created_at","status_at","queue_elapsed_ms","inference_elapsed_ms","credits_deducted","credit_refund_issued","voice","result"],"properties":{"generation_uuid":{"type":"string","format":"uuid"},"client_request_id":{"type":["string","null"],"format":"uuid"},"status":{"type":"string","enum":["queued","processing","completed","failed"]},"status_label":{"type":"string","description":"Presentation text. Use status for the machine lifecycle field."},"batch_queue_slot_eligible":{"type":"boolean"},"queue_position":{"type":["integer","null"]},"error_code":{"type":["string","null"],"enum":["generation_failed",null]},"tool":{"const":"giggyspeech-tts"},"model_id":{"type":["string","null"]},"source":{"type":["string","null"]},"format":{"const":"speech"},"kind":{"const":"audio"},"title":{"type":"string"},"prompt_preview":{"type":"string"},"speed":{"type":["number","null"]},"created_at":{"type":"string","format":"date-time"},"status_at":{"type":"string","format":"date-time"},"queue_elapsed_ms":{"type":["integer","null"],"minimum":0},"inference_elapsed_ms":{"type":["integer","null"],"minimum":0},"credits_deducted":{"type":"integer","minimum":0},"credit_refund_issued":{"type":"boolean"},"voice":{"type":"object","additionalProperties":false,"required":["voice_id","name","language_code","language_label","giggyspeech_language"],"properties":{"voice_id":{"type":["string","null"],"format":"uuid"},"name":{"type":["string","null"]},"language_code":{"type":["string","null"]},"language_label":{"type":["string","null"]},"giggyspeech_language":{"type":["string","null"]}}},"result":{"type":["object","null"],"additionalProperties":false,"properties":{"url":{"type":"string"},"thumbnail_url":{"type":"null"}},"required":["url","thumbnail_url"]}}},"GenerationEnvelope":{"type":"object","required":["api_version","generation"],"properties":{"api_version":{"const":"v1"},"generation":{"$ref":"#/components/schemas/Generation"}},"additionalProperties":false},"Error":{"type":"object","additionalProperties":false,"required":["detail"],"properties":{"detail":{"type":"object","additionalProperties":false,"required":["type","code","message","status","request_id","param"],"properties":{"type":{"type":"string"},"code":{"type":"string"},"message":{"type":"string"},"status":{"type":"string"},"request_id":{"type":"string","format":"uuid"},"param":{"type":["string","null"]}}}}},"VoiceList":{"type":"object","additionalProperties":false,"required":["voices"],"properties":{"voices":{"type":"array","items":{"type":"object","required":["voice_id"],"properties":{"voice_id":{"type":"string","format":"uuid"},"name":{"type":["string","null"]},"samples":{"type":["array","null"]},"category":{"type":["string","null"]},"fine_tuning":{"type":["object","null"]},"labels":{"type":["object","null"],"additionalProperties":{"type":"string"}},"description":{"type":["string","null"]},"preview_url":{"type":["string","null"]},"available_for_tiers":{"type":["array","null"],"items":{"type":"string"}},"settings":{"type":["object","null"]},"sharing":{"type":["object","null"]},"high_quality_base_model_ids":{"type":["array","null"],"items":{"type":"string"}},"verified_languages":{"type":["array","null"],"items":{"type":"object"}},"collection_ids":{"type":["array","null"],"items":{"type":"string"}},"safety_control":{"type":["string","null"]},"voice_verification":{"type":["object","null"]},"permission_on_resource":{"type":["string","null"]},"is_owner":{"type":["boolean","null"]},"is_legacy":{"type":["boolean","null"]},"is_mixed":{"type":["boolean","null"]},"favorited_at_unix":{"type":["integer","null"]},"created_at_unix":{"type":["integer","null"]},"is_bookmarked":{"type":["boolean","null"]},"recording_quality":{"type":["string","null"]},"labelling_status":{"type":["string","null"]},"recording_quality_reason":{"type":["string","null"]}},"additionalProperties":false}}}},"OwnedVoiceList":{"type":"object","additionalProperties":false,"required":["voices"],"properties":{"voices":{"type":"array","items":{"type":"object","required":["voice_id"],"properties":{"voice_id":{"type":"string","format":"uuid"},"name":{"type":["string","null"]},"samples":{"type":["array","null"]},"category":{"type":["string","null"]},"fine_tuning":{"type":["object","null"]},"labels":{"type":["object","null"],"additionalProperties":{"type":"string"}},"description":{"type":["string","null"]},"preview_url":{"type":["string","null"]},"available_for_tiers":{"type":["array","null"],"items":{"type":"string"}},"settings":{"type":["object","null"]},"sharing":{"type":["object","null"]},"high_quality_base_model_ids":{"type":["array","null"],"items":{"type":"string"}},"verified_languages":{"type":["array","null"],"items":{"type":"object"}},"collection_ids":{"type":["array","null"],"items":{"type":"string"}},"safety_control":{"type":["string","null"]},"voice_verification":{"type":["object","null"]},"permission_on_resource":{"type":["string","null"]},"is_owner":{"type":["boolean","null"]},"is_legacy":{"type":["boolean","null"]},"is_mixed":{"type":["boolean","null"]},"favorited_at_unix":{"type":["integer","null"]},"created_at_unix":{"type":["integer","null"]},"is_bookmarked":{"type":["boolean","null"]},"recording_quality":{"type":["string","null"]},"labelling_status":{"type":["string","null"]},"recording_quality_reason":{"type":["string","null"]}},"additionalProperties":false}}}}}}}