Skip to main content
Defined in: typescript/src/errors/RateLimitError.ts:13 Raised when the Runtime returns HTTP 429: the caller has exceeded the per-identity rate limit on POST /execute, or the IP-keyed limit on GET /health,/ready (see packages/api’s rate-limiting middleware). Distinct from every other 4xx this SDK maps — it is not a request defect, it is a transient condition the caller should back off and retry, so retryAfterSeconds (parsed from the response’s Retry-After header, when present) is exposed for callers that want to honor the Runtime’s own hint rather than guess a delay.

Extends

Constructors

Constructor

new RateLimitError(message, options?): RateLimitError
Defined in: typescript/src/errors/RateLimitError.ts:20

Parameters

message
string
options?
requestId?
string
cause?
unknown
retryAfterSeconds?
number

Returns

RateLimitError

Overrides

ParmanaError.constructor

Properties

code

readonly code: ErrorCode
Defined in: typescript/src/errors/ParmanaError.ts:61 Stable machine-readable error code.

Inherited from

ParmanaError.code

requestId?

readonly optional requestId?: string
Defined in: typescript/src/errors/ParmanaError.ts:66 Optional request identifier.

Inherited from

ParmanaError.requestId

cause?

readonly optional cause?: unknown
Defined in: typescript/src/errors/ParmanaError.ts:71 Optional underlying cause.

Inherited from

ParmanaError.cause

retryAfterSeconds?

readonly optional retryAfterSeconds?: number
Defined in: typescript/src/errors/RateLimitError.ts:18 Seconds to wait before retrying, taken from the response’s Retry-After header. Undefined when the Runtime didn’t send one.

stackTraceLimit

static stackTraceLimit: number
Defined in: node_modules/@types/node/globals.d.ts:68 The Error.stackTraceLimit property specifies the number of stack frames collected by a stack trace (whether generated by new Error().stack or Error.captureStackTrace(obj)). The default value is 10 but may be set to any valid JavaScript number. Changes will affect any stack trace captured after the value has been changed. If set to a non-number value, or set to a negative number, stack traces will not capture any frames.

Inherited from

ParmanaError.stackTraceLimit

name

name: string
Defined in: node_modules/typescript/lib/lib.es5.d.ts:1076

Inherited from

ParmanaError.name

message

message: string
Defined in: node_modules/typescript/lib/lib.es5.d.ts:1077

Inherited from

ParmanaError.message

stack?

optional stack?: string
Defined in: node_modules/typescript/lib/lib.es5.d.ts:1078

Inherited from

ParmanaError.stack

Methods

captureStackTrace()

static captureStackTrace(targetObject, constructorOpt?): void
Defined in: node_modules/@types/node/globals.d.ts:52 Creates a .stack property on targetObject, which when accessed returns a string representing the location in the code at which Error.captureStackTrace() was called.
The first line of the trace will be prefixed with ${myObject.name}: ${myObject.message}. The optional constructorOpt argument accepts a function. If given, all frames above constructorOpt, including constructorOpt, will be omitted from the generated stack trace. The constructorOpt argument is useful for hiding implementation details of error generation from the user. For instance:

Parameters

targetObject
object
constructorOpt?
Function

Returns

void

Inherited from

ParmanaError.captureStackTrace

prepareStackTrace()

static prepareStackTrace(err, stackTraces): any
Defined in: node_modules/@types/node/globals.d.ts:56

Parameters

err
Error
stackTraces
CallSite[]

Returns

any

See

https://v8.dev/docs/stack-trace-api#customizing-stack-traces

Inherited from

ParmanaError.prepareStackTrace