n8n-nodes-base
Version:
Base nodes of n8n
143 lines (138 loc) • 4.46 kB
text/typescript
/**
* HubSpot Node - Version 2.1
* Discriminator: resource=contact, operation=getAll
*/
interface Credentials {
hubspotApi: CredentialReference;
hubspotAppToken: CredentialReference;
hubspotOAuth2Api: CredentialReference;
}
/** Get many contacts */
export type HubspotV21ContactGetAllParams = {
resource: 'contact';
operation: 'getAll';
authentication?: 'apiKey' | 'appToken' | 'oAuth2' | Expression<string>;
/**
* Whether to return all results or only up to a given limit
* @default false
*/
returnAll?: boolean | Expression<boolean>;
/**
* Max number of results to return
* @displayOptions.show { returnAll: [false] }
* @default 100
*/
limit?: number | Expression<number>;
/**
* Options
* @default {}
*/
additionalFields?: {
/** Specify which form submissions should be fetched
* @default all
*/
formSubmissionMode?: 'all' | 'none' | 'newest' | 'oldest' | Expression<string>;
/** Whether current list memberships should be fetched for the contact
* @default true
*/
listMemberships?: boolean | Expression<boolean>;
/** <p>Used to include specific contact properties in the results. By default, the results will only include Contact ID and will not include the values for any properties for your Contact.</p><p>Including this parameter will include the data for the specified property in the results. You can include this parameter multiple times to request multiple properties separated by a comma: <code>,</code>.</p>. Choose from the list, or specify IDs using an <a href="https://docs.n8n.io/code/expressions/">expression</a>.
* @default {}
*/
propertiesCollection?: {
/** Contact Properties to Include
*/
propertiesValues?: {
/** Whether to include specific Contact properties in the returned results. Choose from a list, or specify IDs using an <a href="https://docs.n8n.io/code/expressions/">expression</a>. Choose from the list, or specify IDs using an <a href="https://docs.n8n.io/code/expressions/">expression</a>.
* @default []
*/
properties?: string[];
/** Specify if the current value for a property should be fetched, or the value and all the historical values for that property
* @default valueAndHistory
*/
propertyMode?: 'valueAndHistory' | 'valueOnly' | Expression<string>;
};
};
};
};
export type HubspotV21ContactGetAllOutput = {
addedAt?: number;
'canonical-vid'?: number;
'form-submissions'?: Array<{
'contact-associated-by'?: Array<string>;
'conversion-id'?: string;
'form-id'?: string;
'form-type'?: string;
'page-title'?: string;
'page-url'?: string;
'portal-id'?: number;
timestamp?: number;
title?: string;
}>;
'identity-profiles'?: Array<{
'deleted-changed-timestamp'?: number;
identities?: Array<{
'is-primary'?: boolean;
timestamp?: number;
type?: string;
value?: string;
}>;
'saved-at-timestamp'?: number;
vid?: number;
}>;
'is-contact'?: boolean;
'merge-audits'?: Array<{
'canonical-vid'?: number;
'entity-id'?: string;
'first-name'?: string;
'is-reverted'?: boolean;
'last-name'?: string;
merged_from_email?: {
'data-sensitivity'?: null;
'is-encrypted'?: null;
selected?: boolean;
'source-id'?: string;
'source-label'?: null;
'source-type'?: string;
timestamp?: number;
value?: string;
};
merged_to_email?: {
'data-sensitivity'?: null;
'is-encrypted'?: null;
selected?: boolean;
'source-id'?: string;
'source-label'?: null;
'source-type'?: string;
timestamp?: number;
'updated-by-user-id'?: null;
value?: string;
};
'num-properties-moved'?: number;
'primary-vid-to-merge'?: number;
timestamp?: number;
'user-id'?: number;
'vid-to-merge'?: number;
}>;
'merged-vids'?: Array<number>;
'portal-id'?: number;
properties?: {
firstname?: {
value?: string;
};
lastmodifieddate?: {
value?: string;
};
lastname?: {
value?: string;
};
};
vid?: number;
};
export type HubspotV21ContactGetAllNode = {
type: 'n8n-nodes-base.hubspot';
version: 2.1;
credentials?: Credentials;
config: NodeConfig<HubspotV21ContactGetAllParams>;
output?: Items<HubspotV21ContactGetAllOutput>;
};