Skip to main content

Documentation Index

Fetch the complete documentation index at: https://docs.sf-voice.sh/llms.txt

Use this file to discover all available pages before exploring further.

The SDKs are open source at github.com/sf-voice/sf-voice-core. These docs cover SDK version 0.1.1. We are iterating quickly, so pin your SDK version and expect breaking changes between versions until the API settles. The SDKs cover the core operations: ingest, getTask, pollTask, listAssets, getAsset, deleteAsset, search. Method names follow the naming convention of each language.

TypeScript

@sf-voice/media — Node.js, Bun, Deno, browser

Python

sf-voice-media — sync and async clients

Elixir

:sf_voiceReq-based, returns {:ok, _} or {:error, _}

Go

sfvoice — idiomatic Go with context.Context

Rust

sf_voice_media — async with tokio, builder pattern

Java

com.sfvoice:sf-voice-media-java — synchronous, Java 17+

Kotlin

com.sfvoice:sf-voice-media-kotlin — coroutine-native with Ktor

C++

single header — std::future-based, CPR + nlohmann

Authentication

SDKs send your API key as the X-API-Key request header. Keep it in an environment variable and avoid committing it to source control.

Error handling

SDKs use three error categories:
ErrorWhen it’s thrown
API errorThe server returned a non-2xx response. Carries code, message, and status.
Request timeoutA single HTTP request exceeded the configured timeout.
Poll timeoutpollTask ran out of time before the task reached ready or failed.
Error codes from the API:
CodeMeaning
unauthorizedInvalid or missing API key.
not_foundAsset or task ID doesn’t exist.
bucket_not_connectedS3 source used before bucket is configured.
s3_access_deniedSDK can’t read from the specified S3 key.
unsupported_formatFile type isn’t supported for indexing.
file_too_largeUpload exceeds the size limit.
rate_limitedToo many requests. Back off and retry.