UNPKG

@visionfi/server-sdk

Version:

Server-side SDK for VisionFI API access using Google Service Account authentication

197 lines (196 loc) 4.46 kB
/** * DocuSign integration types for the VisionFi client. */ /** * Authentication status values for DocuSign integration. */ export type DocuSignAuthenticationStatus = 'authenticated' | 'unauthenticated' | 'expired' | 'failed'; /** * Connect webhook configuration for DocuSign integration. */ export interface DocuSignConnectWebhook { /** * Unique identifier for the webhook (typically a UUID) */ webhookGuid: string; /** * Secret key used to validate webhook payloads from DocuSign */ hmacSecret: string; /** * ID of the workflow associated with this webhook */ workflowId: string; /** * Creation timestamp */ createdAt?: string; /** * Last update timestamp */ updatedAt?: string; } /** * DocuSign configuration object. */ export interface DocuSignConfig { /** * DocuSign user ID (UUID format) */ userId: string; /** * DocuSign account ID (UUID format) */ accountId: string; /** * DocuSign REST API base URI */ baseUri: string; /** * Name for the integration */ name?: string; /** * Boolean to enable/disable the integration */ enabled?: boolean; /** * Current authentication status */ authenticationStatus?: DocuSignAuthenticationStatus; /** * ISO 8601 timestamp of last authentication */ lastAuthenticated?: string; /** * Connect webhook configurations */ connectConfigs?: DocuSignConnectWebhook[]; /** * Creation timestamp */ createdAt?: string; /** * Last update timestamp */ updatedAt?: string; } /** * Authentication status update payload. */ export interface DocuSignAuthStatusUpdate { /** * Authentication status */ authenticationStatus: DocuSignAuthenticationStatus; /** * ISO 8601 timestamp of authentication */ lastAuthenticated: string; } /** * Response for DocuSign configuration operations. */ export interface DocuSignConfigResponse { /** * Whether the request was successful */ success: boolean; /** * DocuSign configuration data, only present when success is true */ data?: DocuSignConfig; /** * Optional message, typically present when success is false */ message?: string; } /** * Response for DocuSign authentication status operations. */ export interface DocuSignAuthStatusResponse { /** * Whether the request was successful */ success: boolean; /** * Authentication status data, only present when success is true */ data?: { authenticationStatus: DocuSignAuthenticationStatus; lastAuthenticated: string; }; /** * Optional message, typically present when success is false */ message?: string; } /** * Response for DocuSign Connect webhook list operations. */ export interface DocuSignConnectWebhooksResponse { /** * Whether the request was successful */ success: boolean; /** * Array of webhook configurations, only present when success is true */ data?: DocuSignConnectWebhook[]; /** * Optional message, typically present when success is false */ message?: string; } /** * Response for single DocuSign Connect webhook operations. */ export interface DocuSignConnectWebhookResponse { /** * Whether the request was successful */ success: boolean; /** * Webhook configuration data, only present when success is true */ data?: DocuSignConnectWebhook; /** * Optional message, typically present when success is false */ message?: string; } /** * Response for DocuSign Connect webhook deletion. */ export interface DocuSignConnectWebhookDeleteResponse { /** * Whether the request was successful */ success: boolean; /** * Optional message */ message?: string; } /** * Response format for the DocuSign consent URL endpoint. */ export interface DocuSignConsentUrlResponse { /** * Whether the request was successful */ success: boolean; /** * Consent URL data, only present when success is true */ data?: { /** * The generated OAuth consent URL */ consentUrl: string; }; /** * Optional message, typically present when success is false */ message?: string; }