UNPKG

cecon-interfaces

Version:
66 lines (65 loc) 1.67 kB
export interface IN8nChatApiCallback { callApi: boolean; callbackId: string; apiUrl: string; method: 'GET' | 'POST' | 'PUT' | 'PATCH' | 'DELETE'; headers: { authorization?: string; contentType?: string; userAgent?: string; customHeaders?: Record<string, string>; }; payload?: { userData?: { userId: string; name?: string; phone?: string; email?: string; }; formData?: Record<string, any>; contextData?: { sessionId: string; messageId: string; platform: string; timestamp: Date; }; customPayload?: any; }; requestConfig?: { timeout?: number; retryAttempts?: number; retryDelay?: number; validateSSL?: boolean; }; responseHandling?: { autoResponse: boolean; successMessage?: string; errorMessage?: string; responseTemplate?: string; }; metadata?: { action: string; description?: string; requiredFields?: string[]; workflow?: { workflowId: string; nodeId: string; stepName: string; }; }; conditions?: { requireAllFields?: boolean; customValidations?: Array<{ field: string; rule: 'required' | 'email' | 'phone' | 'date' | 'regex'; value?: string; message?: string; }>; }; webhook?: { url: string; method: 'POST' | 'PUT'; notifyOnSuccess?: boolean; notifyOnError?: boolean; }; }