Skip to main content
@ai-billing/narev
@ai-billing/narev / NarevApiError

Class: NarevApiError

Defined in: packages/narev/src/narev-client.ts:47 Error thrown when the Narev API returns a non-2xx response.

Extends

  • Error

Constructors

Constructor

new NarevApiError(message, status, body?): NarevApiError
Defined in: packages/narev/src/narev-client.ts:48

Parameters

message
string
status
number HTTP status code returned by the API.
body?
unknown Raw response body, if parsing succeeded.

Returns

NarevApiError

Overrides

Error.constructor

Properties

status

status: number
Defined in: packages/narev/src/narev-client.ts:51 HTTP status code returned by the API.

body?

optional body?: unknown
Defined in: packages/narev/src/narev-client.ts:53 Raw response body, if parsing succeeded.

cause?

optional cause?: unknown
Defined in: node_modules/.pnpm/typescript@5.9.3/node_modules/typescript/lib/lib.es2022.error.d.ts:26

Inherited from

Error.cause

name

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

Inherited from

Error.name

message

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

Inherited from

Error.message

stack?

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

Inherited from

Error.stack
Last modified on October 29, 2026