Endpoints

https://api.fourhz.ai

MethodPathAction
POST/v1/asr/hotword-poolsCreate
GET/v1/asr/hotword-pools?limit=100&offset=0List; optional query searches pool names
GET / PATCH / DELETE/v1/asr/hotword-pools/{pool_id}Inspect, update or delete

Authenticate with Authorization: YOUR_API_KEY. Pools belong to the API key's account; other accounts cannot inspect or use them. The retired /asr/v1/hotword-pools route is no longer available.

Create and update

FieldTypeDescription
namestringRequired when creating; cannot be cleared on update. Up to 100 characters after trimming spaces.
languagestringLanguage label: auto (default) or a valid language code of up to 10 characters; other values return 400.
wordsstring[]Up to 1,000 distinct words, 64 characters each. Leading/trailing whitespace, empty words and duplicates are removed. PATCH replaces the entire array.
is_enabledbooleanDefaults to true. Disabled pools cannot be selected for new requests.

Send words as a JSON array; there is no separate file-upload step. In Playground, use Manage beside the pool selector to create or edit a pool without leaving the page.

Use a pool

Take the id from the create/list response. Set hotword_pool_id="42" in the Live ASR query, synchronous config or pre-recorded request body. The ID is a positive integer, encoded as a string.

APIHub loads the complete enabled pool, merges it with request-local keyterms, deduplicates it and forwards a snapshot to AudioLLM. A 1,000-word pool remains fully available even though direct realtime/sync keyterms are limited to 100. Pre-recorded direct keyterms allow 1,000 words, each up to 50 characters; pool words retain their 64-character limit. Updates and deletion affect new requests; running requests keep their initial snapshot.

Standard ASR uses these terms for conservative post-recognition spelling correction, including when cleanup is off. Terms are hints, not forced insertions or a guarantee of recognition accuracy.

Examples

curl https://api.fourhz.ai/v1/asr/hotword-pools \
  -H "Authorization: $FOURHZ_API_KEY" \
  -H 'Content-Type: application/json' \
  -d '{"name":"Speech terminology","language":"en","words":["Voiceprint recognition","Speaker diarization"],"is_enabled":true}'

curl https://api.fourhz.ai/v1/asr/hotword-pools/42 \
  -X PATCH -H "Authorization: $FOURHZ_API_KEY" \
  -H 'Content-Type: application/json' -d '{"words":["Voiceprint recognition","Speaker diarization","Voice activity detection"]}'

curl https://api.fourhz.ai/v1/asr/hotword-pools/42 \
  -X DELETE -H "Authorization: $FOURHZ_API_KEY"

Response fields

{"code":"success","msg":"ok","id":42,"name":"Speech terminology","language":"en","words":["Voiceprint recognition","Speaker diarization"],"is_enabled":true,"upstream_ref":null,"created_at":"2026-10-20T00:00:00Z"}

Create, get and patch return the pool fields above. List returns a data array of pools. DELETE returns 204 with no body.

Errors

Every HTTP error body contains error_code (machine-readable) and message (human-readable). Historical fields such as detail, code/msg or an upstream error object are kept and status codes are unchanged. Clients should read error_code and message first.

400Invalid JSON, invalid words or size limits exceeded.
401Missing or invalid API key.
404Pool missing or owned by another account. ASR admission also returns 404 for disabled pools.
503Pool storage temporarily unavailable at ASR admission. Retry later; requested pools are never silently ignored.