Error Classes
Stripe402Error
Stripe402Errorimport type { PaymentErrorCode } from './types'
export class Stripe402Error extends Error {
public readonly code: PaymentErrorCode
constructor(code: PaymentErrorCode, message: string) {
super(message)
this.name = 'Stripe402Error'
this.code = code
}
}Constructor
new Stripe402Error(code: PaymentErrorCode, message: string)Parameter
Type
Description
Properties
Property
Type
Description
Example
Usage in the Middleware
Last updated