NexusConfig is a frozen dataclass holding every value required to construct a client. Pass it to NexusClient.create() or AsyncNexusClient.create() (both accept the same instance).
Field reference
WIFConfig fields
Constructed with keyword arguments only. See Workload identity for the full picture.
WIFProvider, WIFProviderLiteral, WIFProviderLike, ExchangeContext, ExchangePayloadSource, ExchangeSource, TokenSource, TokenSourceResult and ExchangePayloadResult are all exported from westyx_nexus, so the callbacks the SDK asks for can be named and annotated.
API key types
Calling get_secret(...) with a public key raises NexusPublicKeyError synchronously, before the network call.
Where to keep the API key
Anywhere your existing config pipeline puts secrets - environment variables, AWS Secrets Manager, GCP Secret Manager, HashiCorp Vault, or a local .env file in dev. The SDK never logs the raw key.
For Pydantic / pydantic-settings users:
Choosing the TTL
The TTL is a tradeoff between staleness window and redundant network traffic. With SSE enabled (default), changes propagate in milliseconds regardless of the TTL - the TTL only matters as a safety net if the stream falls back.
Disabling SSE
Useful in environments where outbound long-lived connections are blocked (some serverless platforms, certain corporate proxies).