fase(16): integrations module

This commit is contained in:
Claude
2026-03-06 07:22:00 -05:00
committed by debian
parent cffa1aeea9
commit 1f1678af17
49 changed files with 2558 additions and 13 deletions

View File

@@ -214,6 +214,34 @@ export interface ReportTable {
completed_at: number | null;
}
export interface IntegrationTable {
id: string;
name: string;
type: string;
enabled: number;
config_json: string;
created_at: number;
}
export interface WebhookEndpointTable {
id: string;
url: string;
secret: string;
enabled: number;
created_at: number;
last_delivered_at: number | null;
last_status: number | null;
}
export interface WebhookDeliveryTable {
id: string;
endpoint_id: string;
event: string;
payload_json: string;
status: number;
attempted_at: number;
}
export interface Database {
sessions: SessionTable;
states: StateTable;
@@ -232,6 +260,9 @@ export interface Database {
api_keys: ApiKeyTable;
auth_sessions: AuthSessionTable;
reports: ReportTable;
integrations: IntegrationTable;
webhook_endpoints: WebhookEndpointTable;
webhook_deliveries: WebhookDeliveryTable;
}
export function createDatabase(config: { driver: string; path: string; url?: string }): Kysely<Database> {