n8n/packages/nodes-base/nodes/PayPal/PaymentDescription.ts

422 lines
8.5 KiB
TypeScript
Raw Normal View History

2021-01-13 11:20:30 -08:00
import { INodeProperties } from 'n8n-workflow';
2019-11-23 16:36:47 -08:00
export const payoutOperations: INodeProperties[] = [
2019-11-23 16:36:47 -08:00
{
displayName: 'Operation',
name: 'operation',
type: 'options',
displayOptions: {
show: {
resource: [
'payout',
],
},
},
options: [
{
name: 'Create',
value: 'create',
description: 'Create a batch payout',
},
{
name: 'Get',
value: 'get',
description: 'Show batch payout details',
2019-11-26 08:59:27 -08:00
},
2019-11-23 16:36:47 -08:00
],
default: 'create',
description: 'The operation to perform.',
},
];
2019-11-23 16:36:47 -08:00
export const payoutFields: INodeProperties[] = [
2019-11-23 16:36:47 -08:00
/* -------------------------------------------------------------------------- */
/* payout:create */
/* -------------------------------------------------------------------------- */
{
displayName: 'Sender Batch ID',
name: 'senderBatchId',
type: 'string',
required: true,
displayOptions: {
show: {
resource: [
'payout',
],
operation: [
'create',
],
},
},
default: '',
description: 'A sender-specified ID number. Tracks the payout in an accounting system.',
},
{
displayName: 'JSON Parameters',
name: 'jsonParameters',
type: 'boolean',
default: false,
description: '',
displayOptions: {
show: {
resource: [
2020-10-22 06:46:03 -07:00
'payout',
2019-11-23 16:36:47 -08:00
],
operation: [
'create',
2020-10-22 06:46:03 -07:00
],
2019-11-23 16:36:47 -08:00
},
},
},
{
displayName: 'Items',
name: 'itemsUi',
placeholder: 'Add Item',
type: 'fixedCollection',
displayOptions: {
show: {
resource: [
'payout',
],
operation: [
'create',
],
jsonParameters: [
2020-10-22 06:46:03 -07:00
false,
],
2019-11-23 16:36:47 -08:00
},
},
typeOptions: {
multipleValues: true,
},
default: {},
options: [
{
name: 'itemsValues',
displayName: 'Item',
values: [
{
displayName: 'Recipient Type',
name: 'recipientType',
type: 'options',
options: [
{
name: 'Phone',
value: 'phone',
description: 'The unencrypted phone number',
},
{
name: 'Email',
value: 'email',
description: 'The unencrypted email.',
2019-11-23 16:36:47 -08:00
},
{
name: 'PayPal ID',
value: 'paypalId',
description: 'The encrypted PayPal account number.',
},
],
default: 'email',
description: 'The ID type that identifies the recipient of the payment.',
},
{
displayName: 'Receiver Value',
name: 'receiverValue',
type: 'string',
required: true,
default: '',
:zap: Remove unnessasry <br/> (#2340) * introduce analytics * add user survey backend * add user survey backend * set answers on survey submit Co-authored-by: Mutasem Aldmour <4711238+mutdmour@users.noreply.github.com> * change name to personalization * lint Co-authored-by: Mutasem Aldmour <4711238+mutdmour@users.noreply.github.com> * N8n 2495 add personalization modal (#2280) * update modals * add onboarding modal * implement questions * introduce analytics * simplify impl * implement survey handling * add personalized cateogry * update modal behavior * add thank you view * handle empty cases * rename modal * standarize modal names * update image, add tags to headings * remove unused file * remove unused interfaces * clean up footer spacing * introduce analytics * refactor to fix bug * update endpoint * set min height * update stories * update naming from questions to survey * remove spacing after core categories * fix bug in logic * sort nodes * rename types * merge with be * rename userSurvey * clean up rest api * use constants for keys * use survey keys * clean up types * move personalization to its own file Co-authored-by: ahsan-virani <ahsan.virani@gmail.com> * update parameter inputs to be multiline * update spacing * Survey new options (#2300) * split up options * fix quotes * remove unused import * refactor node credentials * add user created workflow event (#2301) * update multi params * simplify env vars * fix versionCli on FE * update personalization env * clean up node detail settings * fix event User opened Credentials panel * fix font sizes across modals * clean up input spacing * fix select modal spacing * increase spacing * fix input copy * fix webhook, tab spacing, retry button * fix button sizes * fix button size * add mini xlarge sizes * fix webhook spacing * fix nodes panel event * fix workflow id in workflow execute event * improve telemetry error logging * fix config and stop process events * add flush call on n8n stop * ready for release * fix input error highlighting * revert change * update toggle spacing * fix delete positioning * keep tooltip while focused * set strict size * increase left spacing * fix sort icons * remove unnessasry <br/> * remove unnessary break * remove unnessary margin * clean unused functionality * remove unnessary css * remove duplicate tracking * only show tooltip when hovering over label * remove extra space * add br * remove extra space * clean up commas * clean up commas * remove extra space * remove extra space * rewrite desc * add commas * add space * remove extra space * add space * add dot * update credentials section * use includes Co-authored-by: ahsan-virani <ahsan.virani@gmail.com> Co-authored-by: Jan Oberhauser <jan.oberhauser@gmail.com>
2021-10-27 13:00:13 -07:00
description: 'The receiver of the payment. Corresponds to the recipient_type value in the request. Max length: 127 characters.',
2019-11-23 16:36:47 -08:00
},
{
displayName: 'Currency',
name: 'currency',
type: 'options',
options: [
{
name: 'Australian dollar',
2020-10-22 06:46:03 -07:00
value: 'AUD',
2019-11-23 16:36:47 -08:00
},
{
name: 'Brazilian real',
2020-10-22 06:46:03 -07:00
value: 'BRL',
2019-11-23 16:36:47 -08:00
},
{
name: 'Canadian dollar',
2020-10-22 06:46:03 -07:00
value: 'CAD',
2019-11-23 16:36:47 -08:00
},
{
name: 'Czech koruna',
2020-10-22 06:46:03 -07:00
value: 'CZK',
2019-11-23 16:36:47 -08:00
},
{
name: 'Danish krone',
2020-10-22 06:46:03 -07:00
value: 'DKK',
2019-11-23 16:36:47 -08:00
},
{
name: 'Euro',
2020-10-22 06:46:03 -07:00
value: 'EUR',
2019-11-23 16:36:47 -08:00
},
{
name: 'United States dollar',
2020-10-22 06:46:03 -07:00
value: 'USD',
},
2019-11-23 16:36:47 -08:00
],
default: 'USD',
description: 'Currency',
},
{
displayName: 'Amount',
name: 'amount',
type: 'string',
required: true,
default: '',
description: 'The value, which might be',
},
{
displayName: 'Note',
name: 'note',
type: 'string',
required: false,
default: '',
:zap: Remove unnessasry <br/> (#2340) * introduce analytics * add user survey backend * add user survey backend * set answers on survey submit Co-authored-by: Mutasem Aldmour <4711238+mutdmour@users.noreply.github.com> * change name to personalization * lint Co-authored-by: Mutasem Aldmour <4711238+mutdmour@users.noreply.github.com> * N8n 2495 add personalization modal (#2280) * update modals * add onboarding modal * implement questions * introduce analytics * simplify impl * implement survey handling * add personalized cateogry * update modal behavior * add thank you view * handle empty cases * rename modal * standarize modal names * update image, add tags to headings * remove unused file * remove unused interfaces * clean up footer spacing * introduce analytics * refactor to fix bug * update endpoint * set min height * update stories * update naming from questions to survey * remove spacing after core categories * fix bug in logic * sort nodes * rename types * merge with be * rename userSurvey * clean up rest api * use constants for keys * use survey keys * clean up types * move personalization to its own file Co-authored-by: ahsan-virani <ahsan.virani@gmail.com> * update parameter inputs to be multiline * update spacing * Survey new options (#2300) * split up options * fix quotes * remove unused import * refactor node credentials * add user created workflow event (#2301) * update multi params * simplify env vars * fix versionCli on FE * update personalization env * clean up node detail settings * fix event User opened Credentials panel * fix font sizes across modals * clean up input spacing * fix select modal spacing * increase spacing * fix input copy * fix webhook, tab spacing, retry button * fix button sizes * fix button size * add mini xlarge sizes * fix webhook spacing * fix nodes panel event * fix workflow id in workflow execute event * improve telemetry error logging * fix config and stop process events * add flush call on n8n stop * ready for release * fix input error highlighting * revert change * update toggle spacing * fix delete positioning * keep tooltip while focused * set strict size * increase left spacing * fix sort icons * remove unnessasry <br/> * remove unnessary break * remove unnessary margin * clean unused functionality * remove unnessary css * remove duplicate tracking * only show tooltip when hovering over label * remove extra space * add br * remove extra space * clean up commas * clean up commas * remove extra space * remove extra space * rewrite desc * add commas * add space * remove extra space * add space * add dot * update credentials section * use includes Co-authored-by: ahsan-virani <ahsan.virani@gmail.com> Co-authored-by: Jan Oberhauser <jan.oberhauser@gmail.com>
2021-10-27 13:00:13 -07:00
description: 'The sender-specified note for notifications. Supports up to 4000 ASCII characters and 1000 non-ASCII characters.',
2019-11-23 16:36:47 -08:00
},
{
displayName: 'Sender Item ID',
name: 'senderItemId',
type: 'string',
default: '',
description: 'The sender-specified ID number. Tracks the payout in an accounting system.',
},
{
displayName: 'Recipient Wallet',
name: 'recipientWallet',
type: 'options',
options: [
{
name: 'PayPal',
value: 'paypal',
description: 'PayPal Wallet',
},
{
name: 'Venmo',
value: 'venmo',
description: 'Venmo Wallet',
},
],
default: 'paypal',
description: 'The recipient wallet',
},
2020-10-22 06:46:03 -07:00
],
2019-11-23 16:36:47 -08:00
},
],
},
{
displayName: 'Items',
name: 'itemsJson',
type: 'json',
default: '',
2019-11-23 16:36:47 -08:00
typeOptions: {
alwaysOpenEditWindow: true,
},
description: 'An array of individual payout items.',
displayOptions: {
show: {
resource: [
2020-10-22 06:46:03 -07:00
'payout',
2019-11-23 16:36:47 -08:00
],
operation: [
'create',
],
jsonParameters: [
true,
2020-10-22 06:46:03 -07:00
],
2019-11-23 16:36:47 -08:00
},
},
},
{
displayName: 'Additional Fields',
name: 'additionalFields',
type: 'collection',
placeholder: 'Add Field',
default: {},
displayOptions: {
show: {
resource: [
'payout',
],
operation: [
'create',
],
},
},
options: [
{
displayName: 'Email Subject',
name: 'emailSubject',
type: 'string',
default: '',
:zap: Remove unnessasry <br/> (#2340) * introduce analytics * add user survey backend * add user survey backend * set answers on survey submit Co-authored-by: Mutasem Aldmour <4711238+mutdmour@users.noreply.github.com> * change name to personalization * lint Co-authored-by: Mutasem Aldmour <4711238+mutdmour@users.noreply.github.com> * N8n 2495 add personalization modal (#2280) * update modals * add onboarding modal * implement questions * introduce analytics * simplify impl * implement survey handling * add personalized cateogry * update modal behavior * add thank you view * handle empty cases * rename modal * standarize modal names * update image, add tags to headings * remove unused file * remove unused interfaces * clean up footer spacing * introduce analytics * refactor to fix bug * update endpoint * set min height * update stories * update naming from questions to survey * remove spacing after core categories * fix bug in logic * sort nodes * rename types * merge with be * rename userSurvey * clean up rest api * use constants for keys * use survey keys * clean up types * move personalization to its own file Co-authored-by: ahsan-virani <ahsan.virani@gmail.com> * update parameter inputs to be multiline * update spacing * Survey new options (#2300) * split up options * fix quotes * remove unused import * refactor node credentials * add user created workflow event (#2301) * update multi params * simplify env vars * fix versionCli on FE * update personalization env * clean up node detail settings * fix event User opened Credentials panel * fix font sizes across modals * clean up input spacing * fix select modal spacing * increase spacing * fix input copy * fix webhook, tab spacing, retry button * fix button sizes * fix button size * add mini xlarge sizes * fix webhook spacing * fix nodes panel event * fix workflow id in workflow execute event * improve telemetry error logging * fix config and stop process events * add flush call on n8n stop * ready for release * fix input error highlighting * revert change * update toggle spacing * fix delete positioning * keep tooltip while focused * set strict size * increase left spacing * fix sort icons * remove unnessasry <br/> * remove unnessary break * remove unnessary margin * clean unused functionality * remove unnessary css * remove duplicate tracking * only show tooltip when hovering over label * remove extra space * add br * remove extra space * clean up commas * clean up commas * remove extra space * remove extra space * rewrite desc * add commas * add space * remove extra space * add space * add dot * update credentials section * use includes Co-authored-by: ahsan-virani <ahsan.virani@gmail.com> Co-authored-by: Jan Oberhauser <jan.oberhauser@gmail.com>
2021-10-27 13:00:13 -07:00
description: 'The subject line for the email that PayPal sends when payment for a payout item completes. The subject line is the same for all recipients. Max length: 255 characters.',
2019-11-23 16:36:47 -08:00
},
{
displayName: 'Email Message',
name: 'emailMessage',
type: 'string',
default: '',
:zap: Remove unnessasry <br/> (#2340) * introduce analytics * add user survey backend * add user survey backend * set answers on survey submit Co-authored-by: Mutasem Aldmour <4711238+mutdmour@users.noreply.github.com> * change name to personalization * lint Co-authored-by: Mutasem Aldmour <4711238+mutdmour@users.noreply.github.com> * N8n 2495 add personalization modal (#2280) * update modals * add onboarding modal * implement questions * introduce analytics * simplify impl * implement survey handling * add personalized cateogry * update modal behavior * add thank you view * handle empty cases * rename modal * standarize modal names * update image, add tags to headings * remove unused file * remove unused interfaces * clean up footer spacing * introduce analytics * refactor to fix bug * update endpoint * set min height * update stories * update naming from questions to survey * remove spacing after core categories * fix bug in logic * sort nodes * rename types * merge with be * rename userSurvey * clean up rest api * use constants for keys * use survey keys * clean up types * move personalization to its own file Co-authored-by: ahsan-virani <ahsan.virani@gmail.com> * update parameter inputs to be multiline * update spacing * Survey new options (#2300) * split up options * fix quotes * remove unused import * refactor node credentials * add user created workflow event (#2301) * update multi params * simplify env vars * fix versionCli on FE * update personalization env * clean up node detail settings * fix event User opened Credentials panel * fix font sizes across modals * clean up input spacing * fix select modal spacing * increase spacing * fix input copy * fix webhook, tab spacing, retry button * fix button sizes * fix button size * add mini xlarge sizes * fix webhook spacing * fix nodes panel event * fix workflow id in workflow execute event * improve telemetry error logging * fix config and stop process events * add flush call on n8n stop * ready for release * fix input error highlighting * revert change * update toggle spacing * fix delete positioning * keep tooltip while focused * set strict size * increase left spacing * fix sort icons * remove unnessasry <br/> * remove unnessary break * remove unnessary margin * clean unused functionality * remove unnessary css * remove duplicate tracking * only show tooltip when hovering over label * remove extra space * add br * remove extra space * clean up commas * clean up commas * remove extra space * remove extra space * rewrite desc * add commas * add space * remove extra space * add space * add dot * update credentials section * use includes Co-authored-by: ahsan-virani <ahsan.virani@gmail.com> Co-authored-by: Jan Oberhauser <jan.oberhauser@gmail.com>
2021-10-27 13:00:13 -07:00
description: 'The email message that PayPal sends when the payout item completes. The message is the same for all recipients.',
2019-11-23 16:36:47 -08:00
},
{
displayName: 'Note',
name: 'note',
type: 'string',
default: '',
description: 'The payouts and item-level notes are concatenated in the email. Max length: 1000 characters.',
2019-11-23 16:36:47 -08:00
},
],
},
/* -------------------------------------------------------------------------- */
/* payout:get */
/* -------------------------------------------------------------------------- */
2019-11-23 16:36:47 -08:00
{
displayName: 'Payout Batch Id',
name: 'payoutBatchId',
type: 'string',
default: '',
required: true,
displayOptions: {
show: {
resource: [
'payout',
],
operation: [
'get',
],
},
2019-11-23 16:36:47 -08:00
},
description: 'The ID of the payout for which to show details.',
2019-11-23 16:36:47 -08:00
},
{
displayName: 'Return All',
name: 'returnAll',
type: 'boolean',
default: false,
displayOptions: {
show: {
resource: [
'payout',
],
operation: [
'get',
],
},
2019-11-23 16:36:47 -08:00
},
description: 'If all results should be returned or only up to a given limit.',
2019-11-23 16:36:47 -08:00
},
{
displayName: 'Limit',
name: 'limit',
type: 'number',
typeOptions: {
maxValue: 1000,
2020-10-22 06:46:03 -07:00
minValue: 1,
},
default: 100,
displayOptions: {
show: {
resource: [
'payout',
],
operation: [
'get',
],
returnAll: [
false,
],
},
},
description: 'If all results should be returned or only up to a given limit.',
2019-11-23 16:36:47 -08:00
},
];
export const payoutItemOperations: INodeProperties[] = [
{
displayName: 'Operation',
name: 'operation',
type: 'options',
displayOptions: {
show: {
resource: [
'payoutItem',
],
},
2019-11-23 16:36:47 -08:00
},
options: [
{
name: 'Cancel',
value: 'cancel',
description: 'Cancels an unclaimed payout item',
},
{
name: 'Get',
value: 'get',
description: 'Show payout item details',
},
],
default: 'get',
description: 'The operation to perform.',
2019-11-23 16:36:47 -08:00
},
];
2019-11-26 08:59:27 -08:00
export const payoutItemFields: INodeProperties[] = [
/* -------------------------------------------------------------------------- */
/* payoutItem:get */
/* -------------------------------------------------------------------------- */
{
displayName: 'Payout Item Id',
name: 'payoutItemId',
type: 'string',
default: '',
required: true,
displayOptions: {
show: {
resource: [
'payoutItem',
],
operation: [
'get',
],
},
2019-11-26 08:59:27 -08:00
},
description: 'The ID of the payout item for which to show details.',
2019-11-26 08:59:27 -08:00
},
/* -------------------------------------------------------------------------- */
/* payoutItem:cancel */
/* -------------------------------------------------------------------------- */
2019-11-26 08:59:27 -08:00
{
displayName: 'Payout Item Id',
name: 'payoutItemId',
type: 'string',
default: '',
required: true,
displayOptions: {
show: {
resource: [
'payoutItem',
],
operation: [
'cancel',
],
},
2019-11-26 08:59:27 -08:00
},
description: 'The ID of the payout item to cancel.',
2019-11-26 08:59:27 -08:00
},
];