Skip to content

ModelThrottledError

Defined in: src/errors.ts:121

Error thrown when a model provider returns a throttling or rate limit error.

This error indicates that the model API has rate limited the request. Users can handle this error in hooks to implement custom retry strategies using the AfterModelCallEvent.retry mechanism.

new ModelThrottledError(message, options?): ModelThrottledError;

Defined in: src/errors.ts:128

Creates a new ModelThrottledError.

ParameterTypeDescription
messagestringError message describing the throttling condition
options?ErrorOptionsOptional error options including cause for error chaining

ModelThrottledError

ModelError.constructor