/** * Outbound webhook configuration + delivery history. * * GET /webhooks/projects/:id — config (all envs) * PATCH /webhooks/projects/:id — update one env's wiring * GET /webhooks/projects/:id/deliveries?... — paginated deliveries * POST /webhooks/:deliveryId/replay — replay a past delivery * * Webhook secrets are AES-256-GCM encrypted server-side (ADR Security §4) * and never surfaced to the client — `hasSecret` + `webhookSecretPrefix` * are the only fields exposed. */ import type { Client } from './client.js'; export interface WebhookAppInfo { readonly id: string; readonly name: string; readonly slug: string; } export interface WebhookEnvironment { readonly id: string; readonly name: string; readonly webhookUrl: string | null; readonly hasSecret: boolean; readonly updatedAt: string; } export interface WebhookConfig { readonly app: WebhookAppInfo; readonly environments: readonly WebhookEnvironment[]; readonly supportedEvents: readonly string[]; } export declare const getConfig: (client: Client, projectId: string) => Promise; export interface UpdateConfigInput { readonly environmentId: string; readonly webhookUrl?: string | null; readonly regenerateSecret?: boolean; } export interface UpdateConfigResult { readonly success: boolean; readonly webhookUrl: string | null; readonly secretGenerated: boolean; readonly webhookSecretPrefix?: string; } export declare const updateConfig: (client: Client, projectId: string, input: UpdateConfigInput) => Promise; export interface WebhookDelivery { readonly id: string; readonly event: string; readonly url: string; readonly status: string; readonly retryCount: number; readonly responseStatus: number | null; readonly error: string | null; readonly createdAt: string; readonly queuedAt: string | null; readonly deliveredAt: string | null; readonly failedAt: string | null; } export interface ListDeliveriesOptions { readonly status?: string; readonly event?: string; readonly environmentId?: string; readonly limit?: number; readonly offset?: number; } export interface ListDeliveriesResult { readonly deliveries: readonly WebhookDelivery[]; readonly total: number; readonly limit: number; readonly offset: number; } export declare const listDeliveries: (client: Client, projectId: string, options?: ListDeliveriesOptions) => Promise; export interface ReplayResult { readonly success: boolean; readonly newDeliveryId: string | null; readonly messageId: string | null; } export declare const replayDelivery: (client: Client, deliveryId: string) => Promise; //# sourceMappingURL=webhooks.d.ts.map