Skip to main content
All BlindCast libraries return Result<T, E> instead of throwing exceptions. When .ok is false, .error has a code (a string literal) and a message (human-readable description). The CLI uses Unix exit codes instead — see CLI Error Codes below. See Result Type Pattern for how to consume results.

Player — PlayerErrorCode

Uploader — UploaderErrorCode

Key Server — KeyErrorCode

These codes are returned by the key server’s internal derivation logic. The HTTP layer maps them to status codes (400, 401, 403, 500).

Crypto (internal) — CryptoErrorCode

These codes come from @blindcast/crypto, which is used internally by the player, uploader, and key server. You’ll see them if you use the crypto package directly.

CLI exit codes

The CLI uses Unix exit codes, not Result types: Use --json to get structured JSON errors on stderr: