OptionalaccessStatic bearer access token or a provider function that returns one.
Mutually exclusive with apiKey.
OptionalaccountTarget organization account ID. Sent as X-Account-Id header.
Overrides the profile's sso_account_id when using SSO auth.
OptionalallowPermit an apiVersion this release was not built against.
Off by default. A newer API version can change response shapes, and this client would decode them incorrectly rather than reject them — a request-side mistake answers 422, but a reshaped response just mis-decodes, silently. Prefer upgrading the package.
OptionalapiAPI key used for authentication. Defaults to process.env.SECLAI_API_KEY when available.
OptionalapiHeader name to use for the API key. Defaults to x-api-key.
OptionalapiDated API version (YYYY-MM-DD) sent as the Seclai-Version header, opting
this client into backward-incompatible API changes released on or before
that date.
Left unset the header is omitted and the account's pinned baseline applies, so responses keep their current shapes and upgrading the SDK alone never changes the wire contract. Pin the account instead with Seclai.updateApiVersion, and read what a request resolves to with Seclai.getApiVersion.
From 2026-07-27 the API rejects undeclared query parameters with a 422
rather than ignoring them, and list endpoints return the canonical
{data, pagination} envelope.
OptionalautoWhether to auto-refresh expired SSO tokens. Defaults to true.
Set to false in environments that should not write to disk.
OptionalbaseAPI base URL. Defaults to process.env.SECLAI_API_URL when available, else SECLAI_API_URL.
OptionalconfigOverride the config directory path (default: SECLAI_CONFIG_DIR env var or ~/.seclai/).
OptionaldefaultExtra headers to include on every request.
OptionalfetchOptional fetch implementation for environments without a global fetch.
OptionalprofileSSO profile name to load from ~/.seclai/config.
Defaults to process.env.SECLAI_PROFILE, then "default".
Configuration for the Seclai client.