Skip to main content

Client options

Per-request options

Every request method accepts options for that call only, as its last argument: { signal, timeout, maxRetries, headers }.

Raw responses

withRawResponse has the same methods and returns the HTTP response along with the result:

Logging

Set FINESSE_LOG=debug to log every request (method, URL, status, timing, request ID), or FINESSE_LOG=info to log only retries. The SDK never logs your API key, request bodies or audio. You can also set logLevel on the client, and pass logger to send the lines somewhere other than console.

Copy a client with other defaults

The copy shares the original client’s connections.

Custom HTTP client

Identify your integration

Requests identify the SDK with an X-Finesse-Client header. If you build an integration on top of the SDK, name it so it shows up in your usage analytics: