Runtime configuration for the railsr client.
All values are read from Application.get_env(:railsr, ...) at startup and
validated via NimbleOptions. Keys can be overridden per-request by passing
opts to any resource function.
Keys
| Key | Type | Default | Description |
|---|---|---|---|
:client_id | string | required | Railsr OAuth 2.0 client ID |
:client_secret | string | required | Railsr OAuth 2.0 client secret |
| :environment | :play | :play_live | :live | :play | Target Railsr environment |
| :timeout | pos_integer | 30_000 | HTTP request timeout in ms |
| :max_retries | non_neg_integer | 3 | Max retry attempts on transient errors |
| :base_backoff_ms | pos_integer | 200 | Base backoff interval for retries |
| :telemetry_prefix | [atom] | [:railsr] | Telemetry event prefix |
| :pool_size | pos_integer | 10 | Finch connection pool size |
| :rate_limit_rps | pos_integer | 50 | Max requests per second |
Summary
Functions
Returns all validated config as a keyword list.
Returns the base URL for the configured (or overridden) environment.
Retrieves a single config value with an optional default.
Returns the OAuth token endpoint URL.
Validates application config at startup. Raises ArgumentError on invalid values.
Functions
@spec all() :: keyword()
Returns all validated config as a keyword list.
Returns the base URL for the configured (or overridden) environment.
Retrieves a single config value with an optional default.
Returns the OAuth token endpoint URL.
@spec validate!() :: :ok
Validates application config at startup. Raises ArgumentError on invalid values.