curl --request POST \
--url https://api.zerogpu.ai/zeroclick/v1/audio/speech \
--header 'Content-Type: multipart/form-data' \
--header 'zc-signature: <api-key>' \
--form 'input=Testing model to generate voice. Hey how are you today?' \
--form voice_sample=@example-fileimport requests
url = "https://api.zerogpu.ai/zeroclick/v1/audio/speech"
files = { "voice_sample": ("example-file", open("example-file", "rb")) }
payload = { "input": "Testing model to generate voice. Hey how are you today?" }
headers = {"zc-signature": "<api-key>"}
response = requests.post(url, data=payload, files=files, headers=headers)
print(response.text)const form = new FormData();
form.append('input', 'Testing model to generate voice. Hey how are you today?');
form.append('voice_sample', '{
"fileName": "example-file"
}');
const options = {method: 'POST', headers: {'zc-signature': '<api-key>'}};
options.body = form;
fetch('https://api.zerogpu.ai/zeroclick/v1/audio/speech', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));falsepackage main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.zerogpu.ai/zeroclick/v1/audio/speech"
payload := strings.NewReader("-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"input\"\r\n\r\nTesting model to generate voice. Hey how are you today?\r\n-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"voice_sample\"; filename=\"example-file\"\r\nContent-Type: application/octet-stream\r\n\r\n{\r\n \"fileName\": \"example-file\"\r\n}\r\n-----011000010111000001101001--")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("zc-signature", "<api-key>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}require 'uri'
require 'net/http'
url = URI("https://api.zerogpu.ai/zeroclick/v1/audio/speech")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["zc-signature"] = '<api-key>'
request.body = "-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"input\"\r\n\r\nTesting model to generate voice. Hey how are you today?\r\n-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"voice_sample\"; filename=\"example-file\"\r\nContent-Type: application/octet-stream\r\n\r\n{\r\n \"fileName\": \"example-file\"\r\n}\r\n-----011000010111000001101001--"
response = http.request(request)
puts response.read_body"<string>"{
"error": {
"message": "POST /v1/audio/transcriptions expects a multipart/form-data body containing the audio `file` field.",
"type": "invalid_request_error",
"param": null,
"code": "invalid_content_type"
}
}{
"error": "invalid_zeroclick_signature"
}{}{
"error": {
"message": "Rate limit reached for LFM2.5-1.2B-Instruct in organization org_123 on requests per min (RPM): Limit 60, Used 60, Requested 1. Please try again in 1s.",
"type": "rate_limit_error",
"param": null,
"code": "requests_per_minute_exceeded"
}
}{
"error": {
"message": "Internal error",
"type": "internal_error"
}
}Speech (ZeroClick)
Generate speech with chatterbox-nano, authenticated by a ZeroClick HMAC signature instead of an API key.
curl --request POST \
--url https://api.zerogpu.ai/zeroclick/v1/audio/speech \
--header 'Content-Type: multipart/form-data' \
--header 'zc-signature: <api-key>' \
--form 'input=Testing model to generate voice. Hey how are you today?' \
--form voice_sample=@example-fileimport requests
url = "https://api.zerogpu.ai/zeroclick/v1/audio/speech"
files = { "voice_sample": ("example-file", open("example-file", "rb")) }
payload = { "input": "Testing model to generate voice. Hey how are you today?" }
headers = {"zc-signature": "<api-key>"}
response = requests.post(url, data=payload, files=files, headers=headers)
print(response.text)const form = new FormData();
form.append('input', 'Testing model to generate voice. Hey how are you today?');
form.append('voice_sample', '{
"fileName": "example-file"
}');
const options = {method: 'POST', headers: {'zc-signature': '<api-key>'}};
options.body = form;
fetch('https://api.zerogpu.ai/zeroclick/v1/audio/speech', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));falsepackage main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.zerogpu.ai/zeroclick/v1/audio/speech"
payload := strings.NewReader("-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"input\"\r\n\r\nTesting model to generate voice. Hey how are you today?\r\n-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"voice_sample\"; filename=\"example-file\"\r\nContent-Type: application/octet-stream\r\n\r\n{\r\n \"fileName\": \"example-file\"\r\n}\r\n-----011000010111000001101001--")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("zc-signature", "<api-key>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}require 'uri'
require 'net/http'
url = URI("https://api.zerogpu.ai/zeroclick/v1/audio/speech")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["zc-signature"] = '<api-key>'
request.body = "-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"input\"\r\n\r\nTesting model to generate voice. Hey how are you today?\r\n-----011000010111000001101001\r\nContent-Disposition: form-data; name=\"voice_sample\"; filename=\"example-file\"\r\nContent-Type: application/octet-stream\r\n\r\n{\r\n \"fileName\": \"example-file\"\r\n}\r\n-----011000010111000001101001--"
response = http.request(request)
puts response.read_body"<string>"{
"error": {
"message": "POST /v1/audio/transcriptions expects a multipart/form-data body containing the audio `file` field.",
"type": "invalid_request_error",
"param": null,
"code": "invalid_content_type"
}
}{
"error": "invalid_zeroclick_signature"
}{}{
"error": {
"message": "Rate limit reached for LFM2.5-1.2B-Instruct in organization org_123 on requests per min (RPM): Limit 60, Used 60, Requested 1. Please try again in 1s.",
"type": "rate_limit_error",
"param": null,
"code": "requests_per_minute_exceeded"
}
}{
"error": {
"message": "Internal error",
"type": "internal_error"
}
}/v1/audio/speech — only authentication, authorization, and metering differ. The body is streamed upstream unread, so the request is always served by the configured model (chatterbox-nano). Send JSON, or multipart/form-data with a voice_sample to clone a voice.
- Authentication — no
x-api-key. A buying agent calls ZeroClick’s hosted pay URL; ZeroClick proxies the request and signs the raw request bytes with an HMAC in thezc-signatureheader. A request is authenticated only by a valid signature. - Authorization — a ZeroClick allowance check runs before any billable work. It fails open on a transient ZeroClick outage (the signature has already verified), but never for a missing or invalid signature.
- Metering — billed per audio second. The allowance check asks for a 1-second floor, since the duration is not known until the clip is decoded or generated. On success,
zc-usagereportsmax(1, ceil(x-audio-duration-seconds))audio seconds. Stripe metering is bypassed; ZeroClick is the sole biller.
Authorizations
HMAC signature minted by ZeroClick over the raw request bytes, of the
form t=<unix-seconds>,kid=<key-id>,v1=<hex-hmac>. Verified by the
@zeroclickai/sellers SDK against the seller's signing secret keyed by
kid. A missing or invalid signature is rejected with 401
invalid_zeroclick_signature; this is never failed open.
Headers
ZeroClick request id, echoed in logs for correlation. Set by ZeroClick when it proxies the request.
"zcreq_1"
Identifier of the buying agent. Used to partition logs/analytics by agent; becomes the synthesized caller identity.
"agt_1"
Body
Multipart form, required for voice cloning.
The text to speak. Inline tags such as [laugh] and [cough] add paralinguistic cues.
1 - 2000"Testing model to generate voice. Hey how are you today?"
Model identifier. The endpoint serves chatterbox-nano.
chatterbox-nano "chatterbox-nano"
OpenAI voice names are accepted and all map to the built-in voice.
default, builtin, chatterbox, alloy, ash, ballad, cedar, coral, echo, fable, marin, nova, onyx, sage, shimmer, verse "default"
pcm is raw 16-bit little-endian mono at 24 kHz.
mp3, opus, aac, flac, wav, pcm "mp3"
Pins sampling for repeatable output (best-effort).
0 <= x <= 42949672951234
Sampling temperature.
0 <= x <= 2Nucleus sampling.
0 <= x <= 1Top-k sampling.
0 <= x <= 10000Penalty on repeated speech tokens.
1 <= x <= 4Reference clip to clone a voice from. Overrides voice. Not stored.
Response
The audio file, with a content type matching response_format. Includes the zc-usage header settling actual usage with ZeroClick.
The response is of type file.

