Skip to main content
Version: 1.4.2

Interface: RateLimiterConfig

Defined in: token-admin/types.ts:655

Rate limiter configuration for a remote chain.

Controls the inbound/outbound token flow rate for a specific remote chain. Set isEnabled: false with capacity: '0' and rate: '0' to disable.

Example

TypeScript
// Disabled rate limiter
const disabled: RateLimiterConfig = { isEnabled: false, capacity: '0', rate: '0' }

// Enabled: 100k tokens capacity, refilling at 167 tokens/sec (~10k/min)
const enabled: RateLimiterConfig = { isEnabled: true, capacity: '100000000000000000000000', rate: '167000000000000000000' }

Properties

capacity

capacity: string

Defined in: token-admin/types.ts:659

Maximum token capacity (bigint as string to avoid JS precision loss).


isEnabled

isEnabled: boolean

Defined in: token-admin/types.ts:657

Whether the rate limiter is enabled.


rate

rate: string

Defined in: token-admin/types.ts:661

Token refill rate per second (bigint as string).