/** * Gmail Node - Version 2.2 * Discriminator: resource=draft, operation=getAll */ interface Credentials { googleApi: CredentialReference; gmailOAuth2: CredentialReference; } export type GmailV22DraftGetAllParams = { resource: 'draft'; operation: 'getAll'; authentication?: 'oAuth2' | 'serviceAccount' | Expression; /** * Whether to return all results or only up to a given limit * @default false */ returnAll?: boolean | Expression; /** * Max number of results to return * @displayOptions.show { returnAll: [false] } * @default 50 */ limit?: number | Expression; /** * Options * @default {} */ options?: { /** Prefix for name of the binary property to which to write the attachments. An index starting with 0 will be added. So if name is 'attachment_' the first attachment is saved to 'attachment_0'. * @default attachment_ */ dataPropertyAttachmentsPrefixName?: string | Expression | PlaceholderValue; /** Whether the draft's attachments will be downloaded * @default false */ downloadAttachments?: boolean | Expression; /** Whether to include messages from SPAM and TRASH in the results * @default false */ includeSpamTrash?: boolean | Expression; }; }; export type GmailV22DraftGetAllOutput = { date?: string; from?: { html?: string; text?: string; value?: Array<{ address?: string; name?: string; }>; }; headers?: { 'content-transfer-encoding'?: string; 'content-type'?: string; date?: string; from?: string; 'message-id'?: string; 'mime-version'?: string; received?: string; subject?: string; to?: string; }; id?: string; labelIds?: Array; messageId?: string; sizeEstimate?: number; subject?: string; text?: string; textAsHtml?: string; threadId?: string; to?: { html?: string; text?: string; value?: Array<{ address?: string; name?: string; }>; }; }; export type GmailV22DraftGetAllNode = { type: 'n8n-nodes-base.gmail'; version: 2.2; credentials?: Credentials; config: NodeConfig; output?: Items; };