Skip to content

Rule.io SDK


Rule.io SDK / client/src / RuleClientConfig

Interface: RuleClientConfig

Defined in: client/src/config.ts:17

User-facing client configuration. All fields except apiKey have defaults.

Properties ​

apiKey ​

apiKey: string

Defined in: client/src/config.ts:18


baseUrlV2? ​

optional baseUrlV2?: string

Defined in: client/src/config.ts:20

Base URL for v2 API (default: https://app.rule.io/api/v2).


baseUrlV3? ​

optional baseUrlV3?: string

Defined in: client/src/config.ts:22

Base URL for v3 API (default: https://app.rule.io/api/v3).


debug? ​

optional debug?: boolean

Defined in: client/src/config.ts:26

Enable debug logging.


fetch? ​

optional fetch?: (input, init?) => Promise<Response>

Defined in: client/src/config.ts:24

Custom fetch implementation for testing.

Parameters ​

input ​

string | URL | Request

init? ​

RequestInit

Returns ​

Promise<Response>


rateLimiting? ​

optional rateLimiting?: RateLimitOptions

Defined in: client/src/config.ts:35

Opt-in client-side rate limiting. When present, every HTTP request is gated by a concurrency semaphore and retried on 429 according to the supplied options (server Retry-After is honored when available).

Omit to disable — the client fires requests with no concurrency cap and surfaces 429s directly to the caller.