/** * Pipedrive Node - Version 1 * Discriminator: resource=deal, operation=create */ interface Credentials { pipedriveApi: CredentialReference; pipedriveOAuth2Api: CredentialReference; } /** Create an activity */ export type PipedriveV1DealCreateParams = { resource: 'deal'; operation: 'create'; authentication?: 'apiToken' | 'oAuth2' | Expression; /** * The title of the deal to create */ title?: string | Expression | PlaceholderValue; /** * Type of entity to link to this deal * @default organization */ associateWith?: 'organization' | 'person' | Expression; /** * ID of the organization this deal will be associated with * @displayOptions.show { associateWith: ["organization"] } * @default 0 */ org_id?: number | Expression; /** * ID of the person this deal will be associated with * @displayOptions.show { associateWith: ["person"] } * @default 0 */ person_id?: number | Expression; /** * Additional Fields * @default {} */ additionalFields?: { /** Currency of the deal. Accepts a 3-character currency code. Like EUR, USD, ... * @default USD */ currency?: string | Expression | PlaceholderValue; /** Adds a custom property to set also values which have not been predefined * @default {} */ customProperties?: { /** Property */ property?: Array<{ /** Name of the property to set. Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code/expressions/">expression</a>. */ name?: string | Expression; /** Value of the property to set */ value?: string | Expression | PlaceholderValue; }>; }; /** Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code/expressions/">expression</a> */ label?: string | Expression; /** Reason why the deal was lost */ lost_reason?: string | Expression | PlaceholderValue; /** ID of the organization this deal will be associated with * @displayOptions.show { /associateWith: ["person"] } * @default 0 */ org_id?: number | Expression; /** ID of the person this deal will be associated with * @displayOptions.show { /associateWith: ["organization"] } * @default 0 */ person_id?: number | Expression; /** Deal success probability percentage * @default 0 */ probability?: number | Expression; /** ID of the stage this deal will be placed in a pipeline. If omitted, the deal will be placed in the first stage of the default pipeline. (PIPELINE > STAGE). Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code/expressions/">expression</a>. */ stage_id?: string | Expression; /** The status of the deal. If not provided it will automatically be set to "open". * @default open */ status?: 'open' | 'won' | 'lost' | 'deleted' | Expression; /** ID of the active user whom the activity will be assigned to. If omitted, the activity will be assigned to the authorized user. Choose from the list, or specify an ID using an <a href="https://docs.n8n.io/code/expressions/">expression</a>. */ user_id?: string | Expression; /** Value of the deal. If not set it will automatically be set to 0. * @default 0 */ value?: number | Expression; /** Visibility of the deal. If omitted, visibility will be set to the default visibility setting of this item type for the authorized user. * @default 3 */ visible_to?: '1' | '3' | Expression; }; }; export type PipedriveV1DealCreateOutput = { active?: boolean; activities_count?: number; acv?: null; acv_currency?: null; add_time?: string; arr?: null; arr_currency?: null; cc_email?: string; creator_user_id?: { active_flag?: boolean; email?: string; has_pic?: number; id?: number; name?: string; value?: number; }; currency?: string; deleted?: boolean; done_activities_count?: number; email_messages_count?: number; expected_close_date?: null; files_count?: number; followers_count?: number; formatted_value?: string; formatted_weighted_value?: string; id?: number; last_activity_date?: null; last_activity_id?: null; last_incoming_mail_time?: null; last_outgoing_mail_time?: null; local_lost_date?: null; lost_reason?: null; lost_time?: null; mrr?: null; mrr_currency?: null; next_activity_date?: null; next_activity_duration?: null; next_activity_id?: null; next_activity_note?: null; next_activity_subject?: null; next_activity_time?: null; next_activity_type?: null; notes_count?: number; org_hidden?: boolean; origin?: string; owner_name?: string; participants_count?: number; person_hidden?: boolean; pipeline_id?: number; probability?: null; products_count?: number; stage_change_time?: null; stage_id?: number; stage_order_nr?: number; status?: string; title?: string; undone_activities_count?: number; update_time?: string; user_id?: { active_flag?: boolean; email?: string; has_pic?: number; id?: number; name?: string; value?: number; }; visible_to?: string; weighted_value_currency?: string; }; export type PipedriveV1DealCreateNode = { type: 'n8n-nodes-base.pipedrive'; version: 1; credentials?: Credentials; config: NodeConfig; output?: Items; };