WebhookRuntimeService
Defined in: packages/webhook/src/runtime/webhook-runtime.service.ts:109
Implements
Section titled “Implements”Constructors
Section titled “Constructors”Constructor
Section titled “Constructor”new WebhookRuntimeService(
config):WebhookRuntimeService
Defined in: packages/webhook/src/runtime/webhook-runtime.service.ts:136
Parameters
Section titled “Parameters”config
Section titled “config”Returns
Section titled “Returns”WebhookRuntimeService
Methods
Section titled “Methods”addEndpoint()
Section titled “addEndpoint()”addEndpoint(
input):Promise<{active:boolean;createdAt:Date;description?:string;events:WebhookEventType[];filters?: {channelId?:string[];providerId?:string[];templateId?:string[]; };headers?:Record<string,string>;id:string;lastTriggeredAt?:Date;name?:string;retryConfig?: {backoffMultiplier:number;maxRetries:number;retryDelayMs:number; };secret?:string;secretUndecryptable?:true;status:"error"|"active"|"inactive"|"suspended";updatedAt:Date;url:string; }>
Defined in: packages/webhook/src/runtime/webhook-runtime.service.ts:163
Parameters
Section titled “Parameters”Returns
Section titled “Returns”Promise<{ active: boolean; createdAt: Date; description?: string; events: WebhookEventType[]; filters?: { channelId?: string[]; providerId?: string[]; templateId?: string[]; }; headers?: Record<string, string>; id: string; lastTriggeredAt?: Date; name?: string; retryConfig?: { backoffMultiplier: number; maxRetries: number; retryDelayMs: number; }; secret?: string; secretUndecryptable?: true; status: "error" | "active" | "inactive" | "suspended"; updatedAt: Date; url: string; }>
Implementation of
Section titled “Implementation of”addEndpoints()
Section titled “addEndpoints()”addEndpoints(
inputs):Promise<object[]>
Defined in: packages/webhook/src/runtime/webhook-runtime.service.ts:182
Parameters
Section titled “Parameters”inputs
Section titled “inputs”readonly WebhookEndpointInput[]
Returns
Section titled “Returns”Promise<object[]>
Implementation of
Section titled “Implementation of”emit()
Section titled “emit()”emit(
event):Promise<void>
Defined in: packages/webhook/src/runtime/webhook-runtime.service.ts:371
Parameters
Section titled “Parameters”Returns
Section titled “Returns”Promise<void>
Implementation of
Section titled “Implementation of”emitSync()
Section titled “emitSync()”emitSync(
event):Promise<object[]>
Defined in: packages/webhook/src/runtime/webhook-runtime.service.ts:395
Parameters
Section titled “Parameters”Returns
Section titled “Returns”Promise<object[]>
Implementation of
Section titled “Implementation of”flush()
Section titled “flush()”flush():
Promise<void>
Defined in: packages/webhook/src/runtime/webhook-runtime.service.ts:417
Returns
Section titled “Returns”Promise<void>
Implementation of
Section titled “Implementation of”getEndpoint()
Section titled “getEndpoint()”getEndpoint(
endpointId):Promise<{active:boolean;createdAt:Date;description?:string;events:WebhookEventType[];filters?: {channelId?:string[];providerId?:string[];templateId?:string[]; };headers?:Record<string,string>;id:string;lastTriggeredAt?:Date;name?:string;retryConfig?: {backoffMultiplier:number;maxRetries:number;retryDelayMs:number; };secret?:string;secretUndecryptable?:true;status:"error"|"active"|"inactive"|"suspended";updatedAt:Date;url:string; } |null>
Defined in: packages/webhook/src/runtime/webhook-runtime.service.ts:316
Parameters
Section titled “Parameters”endpointId
Section titled “endpointId”string
Returns
Section titled “Returns”Promise<{ active: boolean; createdAt: Date; description?: string; events: WebhookEventType[]; filters?: { channelId?: string[]; providerId?: string[]; templateId?: string[]; }; headers?: Record<string, string>; id: string; lastTriggeredAt?: Date; name?: string; retryConfig?: { backoffMultiplier: number; maxRetries: number; retryDelayMs: number; }; secret?: string; secretUndecryptable?: true; status: "error" | "active" | "inactive" | "suspended"; updatedAt: Date; url: string; } | null>
Implementation of
Section titled “Implementation of”listDeliveries()
Section titled “listDeliveries()”listDeliveries(
options?):Promise<object[]>
Defined in: packages/webhook/src/runtime/webhook-runtime.service.ts:429
Parameters
Section titled “Parameters”options?
Section titled “options?”WebhookDeliveryListOptions = {}
Returns
Section titled “Returns”Promise<object[]>
Implementation of
Section titled “Implementation of”listEndpoints()
Section titled “listEndpoints()”listEndpoints():
Promise<object[]>
Defined in: packages/webhook/src/runtime/webhook-runtime.service.ts:321
Returns
Section titled “Returns”Promise<object[]>
Implementation of
Section titled “Implementation of”migrateFieldCryptoToTenant()
Section titled “migrateFieldCryptoToTenant()”migrateFieldCryptoToTenant():
Promise<WebhookTenantMigrationResult>
Defined in: packages/webhook/src/runtime/webhook-runtime.service.ts:447
Re-encrypts stored endpoint secrets and delivery payloads written before
ciphertext was bound to fieldCrypto.tenantId, returning how many of
each it rewrote. Run it once every instance is upgraded, then remove
fieldCrypto.acceptLegacyAad if it was set to keep them readable in
the meantime. Endpoint writes through this runtime wait until it
finishes. See migrateWebhookFieldCryptoToTenant.
Returns
Section titled “Returns”Promise<WebhookTenantMigrationResult>
Implementation of
Section titled “Implementation of”WebhookRuntime.migrateFieldCryptoToTenant
probeEndpoint()
Section titled “probeEndpoint()”probeEndpoint(
input):Promise<WebhookTestResult>
Defined in: packages/webhook/src/runtime/webhook-runtime.service.ts:326
Parameters
Section titled “Parameters”string | WebhookRuntimeTestPayload
Returns
Section titled “Returns”Promise<WebhookTestResult>
Implementation of
Section titled “Implementation of”removeEndpoint()
Section titled “removeEndpoint()”removeEndpoint(
endpointId):Promise<void>
Defined in: packages/webhook/src/runtime/webhook-runtime.service.ts:309
Parameters
Section titled “Parameters”endpointId
Section titled “endpointId”string
Returns
Section titled “Returns”Promise<void>
Implementation of
Section titled “Implementation of”shutdown()
Section titled “shutdown()”shutdown():
Promise<void>
Defined in: packages/webhook/src/runtime/webhook-runtime.service.ts:457
Stops the batch timer, delivers the queued events, waits for endpoint writes already queued, and closes the persistence. Endpoint changes requested after it starts are rejected.
Returns
Section titled “Returns”Promise<void>
Implementation of
Section titled “Implementation of”updateEndpoint()
Section titled “updateEndpoint()”updateEndpoint(
endpointId,updates):Promise<{active:boolean;createdAt:Date;description?:string;events:WebhookEventType[];filters?: {channelId?:string[];providerId?:string[];templateId?:string[]; };headers?:Record<string,string>;id:string;lastTriggeredAt?:Date;name?:string;retryConfig?: {backoffMultiplier:number;maxRetries:number;retryDelayMs:number; };secret?:string;secretUndecryptable?:true;status:"error"|"active"|"inactive"|"suspended";updatedAt:Date;url:string; }>
Defined in: packages/webhook/src/runtime/webhook-runtime.service.ts:261
Parameters
Section titled “Parameters”endpointId
Section titled “endpointId”string
updates
Section titled “updates”Partial<WebhookEndpointInput>
Returns
Section titled “Returns”Promise<{ active: boolean; createdAt: Date; description?: string; events: WebhookEventType[]; filters?: { channelId?: string[]; providerId?: string[]; templateId?: string[]; }; headers?: Record<string, string>; id: string; lastTriggeredAt?: Date; name?: string; retryConfig?: { backoffMultiplier: number; maxRetries: number; retryDelayMs: number; }; secret?: string; secretUndecryptable?: true; status: "error" | "active" | "inactive" | "suspended"; updatedAt: Date; url: string; }>