UNPKG

n8n-nodes-gohighlevel

Version:
40 lines (37 loc) 1.02 kB
// Main response type for returnFullResponse: true export type THttpFullResponse<T = any> = { body: T; // Response body (can be more specific based on your API) headers: IHeaders; // Response headers statusCode: number; // HTTP status code statusMessage: string; // Status message request: IHttpRequestOptions; // Original request details } // Headers interface interface IHeaders { [key: string]: string | string[] | undefined; } // Request options interface interface IHttpRequestOptions { url: string; method: HTTP_REQUEST_METHODS; body?: any; headers?: IHeaders; qs?: { [key: string]: string | number | boolean | null | undefined }; auth?: { username: string; password: string; }; encoding?: string; json?: boolean; timeout?: number; returnFullResponse?: boolean; } // HTTP methods enum type HTTP_REQUEST_METHODS = | 'GET' | 'POST' | 'PUT' | 'PATCH' | 'DELETE' | 'HEAD' | 'OPTIONS';