@heines/n8n-nodes-pax8 0.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +53 -0
- package/dist/credentials/Pax8ApiToken.credentials.d.ts +7 -0
- package/dist/credentials/Pax8ApiToken.credentials.js +29 -0
- package/dist/credentials/Pax8OAuth2Api.credentials.d.ts +8 -0
- package/dist/credentials/Pax8OAuth2Api.credentials.js +63 -0
- package/dist/index.d.ts +3 -0
- package/dist/index.js +19 -0
- package/dist/nodes/Pax8/Pax8.node.d.ts +37 -0
- package/dist/nodes/Pax8/Pax8.node.js +3198 -0
- package/package.json +47 -0
|
@@ -0,0 +1,3198 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.Pax8 = void 0;
|
|
4
|
+
const OP_DEFS = {
|
|
5
|
+
'createAccessToken': { resource: 'accessToken', method: 'POST', path: '/token', params: [], hasBody: true },
|
|
6
|
+
'createCompany': { resource: 'companies', method: 'POST', path: '/companies', params: [], hasBody: true },
|
|
7
|
+
'get_companies_companyId': { resource: 'companies', method: 'GET', path: '/companies/{companyId}', params: [{ name: 'companyId', in: 'path', required: true }], hasBody: false },
|
|
8
|
+
'findCompanies': { resource: 'companies', method: 'GET', path: '/companies', params: [{ name: 'page', in: 'query', required: false }, { name: 'size', in: 'query', required: false }, { name: 'sort', in: 'query', required: false }, { name: 'city', in: 'query', required: false }, { name: 'country', in: 'query', required: false }, { name: 'stateOrProvince', in: 'query', required: false }, { name: 'postalCode', in: 'query', required: false }, { name: 'selfServiceAllowed', in: 'query', required: false }, { name: 'billOnBehalfOfEnabled', in: 'query', required: false }, { name: 'orderApprovalRequired', in: 'query', required: false }, { name: 'status', in: 'query', required: false }], hasBody: false },
|
|
9
|
+
'updateCompany': { resource: 'companies', method: 'PATCH', path: '/companies/{companyId}', params: [{ name: 'companyId', in: 'path', required: true }], hasBody: true },
|
|
10
|
+
'post_companies_companyId_contacts': { resource: 'contacts', method: 'POST', path: '/companies/{companyId}/contacts', params: [{ name: 'companyId', in: 'path', required: true }], hasBody: true },
|
|
11
|
+
'delete_companies_companyId_contacts_contactId': { resource: 'contacts', method: 'DELETE', path: '/companies/{companyId}/contacts/{contactId}', params: [{ name: 'companyId', in: 'path', required: true }, { name: 'contactId', in: 'path', required: true }], hasBody: false },
|
|
12
|
+
'get_companies_companyId_contacts_contactId': { resource: 'contacts', method: 'GET', path: '/companies/{companyId}/contacts/{contactId}', params: [{ name: 'companyId', in: 'path', required: true }, { name: 'contactId', in: 'path', required: true }], hasBody: false },
|
|
13
|
+
'get_companies_companyId_contacts': { resource: 'contacts', method: 'GET', path: '/companies/{companyId}/contacts', params: [{ name: 'page', in: 'query', required: false }, { name: 'size', in: 'query', required: false }, { name: 'companyId', in: 'path', required: true }], hasBody: false },
|
|
14
|
+
'put_companies_companyId_contacts_contactId': { resource: 'contacts', method: 'PUT', path: '/companies/{companyId}/contacts/{contactId}', params: [{ name: 'companyId', in: 'path', required: true }, { name: 'contactId', in: 'path', required: true }], hasBody: true },
|
|
15
|
+
'getPartnerInvoice': { resource: 'invoices', method: 'GET', path: '/invoices/{invoiceId}', params: [{ name: 'invoiceId', in: 'path', required: true }], hasBody: false },
|
|
16
|
+
'findPartnerDraftInvoiceItems': { resource: 'invoices', method: 'GET', path: '/invoices/draftItems', params: [{ name: 'page', in: 'query', required: false }, { name: 'size', in: 'query', required: false }, { name: 'monthOffset', in: 'query', required: false }, { name: 'companyId', in: 'query', required: false }], hasBody: false },
|
|
17
|
+
'findPartnerInvoiceItems': { resource: 'invoices', method: 'GET', path: '/invoices/{invoiceId}/items', params: [{ name: 'invoiceId', in: 'path', required: true }, { name: 'page', in: 'query', required: false }, { name: 'size', in: 'query', required: false }], hasBody: false },
|
|
18
|
+
'findPartnerInvoices': { resource: 'invoices', method: 'GET', path: '/invoices', params: [{ name: 'page', in: 'query', required: false }, { name: 'size', in: 'query', required: false }, { name: 'sort', in: 'query', required: false }, { name: 'status', in: 'query', required: false }, { name: 'invoiceDate', in: 'query', required: false }, { name: 'invoiceDateRangeStart', in: 'query', required: false }, { name: 'invoiceDateRangeEnd', in: 'query', required: false }, { name: 'dueDate', in: 'query', required: false }, { name: 'total', in: 'query', required: false }, { name: 'balance', in: 'query', required: false }, { name: 'carriedBalance', in: 'query', required: false }, { name: 'companyId', in: 'query', required: false }], hasBody: false },
|
|
19
|
+
'addQuoteAttachmentsToLibrary': { resource: 'libraryAttachments', method: 'POST', path: '/v2/quote-attachments/shared', params: [], hasBody: true },
|
|
20
|
+
'deleteSingleLibraryAttachment': { resource: 'libraryAttachments', method: 'DELETE', path: '/v2/quote-attachments/{attachmentId}', params: [{ name: 'attachmentId', in: 'path', required: true }], hasBody: false },
|
|
21
|
+
'getLibraryAttachmentMetadata': { resource: 'libraryAttachments', method: 'GET', path: '/v2/quote-attachments/{attachmentId}', params: [{ name: 'attachmentId', in: 'path', required: true }, { name: 'download', in: 'query', required: false }], hasBody: false },
|
|
22
|
+
'getLibraryAttachmentsMetadata': { resource: 'libraryAttachments', method: 'GET', path: '/v2/quote-attachments', params: [], hasBody: false },
|
|
23
|
+
'replaceLibraryAttachment': { resource: 'libraryAttachments', method: 'PATCH', path: '/v2/quote-attachments/{attachmentId}', params: [{ name: 'attachmentId', in: 'path', required: true }], hasBody: true },
|
|
24
|
+
'updateLibraryAttachments': { resource: 'libraryAttachments', method: 'PUT', path: '/v2/quote-attachments', params: [], hasBody: true },
|
|
25
|
+
'uploadAttachmentToLibrary': { resource: 'libraryAttachments', method: 'POST', path: '/v2/quote-attachments', params: [], hasBody: true },
|
|
26
|
+
'createOrder': { resource: 'orders', method: 'POST', path: '/orders', params: [{ name: 'isMock', in: 'query', required: false }], hasBody: true },
|
|
27
|
+
'findOrdersByOrderId': { resource: 'orders', method: 'GET', path: '/orders/{orderId}', params: [{ name: 'orderId', in: 'path', required: true }], hasBody: false },
|
|
28
|
+
'findOrders': { resource: 'orders', method: 'GET', path: '/orders', params: [{ name: 'page', in: 'query', required: false }, { name: 'size', in: 'query', required: false }, { name: 'companyId', in: 'query', required: false }], hasBody: false },
|
|
29
|
+
'deletePreferenceAttachment': { resource: 'preferenceAttachments', method: 'DELETE', path: '/v2/quote-preferences/attachments/{attachmentId}', params: [{ name: 'attachmentId', in: 'path', required: true }], hasBody: false },
|
|
30
|
+
'uploadPreferencesAttachments': { resource: 'preferenceAttachments', method: 'POST', path: '/v2/quote-preferences/attachments', params: [], hasBody: true },
|
|
31
|
+
'findPricingByProductId': { resource: 'products', method: 'GET', path: '/products/{productId}/pricing', params: [{ name: 'productId', in: 'path', required: true }, { name: 'companyId', in: 'query', required: false }], hasBody: false },
|
|
32
|
+
'findProductByProductId': { resource: 'products', method: 'GET', path: '/products/{productId}', params: [{ name: 'productId', in: 'path', required: true }], hasBody: false },
|
|
33
|
+
'findProductDependenciesByProductId': { resource: 'products', method: 'GET', path: '/products/{productId}/dependencies', params: [{ name: 'productId', in: 'path', required: true }], hasBody: false },
|
|
34
|
+
'findProvisionDetailsByProductId': { resource: 'products', method: 'GET', path: '/products/{productId}/provision-details', params: [{ name: 'productId', in: 'path', required: true }], hasBody: false },
|
|
35
|
+
'findAllProducts': { resource: 'products', method: 'GET', path: '/products', params: [{ name: 'page', in: 'query', required: false }, { name: 'size', in: 'query', required: false }, { name: 'sort', in: 'query', required: false }, { name: 'search', in: 'query', required: false }, { name: 'vendorName', in: 'query', required: false }], hasBody: false },
|
|
36
|
+
'createAttemptForRequest': { resource: 'provisionAttempts', method: 'POST', path: '/provision-requests/{provisionRequestId}/attempts', params: [{ name: 'provisionRequestId', in: 'path', required: true }], hasBody: false },
|
|
37
|
+
'getAllProvisionAttempts': { resource: 'provisionAttempts', method: 'GET', path: '/provision-requests/{provisionRequestId}/attempts', params: [{ name: 'provisionRequestId', in: 'path', required: true }, { name: 'provisionDetailId', in: 'query', required: false }], hasBody: false },
|
|
38
|
+
'getLatestProvisionAttempt': { resource: 'provisionAttempts', method: 'GET', path: '/provision-requests/{provisionRequestId}/attempts/latest', params: [{ name: 'provisionRequestId', in: 'path', required: true }], hasBody: false },
|
|
39
|
+
'getOneProvisionAttempt': { resource: 'provisionAttempts', method: 'GET', path: '/provision-requests/{provisionRequestId}/attempts/{provisionAttemptId}', params: [{ name: 'provisionRequestId', in: 'path', required: true }, { name: 'provisionAttemptId', in: 'path', required: true }], hasBody: false },
|
|
40
|
+
'getAllProvisionDetails': { resource: 'provisionDetails', method: 'GET', path: '/provision-requests/{provisionRequestId}/details', params: [{ name: 'provisionRequestId', in: 'path', required: true }], hasBody: false },
|
|
41
|
+
'getLatestProvisionDetail': { resource: 'provisionDetails', method: 'GET', path: '/provision-requests/{provisionRequestId}/details/latest', params: [{ name: 'provisionRequestId', in: 'path', required: true }], hasBody: false },
|
|
42
|
+
'getOneProvisionDetail': { resource: 'provisionDetails', method: 'GET', path: '/provision-requests/{provisionRequestId}/details/{provisionDetailId}', params: [{ name: 'provisionRequestId', in: 'path', required: true }, { name: 'provisionDetailId', in: 'path', required: true }], hasBody: false },
|
|
43
|
+
'getAllProvisionRequests': { resource: 'provisionRequests', method: 'GET', path: '/provision-requests', params: [], hasBody: false },
|
|
44
|
+
'getAllUnfulfilledProvisionRequests': { resource: 'provisionRequests', method: 'GET', path: '/provision-requests/unfulfilled', params: [], hasBody: false },
|
|
45
|
+
'getOneProvisionRequest': { resource: 'provisionRequests', method: 'GET', path: '/provision-requests/{provisionRequestId}', params: [{ name: 'provisionRequestId', in: 'path', required: true }], hasBody: false },
|
|
46
|
+
'createProvisionResult': { resource: 'provisionResults', method: 'POST', path: '/provision-requests/{provisionRequestId}/results', params: [{ name: 'provisionRequestId', in: 'path', required: true }], hasBody: true },
|
|
47
|
+
'getAllProvisionResults': { resource: 'provisionResults', method: 'GET', path: '/provision-requests/{provisionRequestId}/results', params: [{ name: 'provisionRequestId', in: 'path', required: true }, { name: 'provisionAttemptId', in: 'query', required: false }], hasBody: false },
|
|
48
|
+
'getLatestProvisionResult': { resource: 'provisionResults', method: 'GET', path: '/provision-requests/{provisionRequestId}/results/latest', params: [{ name: 'provisionRequestId', in: 'path', required: true }], hasBody: false },
|
|
49
|
+
'getOneProvisionResult': { resource: 'provisionResults', method: 'GET', path: '/provision-requests/{provisionRequestId}/results/{provisionResultId}', params: [{ name: 'provisionRequestId', in: 'path', required: true }, { name: 'provisionResultId', in: 'path', required: true }], hasBody: false },
|
|
50
|
+
'createWebhookForProvisioner': { resource: 'provisioners', method: 'POST', path: '/provisioners/{provisionerId}/webhooks', params: [{ name: 'provisionerId', in: 'path', required: true }], hasBody: true },
|
|
51
|
+
'getAllProvisioners': { resource: 'provisioners', method: 'GET', path: '/provisioners', params: [], hasBody: false },
|
|
52
|
+
'getAllWebhooksForProvisioner': { resource: 'provisioners', method: 'GET', path: '/provisioners/{provisionerId}/webhooks', params: [{ name: 'provisionerId', in: 'path', required: true }], hasBody: false },
|
|
53
|
+
'getLatestWebhookForProvisioner': { resource: 'provisioners', method: 'GET', path: '/provisioners/{provisionerId}/webhooks/latest', params: [{ name: 'provisionerId', in: 'path', required: true }], hasBody: false },
|
|
54
|
+
'getOneProvisioner': { resource: 'provisioners', method: 'GET', path: '/provisioners/{provisionerId}', params: [{ name: 'provisionerId', in: 'path', required: true }], hasBody: false },
|
|
55
|
+
'getOneWebhookForProvisioner': { resource: 'provisioners', method: 'GET', path: '/provisioners/{provisionerId}/webhooks/{webhookId}', params: [{ name: 'provisionerId', in: 'path', required: true }, { name: 'webhookId', in: 'path', required: true }], hasBody: false },
|
|
56
|
+
'createOrderEvent': { resource: 'provisioningSimulations', method: 'POST', path: '/provision-simulations/order-events', params: [], hasBody: true },
|
|
57
|
+
'addQuoteAccessListEntry': { resource: 'quoteAccessList', method: 'POST', path: '/v2/quotes/{quoteId}/access-list', params: [{ name: 'quoteId', in: 'path', required: true }], hasBody: true },
|
|
58
|
+
'deleteQuoteShareEntry': { resource: 'quoteAccessList', method: 'DELETE', path: '/v2/quotes/{quoteId}/access-list/{accessListEntryId}', params: [{ name: 'quoteId', in: 'path', required: true }, { name: 'accessListEntryId', in: 'path', required: true }], hasBody: false },
|
|
59
|
+
'getQuoteAccessList': { resource: 'quoteAccessList', method: 'GET', path: '/v2/quotes/{quoteId}/access-list', params: [{ name: 'quoteId', in: 'path', required: true }], hasBody: false },
|
|
60
|
+
'copyAttachmentsToQuoteFromLibrary': { resource: 'quoteAttachments', method: 'POST', path: '/v2/quotes/{quoteId}/attachments/shared', params: [{ name: 'quoteId', in: 'path', required: true }], hasBody: true },
|
|
61
|
+
'deleteAttachment': { resource: 'quoteAttachments', method: 'DELETE', path: '/v2/quotes/{quoteId}/attachments/{attachmentId}', params: [{ name: 'quoteId', in: 'path', required: true }, { name: 'attachmentId', in: 'path', required: true }], hasBody: false },
|
|
62
|
+
'downloadAllAttachmentsAsZip': { resource: 'quoteAttachments', method: 'GET', path: '/v2/quotes/{quoteId}/attachments', params: [{ name: 'downloadZip', in: 'query', required: false }, { name: 'quoteId', in: 'path', required: true }], hasBody: false },
|
|
63
|
+
'getAttachmentMetadata': { resource: 'quoteAttachments', method: 'GET', path: '/v2/quotes/{quoteId}/attachments/{attachmentId}', params: [{ name: 'quoteId', in: 'path', required: true }, { name: 'attachmentId', in: 'path', required: true }, { name: 'download', in: 'query', required: false }], hasBody: false },
|
|
64
|
+
'updateAttachmentsMetadata': { resource: 'quoteAttachments', method: 'PUT', path: '/v2/quotes/{quoteId}/attachments', params: [{ name: 'quoteId', in: 'path', required: true }], hasBody: true },
|
|
65
|
+
'uploadAttachmentToQuote': { resource: 'quoteAttachments', method: 'POST', path: '/v2/quotes/{quoteId}/attachments', params: [{ name: 'quoteId', in: 'path', required: true }], hasBody: true },
|
|
66
|
+
'addLineItems': { resource: 'quoteLineItems', method: 'POST', path: '/v2/quotes/{quoteId}/line-items', params: [{ name: 'quoteId', in: 'path', required: true }], hasBody: true },
|
|
67
|
+
'deleteLineItemById': { resource: 'quoteLineItems', method: 'DELETE', path: '/v2/quotes/{quoteId}/line-items/{lineItemId}', params: [{ name: 'quoteId', in: 'path', required: true }, { name: 'lineItemId', in: 'path', required: true }], hasBody: false },
|
|
68
|
+
'bulkDeleteLineItems': { resource: 'quoteLineItems', method: 'POST', path: '/v2/quotes/{quoteId}/line-items/bulk-delete', params: [{ name: 'quoteId', in: 'path', required: true }], hasBody: true },
|
|
69
|
+
'updateLineItems': { resource: 'quoteLineItems', method: 'PUT', path: '/v2/quotes/{quoteId}/line-items', params: [{ name: 'quoteId', in: 'path', required: true }], hasBody: true },
|
|
70
|
+
'getQuotePreferences': { resource: 'quotePreferences', method: 'GET', path: '/v2/quote-preferences', params: [], hasBody: false },
|
|
71
|
+
'persistQuotePreferences': { resource: 'quotePreferences', method: 'PUT', path: '/v2/quote-preferences', params: [], hasBody: true },
|
|
72
|
+
'createSection': { resource: 'quoteSections', method: 'POST', path: '/v2/quotes/{quoteId}/sections', params: [{ name: 'quoteId', in: 'path', required: true }], hasBody: true },
|
|
73
|
+
'getSections': { resource: 'quoteSections', method: 'GET', path: '/v2/quotes/{quoteId}/sections', params: [{ name: 'quoteId', in: 'path', required: true }], hasBody: false },
|
|
74
|
+
'updateSections': { resource: 'quoteSections', method: 'PUT', path: '/v2/quotes/{quoteId}/sections', params: [{ name: 'quoteId', in: 'path', required: true }], hasBody: true },
|
|
75
|
+
'createQuote': { resource: 'quotes', method: 'POST', path: '/v2/quotes', params: [], hasBody: true },
|
|
76
|
+
'deleteQuoteById': { resource: 'quotes', method: 'DELETE', path: '/v2/quotes/{quoteId}', params: [{ name: 'quoteId', in: 'path', required: true }], hasBody: false },
|
|
77
|
+
'getQuoteById': { resource: 'quotes', method: 'GET', path: '/v2/quotes/{quoteId}', params: [{ name: 'quoteId', in: 'path', required: true }], hasBody: false },
|
|
78
|
+
'getQuotesList': { resource: 'quotes', method: 'GET', path: '/v2/quotes', params: [{ name: 'limit', in: 'query', required: false }, { name: 'page', in: 'query', required: false }, { name: 'sort', in: 'query', required: false }, { name: 'search', in: 'query', required: false }, { name: 'status', in: 'query', required: false }, { name: 'account', in: 'query', required: false }, { name: 'partnerId', in: 'query', required: false }, { name: 'intentType', in: 'query', required: false }], hasBody: false },
|
|
79
|
+
'updateQuote': { resource: 'quotes', method: 'PUT', path: '/v2/quotes/{quoteId}', params: [{ name: 'quoteId', in: 'path', required: true }], hasBody: true },
|
|
80
|
+
'delete_subscriptions_subscriptionId': { resource: 'subscriptions', method: 'DELETE', path: '/subscriptions/{subscriptionId}', params: [{ name: 'subscriptionId', in: 'path', required: true }, { name: 'cancelDate', in: 'query', required: false }], hasBody: false },
|
|
81
|
+
'findSubscriptionBySubscriptionId': { resource: 'subscriptions', method: 'GET', path: '/subscriptions/{subscriptionId}', params: [{ name: 'subscriptionId', in: 'path', required: true }], hasBody: false },
|
|
82
|
+
'findSubscriptionHistoryBySubscriptionId': { resource: 'subscriptions', method: 'GET', path: '/subscriptions/{subscriptionId}/history', params: [{ name: 'subscriptionId', in: 'path', required: true }], hasBody: false },
|
|
83
|
+
'findSubscriptions': { resource: 'subscriptions', method: 'GET', path: '/subscriptions', params: [{ name: 'page', in: 'query', required: false }, { name: 'size', in: 'query', required: false }, { name: 'sort', in: 'query', required: false }, { name: 'status', in: 'query', required: false }, { name: 'billingTerm', in: 'query', required: false }, { name: 'companyId', in: 'query', required: false }, { name: 'productId', in: 'query', required: false }], hasBody: false },
|
|
84
|
+
'updateSubscription': { resource: 'subscriptions', method: 'PUT', path: '/subscriptions/{subscriptionId}', params: [{ name: 'subscriptionId', in: 'path', required: true }], hasBody: true },
|
|
85
|
+
'getTopicDefinitions': { resource: 'topicDefinitions', method: 'GET', path: '/webhooks/topic-definitions', params: [{ name: 'page', in: 'query', required: false }, { name: 'size', in: 'query', required: false }, { name: 'search', in: 'query', required: false }, { name: 'sort', in: 'query', required: false }, { name: 'topic', in: 'query', required: false }], hasBody: false },
|
|
86
|
+
'getUsageLines': { resource: 'usageLines', method: 'GET', path: '/lines', params: [{ name: 'subscriptionId', in: 'query', required: false }, { name: 'externalSubscriptionId', in: 'query', required: false }, { name: 'billingPeriod', in: 'query', required: true }, { name: 'summaryKey', in: 'query', required: true }], hasBody: false },
|
|
87
|
+
'saveUsageLines': { resource: 'usageLines', method: 'POST', path: '/lines', params: [{ name: 'subscriptionId', in: 'query', required: false }, { name: 'externalSubscriptionId', in: 'query', required: false }, { name: 'billingPeriod', in: 'query', required: true }, { name: 'overwriteSameDayUsage', in: 'query', required: false }], hasBody: true },
|
|
88
|
+
'saveUsageLinesWithAggregate': { resource: 'usageLines', method: 'POST', path: '/aggregate-lines', params: [{ name: 'subscriptionId', in: 'query', required: false }, { name: 'externalSubscriptionId', in: 'query', required: false }, { name: 'billingPeriod', in: 'query', required: true }, { name: 'overwriteSameDayUsage', in: 'query', required: false }], hasBody: true },
|
|
89
|
+
'findSubscriptionUsageSummary': { resource: 'usageSummaries', method: 'GET', path: '/usage-summaries/{usageSummaryId}', params: [{ name: 'usageSummaryId', in: 'path', required: true }], hasBody: false },
|
|
90
|
+
'findSubscriptionUsageSummaries': { resource: 'usageSummaries', method: 'GET', path: '/subscriptions/{subscriptionId}/usage-summaries', params: [{ name: 'subscriptionId', in: 'path', required: true }, { name: 'page', in: 'query', required: false }, { name: 'size', in: 'query', required: false }, { name: 'sort', in: 'query', required: false }, { name: 'resourceGroup', in: 'query', required: false }, { name: 'companyId', in: 'query', required: false }], hasBody: false },
|
|
91
|
+
'findUsageLines': { resource: 'usageSummaries', method: 'GET', path: '/usage-summaries/{usageSummaryId}/usage-lines', params: [{ name: 'usageSummaryId', in: 'path', required: true }, { name: 'usageDate', in: 'query', required: true }, { name: 'productId', in: 'query', required: false }], hasBody: false },
|
|
92
|
+
'WebhookLogs_get': { resource: 'webhookLogs', method: 'GET', path: '/webhooks/{webhookId}/logs/{id}', params: [{ name: 'webhookId', in: 'path', required: true }, { name: 'id', in: 'path', required: true }], hasBody: false },
|
|
93
|
+
'WebhookLogs_query': { resource: 'webhookLogs', method: 'GET', path: '/webhooks/{webhookId}/logs', params: [{ name: 'webhookId', in: 'path', required: true }, { name: 'topicName', in: 'query', required: false }, { name: 'page', in: 'query', required: false }, { name: 'size', in: 'query', required: false }, { name: 'status', in: 'query', required: false }, { name: 'startDate', in: 'query', required: false }, { name: 'endDate', in: 'query', required: false }, { name: 'sort', in: 'query', required: false }, { name: 'query', in: 'query', required: true }], hasBody: false },
|
|
94
|
+
'retryWebhookDelivery': { resource: 'webhookLogs', method: 'POST', path: '/webhooks/{webhookId}/logs/{logId}/retry', params: [{ name: 'webhookId', in: 'path', required: true }, { name: 'logId', in: 'path', required: true }], hasBody: false },
|
|
95
|
+
'addWebhookTopic': { resource: 'webhooks', method: 'POST', path: '/webhooks/{id}/topics', params: [{ name: 'id', in: 'path', required: true }], hasBody: true },
|
|
96
|
+
'Webhooks_create': { resource: 'webhooks', method: 'POST', path: '/webhooks', params: [], hasBody: true },
|
|
97
|
+
'Webhooks_delete': { resource: 'webhooks', method: 'DELETE', path: '/webhooks/{id}', params: [{ name: 'id', in: 'path', required: true }], hasBody: false },
|
|
98
|
+
'Webhooks_get': { resource: 'webhooks', method: 'GET', path: '/webhooks/{id}', params: [{ name: 'id', in: 'path', required: true }], hasBody: false },
|
|
99
|
+
'Webhooks_query': { resource: 'webhooks', method: 'GET', path: '/webhooks', params: [{ name: 'query', in: 'query', required: false }, { name: 'page', in: 'query', required: false }, { name: 'size', in: 'query', required: false }, { name: 'active', in: 'query', required: false }, { name: 'topic', in: 'query', required: false }, { name: 'sort', in: 'query', required: false }, { name: 'status', in: 'query', required: false }, { name: 'accountId', in: 'query', required: false }], hasBody: false },
|
|
100
|
+
'removeWebhookTopic': { resource: 'webhooks', method: 'DELETE', path: '/webhooks/{id}/topics/{topicId}', params: [{ name: 'id', in: 'path', required: true }, { name: 'topicId', in: 'path', required: true }], hasBody: false },
|
|
101
|
+
'replaceWebhookTopics': { resource: 'webhooks', method: 'PUT', path: '/webhooks/{id}/topics', params: [{ name: 'id', in: 'path', required: true }], hasBody: true },
|
|
102
|
+
'testWebhookTopic': { resource: 'webhooks', method: 'POST', path: '/webhooks/{id}/topics/{topic}/test', params: [{ name: 'id', in: 'path', required: true }, { name: 'topic', in: 'path', required: true }], hasBody: false },
|
|
103
|
+
'updateWebhookTopicConfiguration': { resource: 'webhooks', method: 'POST', path: '/webhooks/{id}/topics/{topicId}/configuration', params: [{ name: 'id', in: 'path', required: true }, { name: 'topicId', in: 'path', required: true }], hasBody: true },
|
|
104
|
+
'updateConfiguration': { resource: 'webhooks', method: 'POST', path: '/webhooks/{id}/configuration', params: [{ name: 'id', in: 'path', required: true }], hasBody: true },
|
|
105
|
+
'updateStatus': { resource: 'webhooks', method: 'POST', path: '/webhooks/{id}/status', params: [{ name: 'id', in: 'path', required: true }], hasBody: true },
|
|
106
|
+
};
|
|
107
|
+
function applyPathParams(endpoint, params) {
|
|
108
|
+
let result = endpoint;
|
|
109
|
+
for (const [key, value] of Object.entries(params)) {
|
|
110
|
+
result = result.replaceAll(`{${key}}`, encodeURIComponent(String(value)));
|
|
111
|
+
result = result.replaceAll(`:${key}`, encodeURIComponent(String(value)));
|
|
112
|
+
}
|
|
113
|
+
return result;
|
|
114
|
+
}
|
|
115
|
+
function cleanQuery(obj) {
|
|
116
|
+
const out = {};
|
|
117
|
+
for (const [k, v] of Object.entries(obj)) {
|
|
118
|
+
if (v === undefined || v === null)
|
|
119
|
+
continue;
|
|
120
|
+
if (typeof v === 'string' && v.trim() === '')
|
|
121
|
+
continue;
|
|
122
|
+
out[k] = v;
|
|
123
|
+
}
|
|
124
|
+
return out;
|
|
125
|
+
}
|
|
126
|
+
const LIST_PAGINATION = {
|
|
127
|
+
// Paged list endpoints returning { content, page }
|
|
128
|
+
findCompanies: { pageParam: 'page', sizeParam: 'size', defaultSize: 10, maxSize: 200 },
|
|
129
|
+
get_companies_companyId_contacts: { pageParam: 'page', sizeParam: 'size', defaultSize: 10, maxSize: 200 },
|
|
130
|
+
findAllProducts: { pageParam: 'page', sizeParam: 'size', defaultSize: 10, maxSize: 200 },
|
|
131
|
+
findOrders: { pageParam: 'page', sizeParam: 'size', defaultSize: 10, maxSize: 200 },
|
|
132
|
+
findSubscriptions: { pageParam: 'page', sizeParam: 'size', defaultSize: 10, maxSize: 200 },
|
|
133
|
+
findPartnerInvoices: { pageParam: 'page', sizeParam: 'size', defaultSize: 10, maxSize: 200 },
|
|
134
|
+
findPartnerInvoiceItems: { pageParam: 'page', sizeParam: 'size', defaultSize: 10, maxSize: 200 },
|
|
135
|
+
findPartnerDraftInvoiceItems: { pageParam: 'page', sizeParam: 'size', defaultSize: 10, maxSize: 200 },
|
|
136
|
+
findSubscriptionUsageSummaries: { pageParam: 'page', sizeParam: 'size', defaultSize: 10, maxSize: 200 },
|
|
137
|
+
getQuotesList: { pageParam: 'page', sizeParam: 'limit', defaultSize: 10, maxSize: 200 },
|
|
138
|
+
Webhooks_query: { pageParam: 'page', sizeParam: 'size', defaultSize: 10, maxSize: 200 },
|
|
139
|
+
getTopicDefinitions: { pageParam: 'page', sizeParam: 'size', defaultSize: 10, maxSize: 200 },
|
|
140
|
+
WebhookLogs_query: { pageParam: 'page', sizeParam: 'size', defaultSize: 10, maxSize: 200 },
|
|
141
|
+
};
|
|
142
|
+
function extractListItems(responseData) {
|
|
143
|
+
if (Array.isArray(responseData))
|
|
144
|
+
return responseData;
|
|
145
|
+
if (responseData && Array.isArray(responseData.content))
|
|
146
|
+
return responseData.content;
|
|
147
|
+
return null;
|
|
148
|
+
}
|
|
149
|
+
class Pax8 {
|
|
150
|
+
constructor() {
|
|
151
|
+
this.description = {
|
|
152
|
+
displayName: 'Pax8',
|
|
153
|
+
name: 'pax8',
|
|
154
|
+
icon: 'file:pax8.svg',
|
|
155
|
+
group: ['transform'],
|
|
156
|
+
version: 1,
|
|
157
|
+
description: 'Interact with the Pax8 Partner API',
|
|
158
|
+
defaults: {
|
|
159
|
+
name: 'Pax8',
|
|
160
|
+
},
|
|
161
|
+
inputs: ['main'],
|
|
162
|
+
outputs: ['main'],
|
|
163
|
+
credentials: [
|
|
164
|
+
{ name: 'pax8OAuth2Api', required: false },
|
|
165
|
+
{ name: 'pax8ApiToken', required: false },
|
|
166
|
+
],
|
|
167
|
+
properties: [
|
|
168
|
+
{
|
|
169
|
+
displayName: 'Authentication',
|
|
170
|
+
name: 'authMode',
|
|
171
|
+
type: 'options',
|
|
172
|
+
default: 'oauth2',
|
|
173
|
+
options: [
|
|
174
|
+
{ name: 'OAuth2 (Client Credentials)', value: 'oauth2' },
|
|
175
|
+
{ name: 'Access Token', value: 'token' },
|
|
176
|
+
],
|
|
177
|
+
description: 'Choose how the node should authenticate',
|
|
178
|
+
},
|
|
179
|
+
{
|
|
180
|
+
displayName: 'Base URL',
|
|
181
|
+
name: 'baseUrl',
|
|
182
|
+
type: 'string',
|
|
183
|
+
default: 'https://api.pax8.com',
|
|
184
|
+
description: 'Base URL for the Pax8 API.',
|
|
185
|
+
},
|
|
186
|
+
{
|
|
187
|
+
displayName: 'Resource',
|
|
188
|
+
name: 'resource',
|
|
189
|
+
type: 'options',
|
|
190
|
+
default: 'accessToken',
|
|
191
|
+
options: [
|
|
192
|
+
{ name: 'Access Token', value: 'accessToken' },
|
|
193
|
+
{ name: 'Companies', value: 'companies' },
|
|
194
|
+
{ name: 'Contacts', value: 'contacts' },
|
|
195
|
+
{ name: 'Invoices', value: 'invoices' },
|
|
196
|
+
{ name: 'Library attachments', value: 'libraryAttachments' },
|
|
197
|
+
{ name: 'Orders', value: 'orders' },
|
|
198
|
+
{ name: 'Preference attachments', value: 'preferenceAttachments' },
|
|
199
|
+
{ name: 'Products', value: 'products' },
|
|
200
|
+
{ name: 'Provision Attempts', value: 'provisionAttempts' },
|
|
201
|
+
{ name: 'Provision Details', value: 'provisionDetails' },
|
|
202
|
+
{ name: 'Provision Requests', value: 'provisionRequests' },
|
|
203
|
+
{ name: 'Provision Results', value: 'provisionResults' },
|
|
204
|
+
{ name: 'Provisioners', value: 'provisioners' },
|
|
205
|
+
{ name: 'Provisioning Simulations', value: 'provisioningSimulations' },
|
|
206
|
+
{ name: 'Quote access list', value: 'quoteAccessList' },
|
|
207
|
+
{ name: 'Quote attachments', value: 'quoteAttachments' },
|
|
208
|
+
{ name: 'Quote line items', value: 'quoteLineItems' },
|
|
209
|
+
{ name: 'Quote preferences', value: 'quotePreferences' },
|
|
210
|
+
{ name: 'Quote sections', value: 'quoteSections' },
|
|
211
|
+
{ name: 'Quotes', value: 'quotes' },
|
|
212
|
+
{ name: 'Subscriptions', value: 'subscriptions' },
|
|
213
|
+
{ name: 'Topic Definitions', value: 'topicDefinitions' },
|
|
214
|
+
{ name: 'Usage Lines', value: 'usageLines' },
|
|
215
|
+
{ name: 'Usage Summaries', value: 'usageSummaries' },
|
|
216
|
+
{ name: 'Webhook Logs', value: 'webhookLogs' },
|
|
217
|
+
{ name: 'Webhooks', value: 'webhooks' },
|
|
218
|
+
],
|
|
219
|
+
},
|
|
220
|
+
{
|
|
221
|
+
displayName: 'Operation',
|
|
222
|
+
name: 'operation',
|
|
223
|
+
type: 'options',
|
|
224
|
+
default: 'createAccessToken',
|
|
225
|
+
displayOptions: { show: { resource: ['accessToken'] } },
|
|
226
|
+
options: [
|
|
227
|
+
{ name: 'Create a new Access Token', value: 'createAccessToken' },
|
|
228
|
+
],
|
|
229
|
+
},
|
|
230
|
+
{
|
|
231
|
+
displayName: 'Operation',
|
|
232
|
+
name: 'operation',
|
|
233
|
+
type: 'options',
|
|
234
|
+
default: 'createCompany',
|
|
235
|
+
displayOptions: { show: { resource: ['companies'] } },
|
|
236
|
+
options: [
|
|
237
|
+
{ name: 'Create Company', value: 'createCompany' },
|
|
238
|
+
{ name: 'Get Company By ID', value: 'get_companies_companyId' },
|
|
239
|
+
{ name: 'List Companies', value: 'findCompanies' },
|
|
240
|
+
{ name: 'Update Company', value: 'updateCompany' },
|
|
241
|
+
],
|
|
242
|
+
},
|
|
243
|
+
{
|
|
244
|
+
displayName: 'Operation',
|
|
245
|
+
name: 'operation',
|
|
246
|
+
type: 'options',
|
|
247
|
+
default: 'post_companies_companyId_contacts',
|
|
248
|
+
displayOptions: { show: { resource: ['contacts'] } },
|
|
249
|
+
options: [
|
|
250
|
+
{ name: 'Create Contact', value: 'post_companies_companyId_contacts' },
|
|
251
|
+
{ name: 'Delete Contact', value: 'delete_companies_companyId_contacts_contactId' },
|
|
252
|
+
{ name: 'Get Contact By ID', value: 'get_companies_companyId_contacts_contactId' },
|
|
253
|
+
{ name: 'List Contacts', value: 'get_companies_companyId_contacts' },
|
|
254
|
+
{ name: 'Update Contact', value: 'put_companies_companyId_contacts_contactId' },
|
|
255
|
+
],
|
|
256
|
+
},
|
|
257
|
+
{
|
|
258
|
+
displayName: 'Operation',
|
|
259
|
+
name: 'operation',
|
|
260
|
+
type: 'options',
|
|
261
|
+
default: 'getPartnerInvoice',
|
|
262
|
+
displayOptions: { show: { resource: ['invoices'] } },
|
|
263
|
+
options: [
|
|
264
|
+
{ name: 'Get Invoice By ID', value: 'getPartnerInvoice' },
|
|
265
|
+
{ name: 'List Draft Invoice Items', value: 'findPartnerDraftInvoiceItems' },
|
|
266
|
+
{ name: 'List Invoice Items', value: 'findPartnerInvoiceItems' },
|
|
267
|
+
{ name: 'List Invoices', value: 'findPartnerInvoices' },
|
|
268
|
+
],
|
|
269
|
+
},
|
|
270
|
+
{
|
|
271
|
+
displayName: 'Operation',
|
|
272
|
+
name: 'operation',
|
|
273
|
+
type: 'options',
|
|
274
|
+
default: 'addQuoteAttachmentsToLibrary',
|
|
275
|
+
displayOptions: { show: { resource: ['libraryAttachments'] } },
|
|
276
|
+
options: [
|
|
277
|
+
{ name: 'Add quote attachments to library', value: 'addQuoteAttachmentsToLibrary' },
|
|
278
|
+
{ name: 'Delete library attachment', value: 'deleteSingleLibraryAttachment' },
|
|
279
|
+
{ name: 'Download library attachment', value: 'getLibraryAttachmentMetadata' },
|
|
280
|
+
{ name: 'Get attachments from the library', value: 'getLibraryAttachmentsMetadata' },
|
|
281
|
+
{ name: 'Replace library attachment', value: 'replaceLibraryAttachment' },
|
|
282
|
+
{ name: 'Update library attachments', value: 'updateLibraryAttachments' },
|
|
283
|
+
{ name: 'Upload attachments to library', value: 'uploadAttachmentToLibrary' },
|
|
284
|
+
],
|
|
285
|
+
},
|
|
286
|
+
{
|
|
287
|
+
displayName: 'Operation',
|
|
288
|
+
name: 'operation',
|
|
289
|
+
type: 'options',
|
|
290
|
+
default: 'createOrder',
|
|
291
|
+
displayOptions: { show: { resource: ['orders'] } },
|
|
292
|
+
options: [
|
|
293
|
+
{ name: 'Create Order', value: 'createOrder' },
|
|
294
|
+
{ name: 'Get Order By ID', value: 'findOrdersByOrderId' },
|
|
295
|
+
{ name: 'List Orders', value: 'findOrders' },
|
|
296
|
+
],
|
|
297
|
+
},
|
|
298
|
+
{
|
|
299
|
+
displayName: 'Operation',
|
|
300
|
+
name: 'operation',
|
|
301
|
+
type: 'options',
|
|
302
|
+
default: 'deletePreferenceAttachment',
|
|
303
|
+
displayOptions: { show: { resource: ['preferenceAttachments'] } },
|
|
304
|
+
options: [
|
|
305
|
+
{ name: 'Delete preference attachment', value: 'deletePreferenceAttachment' },
|
|
306
|
+
{ name: 'Upload preference attachments', value: 'uploadPreferencesAttachments' },
|
|
307
|
+
],
|
|
308
|
+
},
|
|
309
|
+
{
|
|
310
|
+
displayName: 'Operation',
|
|
311
|
+
name: 'operation',
|
|
312
|
+
type: 'options',
|
|
313
|
+
default: 'findPricingByProductId',
|
|
314
|
+
displayOptions: { show: { resource: ['products'] } },
|
|
315
|
+
options: [
|
|
316
|
+
{ name: 'Get Pricing', value: 'findPricingByProductId' },
|
|
317
|
+
{ name: 'Get Product By ID', value: 'findProductByProductId' },
|
|
318
|
+
{ name: 'Get Product Dependencies', value: 'findProductDependenciesByProductId' },
|
|
319
|
+
{ name: 'Get Provisioning Details', value: 'findProvisionDetailsByProductId' },
|
|
320
|
+
{ name: 'List Products', value: 'findAllProducts' },
|
|
321
|
+
],
|
|
322
|
+
},
|
|
323
|
+
{
|
|
324
|
+
displayName: 'Operation',
|
|
325
|
+
name: 'operation',
|
|
326
|
+
type: 'options',
|
|
327
|
+
default: 'createAttemptForRequest',
|
|
328
|
+
displayOptions: { show: { resource: ['provisionAttempts'] } },
|
|
329
|
+
options: [
|
|
330
|
+
{ name: 'Create Provision Attempt for a Provision Request and Provision Detail', value: 'createAttemptForRequest' },
|
|
331
|
+
{ name: 'Get All Provision Attempts for a Provision Request', value: 'getAllProvisionAttempts' },
|
|
332
|
+
{ name: 'Get Latest Provision Attempt for a Provision Request', value: 'getLatestProvisionAttempt' },
|
|
333
|
+
{ name: 'Get Provision Attempt by ID', value: 'getOneProvisionAttempt' },
|
|
334
|
+
],
|
|
335
|
+
},
|
|
336
|
+
{
|
|
337
|
+
displayName: 'Operation',
|
|
338
|
+
name: 'operation',
|
|
339
|
+
type: 'options',
|
|
340
|
+
default: 'getAllProvisionDetails',
|
|
341
|
+
displayOptions: { show: { resource: ['provisionDetails'] } },
|
|
342
|
+
options: [
|
|
343
|
+
{ name: 'Get All Provision Details for a Provision Request', value: 'getAllProvisionDetails' },
|
|
344
|
+
{ name: 'Get Latest Provision Detail by Provision Request ID', value: 'getLatestProvisionDetail' },
|
|
345
|
+
{ name: 'Get One Provision Detail by Provision Request ID', value: 'getOneProvisionDetail' },
|
|
346
|
+
],
|
|
347
|
+
},
|
|
348
|
+
{
|
|
349
|
+
displayName: 'Operation',
|
|
350
|
+
name: 'operation',
|
|
351
|
+
type: 'options',
|
|
352
|
+
default: 'getAllProvisionRequests',
|
|
353
|
+
displayOptions: { show: { resource: ['provisionRequests'] } },
|
|
354
|
+
options: [
|
|
355
|
+
{ name: 'Get All Provision Requests', value: 'getAllProvisionRequests' },
|
|
356
|
+
{ name: 'Get All Unfulfilled Provision Requests', value: 'getAllUnfulfilledProvisionRequests' },
|
|
357
|
+
{ name: 'Get One Provision Request', value: 'getOneProvisionRequest' },
|
|
358
|
+
],
|
|
359
|
+
},
|
|
360
|
+
{
|
|
361
|
+
displayName: 'Operation',
|
|
362
|
+
name: 'operation',
|
|
363
|
+
type: 'options',
|
|
364
|
+
default: 'createProvisionResult',
|
|
365
|
+
displayOptions: { show: { resource: ['provisionResults'] } },
|
|
366
|
+
options: [
|
|
367
|
+
{ name: 'Create Provision Result', value: 'createProvisionResult' },
|
|
368
|
+
{ name: 'Get All Provision Results for a Provision Request', value: 'getAllProvisionResults' },
|
|
369
|
+
{ name: 'Get Latest Provision Result for an Order', value: 'getLatestProvisionResult' },
|
|
370
|
+
{ name: 'Get One Provision Result', value: 'getOneProvisionResult' },
|
|
371
|
+
],
|
|
372
|
+
},
|
|
373
|
+
{
|
|
374
|
+
displayName: 'Operation',
|
|
375
|
+
name: 'operation',
|
|
376
|
+
type: 'options',
|
|
377
|
+
default: 'createWebhookForProvisioner',
|
|
378
|
+
displayOptions: { show: { resource: ['provisioners'] } },
|
|
379
|
+
options: [
|
|
380
|
+
{ name: 'Create a Webhook Configuration for a Provisioner', value: 'createWebhookForProvisioner' },
|
|
381
|
+
{ name: 'Get All Provisioners', value: 'getAllProvisioners' },
|
|
382
|
+
{ name: 'Get All Webhook Configurations for a Provisioner', value: 'getAllWebhooksForProvisioner' },
|
|
383
|
+
{ name: 'Get Latest Webhook for a Provisioner', value: 'getLatestWebhookForProvisioner' },
|
|
384
|
+
{ name: 'Get One Provisioner by ID', value: 'getOneProvisioner' },
|
|
385
|
+
{ name: 'Get One Webhook for a Provisioner', value: 'getOneWebhookForProvisioner' },
|
|
386
|
+
],
|
|
387
|
+
},
|
|
388
|
+
{
|
|
389
|
+
displayName: 'Operation',
|
|
390
|
+
name: 'operation',
|
|
391
|
+
type: 'options',
|
|
392
|
+
default: 'createOrderEvent',
|
|
393
|
+
displayOptions: { show: { resource: ['provisioningSimulations'] } },
|
|
394
|
+
options: [
|
|
395
|
+
{ name: 'Create Order Event', value: 'createOrderEvent' },
|
|
396
|
+
],
|
|
397
|
+
},
|
|
398
|
+
{
|
|
399
|
+
displayName: 'Operation',
|
|
400
|
+
name: 'operation',
|
|
401
|
+
type: 'options',
|
|
402
|
+
default: 'addQuoteAccessListEntry',
|
|
403
|
+
displayOptions: { show: { resource: ['quoteAccessList'] } },
|
|
404
|
+
options: [
|
|
405
|
+
{ name: 'Add access list entries', value: 'addQuoteAccessListEntry' },
|
|
406
|
+
{ name: 'Delete quote access list entry', value: 'deleteQuoteShareEntry' },
|
|
407
|
+
{ name: 'Get quote access list', value: 'getQuoteAccessList' },
|
|
408
|
+
],
|
|
409
|
+
},
|
|
410
|
+
{
|
|
411
|
+
displayName: 'Operation',
|
|
412
|
+
name: 'operation',
|
|
413
|
+
type: 'options',
|
|
414
|
+
default: 'copyAttachmentsToQuoteFromLibrary',
|
|
415
|
+
displayOptions: { show: { resource: ['quoteAttachments'] } },
|
|
416
|
+
options: [
|
|
417
|
+
{ name: 'Copy attachment to quote from library', value: 'copyAttachmentsToQuoteFromLibrary' },
|
|
418
|
+
{ name: 'Delete attachment', value: 'deleteAttachment' },
|
|
419
|
+
{ name: 'Download all quote attachments', value: 'downloadAllAttachmentsAsZip' },
|
|
420
|
+
{ name: 'Download attachment', value: 'getAttachmentMetadata' },
|
|
421
|
+
{ name: 'Update attachments', value: 'updateAttachmentsMetadata' },
|
|
422
|
+
{ name: 'Upload attachments to quote', value: 'uploadAttachmentToQuote' },
|
|
423
|
+
],
|
|
424
|
+
},
|
|
425
|
+
{
|
|
426
|
+
displayName: 'Operation',
|
|
427
|
+
name: 'operation',
|
|
428
|
+
type: 'options',
|
|
429
|
+
default: 'addLineItems',
|
|
430
|
+
displayOptions: { show: { resource: ['quoteLineItems'] } },
|
|
431
|
+
options: [
|
|
432
|
+
{ name: 'Add line items', value: 'addLineItems' },
|
|
433
|
+
{ name: 'Delete line item by ID', value: 'deleteLineItemById' },
|
|
434
|
+
{ name: 'Delete line items', value: 'bulkDeleteLineItems' },
|
|
435
|
+
{ name: 'Update line items', value: 'updateLineItems' },
|
|
436
|
+
],
|
|
437
|
+
},
|
|
438
|
+
{
|
|
439
|
+
displayName: 'Operation',
|
|
440
|
+
name: 'operation',
|
|
441
|
+
type: 'options',
|
|
442
|
+
default: 'getQuotePreferences',
|
|
443
|
+
displayOptions: { show: { resource: ['quotePreferences'] } },
|
|
444
|
+
options: [
|
|
445
|
+
{ name: 'Get quote preferences', value: 'getQuotePreferences' },
|
|
446
|
+
{ name: 'Update quote preferences', value: 'persistQuotePreferences' },
|
|
447
|
+
],
|
|
448
|
+
},
|
|
449
|
+
{
|
|
450
|
+
displayName: 'Operation',
|
|
451
|
+
name: 'operation',
|
|
452
|
+
type: 'options',
|
|
453
|
+
default: 'createSection',
|
|
454
|
+
displayOptions: { show: { resource: ['quoteSections'] } },
|
|
455
|
+
options: [
|
|
456
|
+
{ name: 'Create Section', value: 'createSection' },
|
|
457
|
+
{ name: 'Get quote sections', value: 'getSections' },
|
|
458
|
+
{ name: 'Update Sections', value: 'updateSections' },
|
|
459
|
+
],
|
|
460
|
+
},
|
|
461
|
+
{
|
|
462
|
+
displayName: 'Operation',
|
|
463
|
+
name: 'operation',
|
|
464
|
+
type: 'options',
|
|
465
|
+
default: 'createQuote',
|
|
466
|
+
displayOptions: { show: { resource: ['quotes'] } },
|
|
467
|
+
options: [
|
|
468
|
+
{ name: 'Create quote', value: 'createQuote' },
|
|
469
|
+
{ name: 'Delete quote by ID', value: 'deleteQuoteById' },
|
|
470
|
+
{ name: 'Get quote by ID', value: 'getQuoteById' },
|
|
471
|
+
{ name: 'Get quotes list', value: 'getQuotesList' },
|
|
472
|
+
{ name: 'Update quote by ID', value: 'updateQuote' },
|
|
473
|
+
],
|
|
474
|
+
},
|
|
475
|
+
{
|
|
476
|
+
displayName: 'Operation',
|
|
477
|
+
name: 'operation',
|
|
478
|
+
type: 'options',
|
|
479
|
+
default: 'delete_subscriptions_subscriptionId',
|
|
480
|
+
displayOptions: { show: { resource: ['subscriptions'] } },
|
|
481
|
+
options: [
|
|
482
|
+
{ name: 'Cancel Subscription', value: 'delete_subscriptions_subscriptionId' },
|
|
483
|
+
{ name: 'Get Subscription By ID', value: 'findSubscriptionBySubscriptionId' },
|
|
484
|
+
{ name: 'Get Subscription History', value: 'findSubscriptionHistoryBySubscriptionId' },
|
|
485
|
+
{ name: 'List Subscriptions', value: 'findSubscriptions' },
|
|
486
|
+
{ name: 'Update Subscription', value: 'updateSubscription' },
|
|
487
|
+
],
|
|
488
|
+
},
|
|
489
|
+
{
|
|
490
|
+
displayName: 'Operation',
|
|
491
|
+
name: 'operation',
|
|
492
|
+
type: 'options',
|
|
493
|
+
default: 'getTopicDefinitions',
|
|
494
|
+
displayOptions: { show: { resource: ['topicDefinitions'] } },
|
|
495
|
+
options: [
|
|
496
|
+
{ name: 'Get topic definitions', value: 'getTopicDefinitions' },
|
|
497
|
+
],
|
|
498
|
+
},
|
|
499
|
+
{
|
|
500
|
+
displayName: 'Operation',
|
|
501
|
+
name: 'operation',
|
|
502
|
+
type: 'options',
|
|
503
|
+
default: 'getUsageLines',
|
|
504
|
+
displayOptions: { show: { resource: ['usageLines'] } },
|
|
505
|
+
options: [
|
|
506
|
+
{ name: 'Get Usage Lines', value: 'getUsageLines' },
|
|
507
|
+
{ name: 'Save Usage Lines', value: 'saveUsageLines' },
|
|
508
|
+
{ name: 'Save Usage Lines with an Aggregate Partner Quantity', value: 'saveUsageLinesWithAggregate' },
|
|
509
|
+
],
|
|
510
|
+
},
|
|
511
|
+
{
|
|
512
|
+
displayName: 'Operation',
|
|
513
|
+
name: 'operation',
|
|
514
|
+
type: 'options',
|
|
515
|
+
default: 'findSubscriptionUsageSummary',
|
|
516
|
+
displayOptions: { show: { resource: ['usageSummaries'] } },
|
|
517
|
+
options: [
|
|
518
|
+
{ name: 'Get Usage Summary By ID', value: 'findSubscriptionUsageSummary' },
|
|
519
|
+
{ name: 'List Usage Summaries', value: 'findSubscriptionUsageSummaries' },
|
|
520
|
+
{ name: 'List Usage Summary Lines', value: 'findUsageLines' },
|
|
521
|
+
],
|
|
522
|
+
},
|
|
523
|
+
{
|
|
524
|
+
displayName: 'Operation',
|
|
525
|
+
name: 'operation',
|
|
526
|
+
type: 'options',
|
|
527
|
+
default: 'WebhookLogs_get',
|
|
528
|
+
displayOptions: { show: { resource: ['webhookLogs'] } },
|
|
529
|
+
options: [
|
|
530
|
+
{ name: 'Get webhook log by ID', value: 'WebhookLogs_get' },
|
|
531
|
+
{ name: 'Query webhook logs', value: 'WebhookLogs_query' },
|
|
532
|
+
{ name: 'Retry webhook delivery', value: 'retryWebhookDelivery' },
|
|
533
|
+
],
|
|
534
|
+
},
|
|
535
|
+
{
|
|
536
|
+
displayName: 'Operation',
|
|
537
|
+
name: 'operation',
|
|
538
|
+
type: 'options',
|
|
539
|
+
default: 'addWebhookTopic',
|
|
540
|
+
displayOptions: { show: { resource: ['webhooks'] } },
|
|
541
|
+
options: [
|
|
542
|
+
{ name: 'Add webhook topic', value: 'addWebhookTopic' },
|
|
543
|
+
{ name: 'Create webhook', value: 'Webhooks_create' },
|
|
544
|
+
{ name: 'Delete webhook', value: 'Webhooks_delete' },
|
|
545
|
+
{ name: 'Get webhook by ID', value: 'Webhooks_get' },
|
|
546
|
+
{ name: 'Query webhooks', value: 'Webhooks_query' },
|
|
547
|
+
{ name: 'Remove webhook topic', value: 'removeWebhookTopic' },
|
|
548
|
+
{ name: 'Replace all webhook topics', value: 'replaceWebhookTopics' },
|
|
549
|
+
{ name: 'Test webhook topic', value: 'testWebhookTopic' },
|
|
550
|
+
{ name: 'Update topic configuration', value: 'updateWebhookTopicConfiguration' },
|
|
551
|
+
{ name: 'Update webhook configuration', value: 'updateConfiguration' },
|
|
552
|
+
{ name: 'Update webhook status', value: 'updateStatus' },
|
|
553
|
+
],
|
|
554
|
+
},
|
|
555
|
+
{
|
|
556
|
+
displayName: 'Body',
|
|
557
|
+
name: 'body',
|
|
558
|
+
type: 'json',
|
|
559
|
+
default: '{}',
|
|
560
|
+
required: false,
|
|
561
|
+
displayOptions: { show: { resource: ['accessToken'], operation: ['createAccessToken'] } },
|
|
562
|
+
description: 'Request body as JSON.',
|
|
563
|
+
},
|
|
564
|
+
{
|
|
565
|
+
displayName: 'Body',
|
|
566
|
+
name: 'body',
|
|
567
|
+
type: 'json',
|
|
568
|
+
default: '{}',
|
|
569
|
+
required: false,
|
|
570
|
+
displayOptions: { show: { resource: ['companies'], operation: ['createCompany'] } },
|
|
571
|
+
description: 'Request body as JSON.',
|
|
572
|
+
},
|
|
573
|
+
{
|
|
574
|
+
displayName: 'companyId',
|
|
575
|
+
name: 'companyId',
|
|
576
|
+
type: 'options',
|
|
577
|
+
typeOptions: { loadOptionsMethod: 'getCompanies' },
|
|
578
|
+
default: '',
|
|
579
|
+
required: true,
|
|
580
|
+
displayOptions: { show: { resource: ['companies'], operation: ['get_companies_companyId'] } },
|
|
581
|
+
description: 'path parameter',
|
|
582
|
+
},
|
|
583
|
+
{
|
|
584
|
+
displayName: 'Return All',
|
|
585
|
+
name: 'returnAll',
|
|
586
|
+
type: 'boolean',
|
|
587
|
+
default: false,
|
|
588
|
+
displayOptions: { show: { resource: ['companies'], operation: ['findCompanies'] } },
|
|
589
|
+
description: 'Whether to return all results (paginate automatically).',
|
|
590
|
+
},
|
|
591
|
+
{
|
|
592
|
+
displayName: 'Max Results',
|
|
593
|
+
name: 'maxResults',
|
|
594
|
+
type: 'number',
|
|
595
|
+
default: 0,
|
|
596
|
+
displayOptions: { show: { resource: ['companies'], operation: ['findCompanies'], returnAll: [true] } },
|
|
597
|
+
description: 'Maximum number of results to return. 0 means no limit.',
|
|
598
|
+
},
|
|
599
|
+
{
|
|
600
|
+
displayName: 'Return All',
|
|
601
|
+
name: 'returnAll',
|
|
602
|
+
type: 'boolean',
|
|
603
|
+
default: false,
|
|
604
|
+
displayOptions: { show: { resource: ['contacts'], operation: ['get_companies_companyId_contacts'] } },
|
|
605
|
+
description: 'Whether to return all results (paginate automatically).',
|
|
606
|
+
},
|
|
607
|
+
{
|
|
608
|
+
displayName: 'Max Results',
|
|
609
|
+
name: 'maxResults',
|
|
610
|
+
type: 'number',
|
|
611
|
+
default: 0,
|
|
612
|
+
displayOptions: { show: { resource: ['contacts'], operation: ['get_companies_companyId_contacts'], returnAll: [true] } },
|
|
613
|
+
description: 'Maximum number of results to return. 0 means no limit.',
|
|
614
|
+
},
|
|
615
|
+
{
|
|
616
|
+
displayName: 'Return All',
|
|
617
|
+
name: 'returnAll',
|
|
618
|
+
type: 'boolean',
|
|
619
|
+
default: false,
|
|
620
|
+
displayOptions: { show: { resource: ['products'], operation: ['findAllProducts'] } },
|
|
621
|
+
description: 'Whether to return all results (paginate automatically).',
|
|
622
|
+
},
|
|
623
|
+
{
|
|
624
|
+
displayName: 'Max Results',
|
|
625
|
+
name: 'maxResults',
|
|
626
|
+
type: 'number',
|
|
627
|
+
default: 0,
|
|
628
|
+
displayOptions: { show: { resource: ['products'], operation: ['findAllProducts'], returnAll: [true] } },
|
|
629
|
+
description: 'Maximum number of results to return. 0 means no limit.',
|
|
630
|
+
},
|
|
631
|
+
{
|
|
632
|
+
displayName: 'Return All',
|
|
633
|
+
name: 'returnAll',
|
|
634
|
+
type: 'boolean',
|
|
635
|
+
default: false,
|
|
636
|
+
displayOptions: { show: { resource: ['orders'], operation: ['findOrders'] } },
|
|
637
|
+
description: 'Whether to return all results (paginate automatically).',
|
|
638
|
+
},
|
|
639
|
+
{
|
|
640
|
+
displayName: 'Max Results',
|
|
641
|
+
name: 'maxResults',
|
|
642
|
+
type: 'number',
|
|
643
|
+
default: 0,
|
|
644
|
+
displayOptions: { show: { resource: ['orders'], operation: ['findOrders'], returnAll: [true] } },
|
|
645
|
+
description: 'Maximum number of results to return. 0 means no limit.',
|
|
646
|
+
},
|
|
647
|
+
{
|
|
648
|
+
displayName: 'Return All',
|
|
649
|
+
name: 'returnAll',
|
|
650
|
+
type: 'boolean',
|
|
651
|
+
default: false,
|
|
652
|
+
displayOptions: { show: { resource: ['subscriptions'], operation: ['findSubscriptions'] } },
|
|
653
|
+
description: 'Whether to return all results (paginate automatically).',
|
|
654
|
+
},
|
|
655
|
+
{
|
|
656
|
+
displayName: 'Max Results',
|
|
657
|
+
name: 'maxResults',
|
|
658
|
+
type: 'number',
|
|
659
|
+
default: 0,
|
|
660
|
+
displayOptions: { show: { resource: ['subscriptions'], operation: ['findSubscriptions'], returnAll: [true] } },
|
|
661
|
+
description: 'Maximum number of results to return. 0 means no limit.',
|
|
662
|
+
},
|
|
663
|
+
{
|
|
664
|
+
displayName: 'Return All',
|
|
665
|
+
name: 'returnAll',
|
|
666
|
+
type: 'boolean',
|
|
667
|
+
default: false,
|
|
668
|
+
displayOptions: { show: { resource: ['invoices'], operation: ['findPartnerInvoices'] } },
|
|
669
|
+
description: 'Whether to return all results (paginate automatically).',
|
|
670
|
+
},
|
|
671
|
+
{
|
|
672
|
+
displayName: 'Max Results',
|
|
673
|
+
name: 'maxResults',
|
|
674
|
+
type: 'number',
|
|
675
|
+
default: 0,
|
|
676
|
+
displayOptions: { show: { resource: ['invoices'], operation: ['findPartnerInvoices'], returnAll: [true] } },
|
|
677
|
+
description: 'Maximum number of results to return. 0 means no limit.',
|
|
678
|
+
},
|
|
679
|
+
{
|
|
680
|
+
displayName: 'Return All',
|
|
681
|
+
name: 'returnAll',
|
|
682
|
+
type: 'boolean',
|
|
683
|
+
default: false,
|
|
684
|
+
displayOptions: { show: { resource: ['invoices'], operation: ['findPartnerInvoiceItems'] } },
|
|
685
|
+
description: 'Whether to return all results (paginate automatically).',
|
|
686
|
+
},
|
|
687
|
+
{
|
|
688
|
+
displayName: 'Max Results',
|
|
689
|
+
name: 'maxResults',
|
|
690
|
+
type: 'number',
|
|
691
|
+
default: 0,
|
|
692
|
+
displayOptions: { show: { resource: ['invoices'], operation: ['findPartnerInvoiceItems'], returnAll: [true] } },
|
|
693
|
+
description: 'Maximum number of results to return. 0 means no limit.',
|
|
694
|
+
},
|
|
695
|
+
{
|
|
696
|
+
displayName: 'Return All',
|
|
697
|
+
name: 'returnAll',
|
|
698
|
+
type: 'boolean',
|
|
699
|
+
default: false,
|
|
700
|
+
displayOptions: { show: { resource: ['invoices'], operation: ['findPartnerDraftInvoiceItems'] } },
|
|
701
|
+
description: 'Whether to return all results (paginate automatically).',
|
|
702
|
+
},
|
|
703
|
+
{
|
|
704
|
+
displayName: 'Max Results',
|
|
705
|
+
name: 'maxResults',
|
|
706
|
+
type: 'number',
|
|
707
|
+
default: 0,
|
|
708
|
+
displayOptions: { show: { resource: ['invoices'], operation: ['findPartnerDraftInvoiceItems'], returnAll: [true] } },
|
|
709
|
+
description: 'Maximum number of results to return. 0 means no limit.',
|
|
710
|
+
},
|
|
711
|
+
{
|
|
712
|
+
displayName: 'Return All',
|
|
713
|
+
name: 'returnAll',
|
|
714
|
+
type: 'boolean',
|
|
715
|
+
default: false,
|
|
716
|
+
displayOptions: { show: { resource: ['usageSummaries'], operation: ['findSubscriptionUsageSummaries'] } },
|
|
717
|
+
description: 'Whether to return all results (paginate automatically).',
|
|
718
|
+
},
|
|
719
|
+
{
|
|
720
|
+
displayName: 'Max Results',
|
|
721
|
+
name: 'maxResults',
|
|
722
|
+
type: 'number',
|
|
723
|
+
default: 0,
|
|
724
|
+
displayOptions: { show: { resource: ['usageSummaries'], operation: ['findSubscriptionUsageSummaries'], returnAll: [true] } },
|
|
725
|
+
description: 'Maximum number of results to return. 0 means no limit.',
|
|
726
|
+
},
|
|
727
|
+
{
|
|
728
|
+
displayName: 'Return All',
|
|
729
|
+
name: 'returnAll',
|
|
730
|
+
type: 'boolean',
|
|
731
|
+
default: false,
|
|
732
|
+
displayOptions: { show: { resource: ['quotes'], operation: ['getQuotesList'] } },
|
|
733
|
+
description: 'Whether to return all results (paginate automatically).',
|
|
734
|
+
},
|
|
735
|
+
{
|
|
736
|
+
displayName: 'Max Results',
|
|
737
|
+
name: 'maxResults',
|
|
738
|
+
type: 'number',
|
|
739
|
+
default: 0,
|
|
740
|
+
displayOptions: { show: { resource: ['quotes'], operation: ['getQuotesList'], returnAll: [true] } },
|
|
741
|
+
description: 'Maximum number of results to return. 0 means no limit.',
|
|
742
|
+
},
|
|
743
|
+
{
|
|
744
|
+
displayName: 'Return All',
|
|
745
|
+
name: 'returnAll',
|
|
746
|
+
type: 'boolean',
|
|
747
|
+
default: false,
|
|
748
|
+
displayOptions: { show: { resource: ['webhooks'], operation: ['Webhooks_query'] } },
|
|
749
|
+
description: 'Whether to return all results (paginate automatically).',
|
|
750
|
+
},
|
|
751
|
+
{
|
|
752
|
+
displayName: 'Max Results',
|
|
753
|
+
name: 'maxResults',
|
|
754
|
+
type: 'number',
|
|
755
|
+
default: 0,
|
|
756
|
+
displayOptions: { show: { resource: ['webhooks'], operation: ['Webhooks_query'], returnAll: [true] } },
|
|
757
|
+
description: 'Maximum number of results to return. 0 means no limit.',
|
|
758
|
+
},
|
|
759
|
+
{
|
|
760
|
+
displayName: 'Return All',
|
|
761
|
+
name: 'returnAll',
|
|
762
|
+
type: 'boolean',
|
|
763
|
+
default: false,
|
|
764
|
+
displayOptions: { show: { resource: ['topicDefinitions'], operation: ['getTopicDefinitions'] } },
|
|
765
|
+
description: 'Whether to return all results (paginate automatically).',
|
|
766
|
+
},
|
|
767
|
+
{
|
|
768
|
+
displayName: 'Max Results',
|
|
769
|
+
name: 'maxResults',
|
|
770
|
+
type: 'number',
|
|
771
|
+
default: 0,
|
|
772
|
+
displayOptions: { show: { resource: ['topicDefinitions'], operation: ['getTopicDefinitions'], returnAll: [true] } },
|
|
773
|
+
description: 'Maximum number of results to return. 0 means no limit.',
|
|
774
|
+
},
|
|
775
|
+
{
|
|
776
|
+
displayName: 'Return All',
|
|
777
|
+
name: 'returnAll',
|
|
778
|
+
type: 'boolean',
|
|
779
|
+
default: false,
|
|
780
|
+
displayOptions: { show: { resource: ['webhookLogs'], operation: ['WebhookLogs_query'] } },
|
|
781
|
+
description: 'Whether to return all results (paginate automatically).',
|
|
782
|
+
},
|
|
783
|
+
{
|
|
784
|
+
displayName: 'Max Results',
|
|
785
|
+
name: 'maxResults',
|
|
786
|
+
type: 'number',
|
|
787
|
+
default: 0,
|
|
788
|
+
displayOptions: { show: { resource: ['webhookLogs'], operation: ['WebhookLogs_query'], returnAll: [true] } },
|
|
789
|
+
description: 'Maximum number of results to return. 0 means no limit.',
|
|
790
|
+
},
|
|
791
|
+
{
|
|
792
|
+
displayName: 'page',
|
|
793
|
+
name: 'page',
|
|
794
|
+
type: 'number',
|
|
795
|
+
default: 0,
|
|
796
|
+
required: false,
|
|
797
|
+
displayOptions: { show: { resource: ['companies'], operation: ['findCompanies'], returnAll: [false] } },
|
|
798
|
+
description: 'The page number to request for in the companies list',
|
|
799
|
+
},
|
|
800
|
+
{
|
|
801
|
+
displayName: 'size',
|
|
802
|
+
name: 'size',
|
|
803
|
+
type: 'number',
|
|
804
|
+
default: 0,
|
|
805
|
+
required: false,
|
|
806
|
+
displayOptions: { show: { resource: ['companies'], operation: ['findCompanies'], returnAll: [false] } },
|
|
807
|
+
description: 'Return this number of company records per page',
|
|
808
|
+
},
|
|
809
|
+
{
|
|
810
|
+
displayName: 'sort',
|
|
811
|
+
name: 'sort',
|
|
812
|
+
type: 'options',
|
|
813
|
+
default: 'name',
|
|
814
|
+
required: false,
|
|
815
|
+
displayOptions: { show: { resource: ['companies'], operation: ['findCompanies'] } },
|
|
816
|
+
description: 'Return companies sorted by this field and direction. Formatted as fieldName,direction - ex. sort=name,desc',
|
|
817
|
+
options: [{ name: 'name', value: 'name' }, { name: 'city', value: 'city' }, { name: 'country', value: 'country' }, { name: 'stateOrProvince', value: 'stateOrProvince' }, { name: 'postalCode', value: 'postalCode' }],
|
|
818
|
+
},
|
|
819
|
+
{
|
|
820
|
+
displayName: 'city',
|
|
821
|
+
name: 'city',
|
|
822
|
+
type: 'string',
|
|
823
|
+
default: '',
|
|
824
|
+
required: false,
|
|
825
|
+
displayOptions: { show: { resource: ['companies'], operation: ['findCompanies'] } },
|
|
826
|
+
description: 'Return only companies matching this ```city``` value',
|
|
827
|
+
},
|
|
828
|
+
{
|
|
829
|
+
displayName: 'country',
|
|
830
|
+
name: 'country',
|
|
831
|
+
type: 'string',
|
|
832
|
+
default: '',
|
|
833
|
+
required: false,
|
|
834
|
+
displayOptions: { show: { resource: ['companies'], operation: ['findCompanies'] } },
|
|
835
|
+
description: 'Return only companies matching this ```country``` value',
|
|
836
|
+
},
|
|
837
|
+
{
|
|
838
|
+
displayName: 'stateOrProvince',
|
|
839
|
+
name: 'stateOrProvince',
|
|
840
|
+
type: 'string',
|
|
841
|
+
default: '',
|
|
842
|
+
required: false,
|
|
843
|
+
displayOptions: { show: { resource: ['companies'], operation: ['findCompanies'] } },
|
|
844
|
+
description: 'Return only companies matching this ```stateOrProvince``` value',
|
|
845
|
+
},
|
|
846
|
+
{
|
|
847
|
+
displayName: 'postalCode',
|
|
848
|
+
name: 'postalCode',
|
|
849
|
+
type: 'string',
|
|
850
|
+
default: '',
|
|
851
|
+
required: false,
|
|
852
|
+
displayOptions: { show: { resource: ['companies'], operation: ['findCompanies'] } },
|
|
853
|
+
description: 'Return only companies matching this ```postalCode``` value',
|
|
854
|
+
},
|
|
855
|
+
{
|
|
856
|
+
displayName: 'selfServiceAllowed',
|
|
857
|
+
name: 'selfServiceAllowed',
|
|
858
|
+
type: 'boolean',
|
|
859
|
+
default: false,
|
|
860
|
+
required: false,
|
|
861
|
+
displayOptions: { show: { resource: ['companies'], operation: ['findCompanies'] } },
|
|
862
|
+
description: 'Return only companies matching this ```selfServiceAllowed``` value',
|
|
863
|
+
},
|
|
864
|
+
{
|
|
865
|
+
displayName: 'billOnBehalfOfEnabled',
|
|
866
|
+
name: 'billOnBehalfOfEnabled',
|
|
867
|
+
type: 'boolean',
|
|
868
|
+
default: false,
|
|
869
|
+
required: false,
|
|
870
|
+
displayOptions: { show: { resource: ['companies'], operation: ['findCompanies'] } },
|
|
871
|
+
description: 'Return only companies matching this ```billOnBehalfOfEnabled``` value',
|
|
872
|
+
},
|
|
873
|
+
{
|
|
874
|
+
displayName: 'orderApprovalRequired',
|
|
875
|
+
name: 'orderApprovalRequired',
|
|
876
|
+
type: 'boolean',
|
|
877
|
+
default: false,
|
|
878
|
+
required: false,
|
|
879
|
+
displayOptions: { show: { resource: ['companies'], operation: ['findCompanies'] } },
|
|
880
|
+
description: 'Return only companies matching this ```orderApprovalRequired``` value',
|
|
881
|
+
},
|
|
882
|
+
{
|
|
883
|
+
displayName: 'status',
|
|
884
|
+
name: 'status',
|
|
885
|
+
type: 'options',
|
|
886
|
+
default: 'Active',
|
|
887
|
+
required: false,
|
|
888
|
+
displayOptions: { show: { resource: ['companies'], operation: ['findCompanies'] } },
|
|
889
|
+
description: 'Return only companies matching this ```status``` value',
|
|
890
|
+
options: [{ name: 'Active', value: 'Active' }, { name: 'Inactive', value: 'Inactive' }, { name: 'Deleted', value: 'Deleted' }],
|
|
891
|
+
},
|
|
892
|
+
{
|
|
893
|
+
displayName: 'companyId',
|
|
894
|
+
name: 'companyId',
|
|
895
|
+
type: 'options',
|
|
896
|
+
typeOptions: { loadOptionsMethod: 'getCompanies' },
|
|
897
|
+
default: '',
|
|
898
|
+
required: true,
|
|
899
|
+
displayOptions: { show: { resource: ['companies'], operation: ['updateCompany'] } },
|
|
900
|
+
description: 'path parameter',
|
|
901
|
+
},
|
|
902
|
+
{
|
|
903
|
+
displayName: 'Body',
|
|
904
|
+
name: 'body',
|
|
905
|
+
type: 'json',
|
|
906
|
+
default: '{}',
|
|
907
|
+
required: false,
|
|
908
|
+
displayOptions: { show: { resource: ['companies'], operation: ['updateCompany'] } },
|
|
909
|
+
description: 'Request body as JSON.',
|
|
910
|
+
},
|
|
911
|
+
{
|
|
912
|
+
displayName: 'companyId',
|
|
913
|
+
name: 'companyId',
|
|
914
|
+
type: 'options',
|
|
915
|
+
typeOptions: { loadOptionsMethod: 'getCompanies' },
|
|
916
|
+
default: '',
|
|
917
|
+
required: true,
|
|
918
|
+
displayOptions: { show: { resource: ['contacts'], operation: ['post_companies_companyId_contacts'] } },
|
|
919
|
+
description: 'path parameter',
|
|
920
|
+
},
|
|
921
|
+
{
|
|
922
|
+
displayName: 'Body',
|
|
923
|
+
name: 'body',
|
|
924
|
+
type: 'json',
|
|
925
|
+
default: '{}',
|
|
926
|
+
required: false,
|
|
927
|
+
displayOptions: { show: { resource: ['contacts'], operation: ['post_companies_companyId_contacts'] } },
|
|
928
|
+
description: 'Request body as JSON.',
|
|
929
|
+
},
|
|
930
|
+
{
|
|
931
|
+
displayName: 'companyId',
|
|
932
|
+
name: 'companyId',
|
|
933
|
+
type: 'options',
|
|
934
|
+
typeOptions: { loadOptionsMethod: 'getCompanies' },
|
|
935
|
+
default: '',
|
|
936
|
+
required: true,
|
|
937
|
+
displayOptions: { show: { resource: ['contacts'], operation: ['delete_companies_companyId_contacts_contactId'] } },
|
|
938
|
+
description: 'path parameter',
|
|
939
|
+
},
|
|
940
|
+
{
|
|
941
|
+
displayName: 'contactId',
|
|
942
|
+
name: 'contactId',
|
|
943
|
+
type: 'options',
|
|
944
|
+
typeOptions: { loadOptionsMethod: 'getContacts' },
|
|
945
|
+
default: '',
|
|
946
|
+
required: true,
|
|
947
|
+
displayOptions: { show: { resource: ['contacts'], operation: ['delete_companies_companyId_contacts_contactId'] } },
|
|
948
|
+
description: 'path parameter',
|
|
949
|
+
},
|
|
950
|
+
{
|
|
951
|
+
displayName: 'companyId',
|
|
952
|
+
name: 'companyId',
|
|
953
|
+
type: 'options',
|
|
954
|
+
typeOptions: { loadOptionsMethod: 'getCompanies' },
|
|
955
|
+
default: '',
|
|
956
|
+
required: true,
|
|
957
|
+
displayOptions: { show: { resource: ['contacts'], operation: ['get_companies_companyId_contacts_contactId'] } },
|
|
958
|
+
description: 'path parameter',
|
|
959
|
+
},
|
|
960
|
+
{
|
|
961
|
+
displayName: 'contactId',
|
|
962
|
+
name: 'contactId',
|
|
963
|
+
type: 'options',
|
|
964
|
+
typeOptions: { loadOptionsMethod: 'getContacts' },
|
|
965
|
+
default: '',
|
|
966
|
+
required: true,
|
|
967
|
+
displayOptions: { show: { resource: ['contacts'], operation: ['get_companies_companyId_contacts_contactId'] } },
|
|
968
|
+
description: 'path parameter',
|
|
969
|
+
},
|
|
970
|
+
{
|
|
971
|
+
displayName: 'page',
|
|
972
|
+
name: 'page',
|
|
973
|
+
type: 'number',
|
|
974
|
+
default: 0,
|
|
975
|
+
required: false,
|
|
976
|
+
displayOptions: { show: { resource: ['contacts'], operation: ['get_companies_companyId_contacts'], returnAll: [false] } },
|
|
977
|
+
description: 'The page number to request for in the contacts list',
|
|
978
|
+
},
|
|
979
|
+
{
|
|
980
|
+
displayName: 'size',
|
|
981
|
+
name: 'size',
|
|
982
|
+
type: 'number',
|
|
983
|
+
default: 0,
|
|
984
|
+
required: false,
|
|
985
|
+
displayOptions: { show: { resource: ['contacts'], operation: ['get_companies_companyId_contacts'], returnAll: [false] } },
|
|
986
|
+
description: 'Return this number of company records per page',
|
|
987
|
+
},
|
|
988
|
+
{
|
|
989
|
+
displayName: 'companyId',
|
|
990
|
+
name: 'companyId',
|
|
991
|
+
type: 'options',
|
|
992
|
+
typeOptions: { loadOptionsMethod: 'getCompanies' },
|
|
993
|
+
default: '',
|
|
994
|
+
required: true,
|
|
995
|
+
displayOptions: { show: { resource: ['contacts'], operation: ['get_companies_companyId_contacts'] } },
|
|
996
|
+
description: 'path parameter',
|
|
997
|
+
},
|
|
998
|
+
{
|
|
999
|
+
displayName: 'companyId',
|
|
1000
|
+
name: 'companyId',
|
|
1001
|
+
type: 'options',
|
|
1002
|
+
typeOptions: { loadOptionsMethod: 'getCompanies' },
|
|
1003
|
+
default: '',
|
|
1004
|
+
required: true,
|
|
1005
|
+
displayOptions: { show: { resource: ['contacts'], operation: ['put_companies_companyId_contacts_contactId'] } },
|
|
1006
|
+
description: 'path parameter',
|
|
1007
|
+
},
|
|
1008
|
+
{
|
|
1009
|
+
displayName: 'contactId',
|
|
1010
|
+
name: 'contactId',
|
|
1011
|
+
type: 'options',
|
|
1012
|
+
typeOptions: { loadOptionsMethod: 'getContacts' },
|
|
1013
|
+
default: '',
|
|
1014
|
+
required: true,
|
|
1015
|
+
displayOptions: { show: { resource: ['contacts'], operation: ['put_companies_companyId_contacts_contactId'] } },
|
|
1016
|
+
description: 'path parameter',
|
|
1017
|
+
},
|
|
1018
|
+
{
|
|
1019
|
+
displayName: 'Body',
|
|
1020
|
+
name: 'body',
|
|
1021
|
+
type: 'json',
|
|
1022
|
+
default: '{}',
|
|
1023
|
+
required: true,
|
|
1024
|
+
displayOptions: { show: { resource: ['contacts'], operation: ['put_companies_companyId_contacts_contactId'] } },
|
|
1025
|
+
description: 'Request body as JSON.',
|
|
1026
|
+
},
|
|
1027
|
+
{
|
|
1028
|
+
displayName: 'invoiceId',
|
|
1029
|
+
name: 'invoiceId',
|
|
1030
|
+
type: 'options',
|
|
1031
|
+
typeOptions: { loadOptionsMethod: 'getInvoices' },
|
|
1032
|
+
default: '',
|
|
1033
|
+
required: true,
|
|
1034
|
+
displayOptions: { show: { resource: ['invoices'], operation: ['getPartnerInvoice'] } },
|
|
1035
|
+
description: 'The invoice id',
|
|
1036
|
+
},
|
|
1037
|
+
{
|
|
1038
|
+
displayName: 'page',
|
|
1039
|
+
name: 'page',
|
|
1040
|
+
type: 'number',
|
|
1041
|
+
default: 0,
|
|
1042
|
+
required: false,
|
|
1043
|
+
displayOptions: { show: { resource: ['invoices'], operation: ['findPartnerDraftInvoiceItems'], returnAll: [false] } },
|
|
1044
|
+
description: 'The page number to request in the draft invoice items list',
|
|
1045
|
+
},
|
|
1046
|
+
{
|
|
1047
|
+
displayName: 'size',
|
|
1048
|
+
name: 'size',
|
|
1049
|
+
type: 'number',
|
|
1050
|
+
default: 0,
|
|
1051
|
+
required: false,
|
|
1052
|
+
displayOptions: { show: { resource: ['invoices'], operation: ['findPartnerDraftInvoiceItems'], returnAll: [false] } },
|
|
1053
|
+
description: 'Returns _this_ number of draft invoice items per page',
|
|
1054
|
+
},
|
|
1055
|
+
{
|
|
1056
|
+
displayName: 'monthOffset',
|
|
1057
|
+
name: 'monthOffset',
|
|
1058
|
+
type: 'options',
|
|
1059
|
+
default: '0',
|
|
1060
|
+
required: false,
|
|
1061
|
+
displayOptions: { show: { resource: ['invoices'], operation: ['findPartnerDraftInvoiceItems'] } },
|
|
1062
|
+
description: 'Number of months from current to return draft items for. 0 = current month, 1 = next month. Only values 0 and 1 are currently supported. If omitted, defaults to 1 (next month).',
|
|
1063
|
+
options: [{ name: '0', value: '0' }, { name: '1', value: '1' }],
|
|
1064
|
+
},
|
|
1065
|
+
{
|
|
1066
|
+
displayName: 'companyId',
|
|
1067
|
+
name: 'companyId',
|
|
1068
|
+
type: 'options',
|
|
1069
|
+
typeOptions: { loadOptionsMethod: 'getCompanies' },
|
|
1070
|
+
default: '',
|
|
1071
|
+
required: false,
|
|
1072
|
+
displayOptions: { show: { resource: ['invoices'], operation: ['findPartnerDraftInvoiceItems'] } },
|
|
1073
|
+
description: 'Filter draft items to a specific company.',
|
|
1074
|
+
},
|
|
1075
|
+
{
|
|
1076
|
+
displayName: 'invoiceId',
|
|
1077
|
+
name: 'invoiceId',
|
|
1078
|
+
type: 'options',
|
|
1079
|
+
typeOptions: { loadOptionsMethod: 'getInvoices' },
|
|
1080
|
+
default: '',
|
|
1081
|
+
required: true,
|
|
1082
|
+
displayOptions: { show: { resource: ['invoices'], operation: ['findPartnerInvoiceItems'], returnAll: [false] } },
|
|
1083
|
+
description: 'The invoice id',
|
|
1084
|
+
},
|
|
1085
|
+
{
|
|
1086
|
+
displayName: 'page',
|
|
1087
|
+
name: 'page',
|
|
1088
|
+
type: 'number',
|
|
1089
|
+
default: 0,
|
|
1090
|
+
required: false,
|
|
1091
|
+
displayOptions: { show: { resource: ['invoices'], operation: ['findPartnerInvoiceItems'], returnAll: [false] } },
|
|
1092
|
+
description: 'The page number to request in the invoices items list',
|
|
1093
|
+
},
|
|
1094
|
+
{
|
|
1095
|
+
displayName: 'size',
|
|
1096
|
+
name: 'size',
|
|
1097
|
+
type: 'number',
|
|
1098
|
+
default: 0,
|
|
1099
|
+
required: false,
|
|
1100
|
+
displayOptions: { show: { resource: ['invoices'], operation: ['findPartnerInvoiceItems'], returnAll: [false] } },
|
|
1101
|
+
description: 'Returns _this_ number of invoices items per page',
|
|
1102
|
+
},
|
|
1103
|
+
{
|
|
1104
|
+
displayName: 'page',
|
|
1105
|
+
name: 'page',
|
|
1106
|
+
type: 'number',
|
|
1107
|
+
default: 0,
|
|
1108
|
+
required: false,
|
|
1109
|
+
displayOptions: { show: { resource: ['invoices'], operation: ['findPartnerInvoices'], returnAll: [false] } },
|
|
1110
|
+
description: 'The page number to request in the invoices list',
|
|
1111
|
+
},
|
|
1112
|
+
{
|
|
1113
|
+
displayName: 'size',
|
|
1114
|
+
name: 'size',
|
|
1115
|
+
type: 'number',
|
|
1116
|
+
default: 0,
|
|
1117
|
+
required: false,
|
|
1118
|
+
displayOptions: { show: { resource: ['invoices'], operation: ['findPartnerInvoices'], returnAll: [false] } },
|
|
1119
|
+
description: 'Returns _this_ number of invoices per page',
|
|
1120
|
+
},
|
|
1121
|
+
{
|
|
1122
|
+
displayName: 'sort',
|
|
1123
|
+
name: 'sort',
|
|
1124
|
+
type: 'options',
|
|
1125
|
+
default: 'invoiceDate',
|
|
1126
|
+
required: false,
|
|
1127
|
+
displayOptions: { show: { resource: ['invoices'], operation: ['findPartnerInvoices'] } },
|
|
1128
|
+
description: 'Return invoices sorted by this field and direction Formatted as fieldName,direction - ex. sort=invoiceDate,desc',
|
|
1129
|
+
options: [{ name: 'invoiceDate', value: 'invoiceDate' }, { name: 'dueDate', value: 'dueDate' }, { name: 'status', value: 'status' }, { name: 'partnerName', value: 'partnerName' }, { name: 'total', value: 'total' }, { name: 'balance', value: 'balance' }, { name: 'carriedBalance', value: 'carriedBalance' }],
|
|
1130
|
+
},
|
|
1131
|
+
{
|
|
1132
|
+
displayName: 'status',
|
|
1133
|
+
name: 'status',
|
|
1134
|
+
type: 'options',
|
|
1135
|
+
default: 'Unpaid',
|
|
1136
|
+
required: false,
|
|
1137
|
+
displayOptions: { show: { resource: ['invoices'], operation: ['findPartnerInvoices'] } },
|
|
1138
|
+
description: 'Return only invoices matching this ```status``` value',
|
|
1139
|
+
options: [{ name: 'Unpaid', value: 'Unpaid' }, { name: 'Paid', value: 'Paid' }, { name: 'Void', value: 'Void' }, { name: 'Carried', value: 'Carried' }, { name: 'Nothing Due', value: 'Nothing Due' }, { name: 'Credited', value: 'Credited' }],
|
|
1140
|
+
},
|
|
1141
|
+
{
|
|
1142
|
+
displayName: 'invoiceDate',
|
|
1143
|
+
name: 'invoiceDate',
|
|
1144
|
+
type: 'string',
|
|
1145
|
+
default: '',
|
|
1146
|
+
required: false,
|
|
1147
|
+
displayOptions: { show: { resource: ['invoices'], operation: ['findPartnerInvoices'] } },
|
|
1148
|
+
description: 'Return only invoices matching this ```invoiceDate``` value',
|
|
1149
|
+
},
|
|
1150
|
+
{
|
|
1151
|
+
displayName: 'invoiceDateRangeStart',
|
|
1152
|
+
name: 'invoiceDateRangeStart',
|
|
1153
|
+
type: 'string',
|
|
1154
|
+
default: '',
|
|
1155
|
+
required: false,
|
|
1156
|
+
displayOptions: { show: { resource: ['invoices'], operation: ['findPartnerInvoices'] } },
|
|
1157
|
+
description: 'Return only invoices with an ```invoiceDate``` greater than or equal to this date',
|
|
1158
|
+
},
|
|
1159
|
+
{
|
|
1160
|
+
displayName: 'invoiceDateRangeEnd',
|
|
1161
|
+
name: 'invoiceDateRangeEnd',
|
|
1162
|
+
type: 'string',
|
|
1163
|
+
default: '',
|
|
1164
|
+
required: false,
|
|
1165
|
+
displayOptions: { show: { resource: ['invoices'], operation: ['findPartnerInvoices'] } },
|
|
1166
|
+
description: 'Return only invoices with an ```invoiceDate``` less than or equal to this date',
|
|
1167
|
+
},
|
|
1168
|
+
{
|
|
1169
|
+
displayName: 'dueDate',
|
|
1170
|
+
name: 'dueDate',
|
|
1171
|
+
type: 'string',
|
|
1172
|
+
default: '',
|
|
1173
|
+
required: false,
|
|
1174
|
+
displayOptions: { show: { resource: ['invoices'], operation: ['findPartnerInvoices'] } },
|
|
1175
|
+
description: 'Return only invoices matching this ```dueDate``` value',
|
|
1176
|
+
},
|
|
1177
|
+
{
|
|
1178
|
+
displayName: 'total',
|
|
1179
|
+
name: 'total',
|
|
1180
|
+
type: 'number',
|
|
1181
|
+
default: 0,
|
|
1182
|
+
required: false,
|
|
1183
|
+
displayOptions: { show: { resource: ['invoices'], operation: ['findPartnerInvoices'] } },
|
|
1184
|
+
description: 'Return only invoices matching this ```total``` value',
|
|
1185
|
+
},
|
|
1186
|
+
{
|
|
1187
|
+
displayName: 'balance',
|
|
1188
|
+
name: 'balance',
|
|
1189
|
+
type: 'number',
|
|
1190
|
+
default: 0,
|
|
1191
|
+
required: false,
|
|
1192
|
+
displayOptions: { show: { resource: ['invoices'], operation: ['findPartnerInvoices'] } },
|
|
1193
|
+
description: 'Return only invoices matching this ```balance``` value',
|
|
1194
|
+
},
|
|
1195
|
+
{
|
|
1196
|
+
displayName: 'carriedBalance',
|
|
1197
|
+
name: 'carriedBalance',
|
|
1198
|
+
type: 'number',
|
|
1199
|
+
default: 0,
|
|
1200
|
+
required: false,
|
|
1201
|
+
displayOptions: { show: { resource: ['invoices'], operation: ['findPartnerInvoices'] } },
|
|
1202
|
+
description: 'Return only invoices matching this ```carriedBalance``` value',
|
|
1203
|
+
},
|
|
1204
|
+
{
|
|
1205
|
+
displayName: 'companyId',
|
|
1206
|
+
name: 'companyId',
|
|
1207
|
+
type: 'options',
|
|
1208
|
+
typeOptions: { loadOptionsMethod: 'getCompanies' },
|
|
1209
|
+
default: '',
|
|
1210
|
+
required: false,
|
|
1211
|
+
displayOptions: { show: { resource: ['invoices'], operation: ['findPartnerInvoices'] } },
|
|
1212
|
+
description: 'Return only invoices matching this ```companyId``` value',
|
|
1213
|
+
},
|
|
1214
|
+
{
|
|
1215
|
+
displayName: 'Body',
|
|
1216
|
+
name: 'body',
|
|
1217
|
+
type: 'json',
|
|
1218
|
+
default: '{}',
|
|
1219
|
+
required: true,
|
|
1220
|
+
displayOptions: { show: { resource: ['libraryAttachments'], operation: ['addQuoteAttachmentsToLibrary'] } },
|
|
1221
|
+
description: 'Request body as JSON.',
|
|
1222
|
+
},
|
|
1223
|
+
{
|
|
1224
|
+
displayName: 'attachmentId',
|
|
1225
|
+
name: 'attachmentId',
|
|
1226
|
+
type: 'string',
|
|
1227
|
+
default: '',
|
|
1228
|
+
required: true,
|
|
1229
|
+
displayOptions: { show: { resource: ['libraryAttachments'], operation: ['deleteSingleLibraryAttachment'] } },
|
|
1230
|
+
description: 'path parameter',
|
|
1231
|
+
},
|
|
1232
|
+
{
|
|
1233
|
+
displayName: 'attachmentId',
|
|
1234
|
+
name: 'attachmentId',
|
|
1235
|
+
type: 'string',
|
|
1236
|
+
default: '',
|
|
1237
|
+
required: true,
|
|
1238
|
+
displayOptions: { show: { resource: ['libraryAttachments'], operation: ['getLibraryAttachmentMetadata'] } },
|
|
1239
|
+
description: 'path parameter',
|
|
1240
|
+
},
|
|
1241
|
+
{
|
|
1242
|
+
displayName: 'download',
|
|
1243
|
+
name: 'download',
|
|
1244
|
+
type: 'options',
|
|
1245
|
+
default: 'true',
|
|
1246
|
+
required: false,
|
|
1247
|
+
displayOptions: { show: { resource: ['libraryAttachments'], operation: ['getLibraryAttachmentMetadata'] } },
|
|
1248
|
+
description: 'Must be set to true to download the file.',
|
|
1249
|
+
options: [{ name: 'true', value: 'true' }],
|
|
1250
|
+
},
|
|
1251
|
+
{
|
|
1252
|
+
displayName: 'attachmentId',
|
|
1253
|
+
name: 'attachmentId',
|
|
1254
|
+
type: 'string',
|
|
1255
|
+
default: '',
|
|
1256
|
+
required: true,
|
|
1257
|
+
displayOptions: { show: { resource: ['libraryAttachments'], operation: ['replaceLibraryAttachment'] } },
|
|
1258
|
+
description: 'path parameter',
|
|
1259
|
+
},
|
|
1260
|
+
{
|
|
1261
|
+
displayName: 'Body',
|
|
1262
|
+
name: 'body',
|
|
1263
|
+
type: 'json',
|
|
1264
|
+
default: '{}',
|
|
1265
|
+
required: false,
|
|
1266
|
+
displayOptions: { show: { resource: ['libraryAttachments'], operation: ['replaceLibraryAttachment'] } },
|
|
1267
|
+
description: 'Request body as JSON.',
|
|
1268
|
+
},
|
|
1269
|
+
{
|
|
1270
|
+
displayName: 'Body',
|
|
1271
|
+
name: 'body',
|
|
1272
|
+
type: 'json',
|
|
1273
|
+
default: '{}',
|
|
1274
|
+
required: true,
|
|
1275
|
+
displayOptions: { show: { resource: ['libraryAttachments'], operation: ['updateLibraryAttachments'] } },
|
|
1276
|
+
description: 'Request body as JSON.',
|
|
1277
|
+
},
|
|
1278
|
+
{
|
|
1279
|
+
displayName: 'Body',
|
|
1280
|
+
name: 'body',
|
|
1281
|
+
type: 'json',
|
|
1282
|
+
default: '{}',
|
|
1283
|
+
required: false,
|
|
1284
|
+
displayOptions: { show: { resource: ['libraryAttachments'], operation: ['uploadAttachmentToLibrary'] } },
|
|
1285
|
+
description: 'Request body as JSON.',
|
|
1286
|
+
},
|
|
1287
|
+
{
|
|
1288
|
+
displayName: 'isMock',
|
|
1289
|
+
name: 'isMock',
|
|
1290
|
+
type: 'boolean',
|
|
1291
|
+
default: false,
|
|
1292
|
+
required: false,
|
|
1293
|
+
displayOptions: { show: { resource: ['orders'], operation: ['createOrder'] } },
|
|
1294
|
+
description: 'Perform validations only. Skip any interactions with the database.',
|
|
1295
|
+
},
|
|
1296
|
+
{
|
|
1297
|
+
displayName: 'Body',
|
|
1298
|
+
name: 'body',
|
|
1299
|
+
type: 'json',
|
|
1300
|
+
default: '{}',
|
|
1301
|
+
required: false,
|
|
1302
|
+
displayOptions: { show: { resource: ['orders'], operation: ['createOrder'] } },
|
|
1303
|
+
description: 'Request body as JSON.',
|
|
1304
|
+
},
|
|
1305
|
+
{
|
|
1306
|
+
displayName: 'orderId',
|
|
1307
|
+
name: 'orderId',
|
|
1308
|
+
type: 'string',
|
|
1309
|
+
default: '',
|
|
1310
|
+
required: true,
|
|
1311
|
+
displayOptions: { show: { resource: ['orders'], operation: ['findOrdersByOrderId'] } },
|
|
1312
|
+
description: 'The unique identifier for an order record',
|
|
1313
|
+
},
|
|
1314
|
+
{
|
|
1315
|
+
displayName: 'page',
|
|
1316
|
+
name: 'page',
|
|
1317
|
+
type: 'number',
|
|
1318
|
+
default: 0,
|
|
1319
|
+
required: false,
|
|
1320
|
+
displayOptions: { show: { resource: ['orders'], operation: ['findOrders'], returnAll: [false] } },
|
|
1321
|
+
description: 'The page number to request for in the orders list',
|
|
1322
|
+
},
|
|
1323
|
+
{
|
|
1324
|
+
displayName: 'size',
|
|
1325
|
+
name: 'size',
|
|
1326
|
+
type: 'number',
|
|
1327
|
+
default: 0,
|
|
1328
|
+
required: false,
|
|
1329
|
+
displayOptions: { show: { resource: ['orders'], operation: ['findOrders'], returnAll: [false] } },
|
|
1330
|
+
description: 'query parameter',
|
|
1331
|
+
},
|
|
1332
|
+
{
|
|
1333
|
+
displayName: 'companyId',
|
|
1334
|
+
name: 'companyId',
|
|
1335
|
+
type: 'options',
|
|
1336
|
+
typeOptions: { loadOptionsMethod: 'getCompanies' },
|
|
1337
|
+
default: '',
|
|
1338
|
+
required: false,
|
|
1339
|
+
displayOptions: { show: { resource: ['orders'], operation: ['findOrders'] } },
|
|
1340
|
+
description: 'The company id to filter on',
|
|
1341
|
+
},
|
|
1342
|
+
{
|
|
1343
|
+
displayName: 'attachmentId',
|
|
1344
|
+
name: 'attachmentId',
|
|
1345
|
+
type: 'string',
|
|
1346
|
+
default: '',
|
|
1347
|
+
required: true,
|
|
1348
|
+
displayOptions: { show: { resource: ['preferenceAttachments'], operation: ['deletePreferenceAttachment'] } },
|
|
1349
|
+
description: 'path parameter',
|
|
1350
|
+
},
|
|
1351
|
+
{
|
|
1352
|
+
displayName: 'Body',
|
|
1353
|
+
name: 'body',
|
|
1354
|
+
type: 'json',
|
|
1355
|
+
default: '{}',
|
|
1356
|
+
required: true,
|
|
1357
|
+
displayOptions: { show: { resource: ['preferenceAttachments'], operation: ['uploadPreferencesAttachments'] } },
|
|
1358
|
+
description: 'Request body as JSON.',
|
|
1359
|
+
},
|
|
1360
|
+
{
|
|
1361
|
+
displayName: 'productId',
|
|
1362
|
+
name: 'productId',
|
|
1363
|
+
type: 'options',
|
|
1364
|
+
typeOptions: { loadOptionsMethod: 'getProducts' },
|
|
1365
|
+
default: '',
|
|
1366
|
+
required: true,
|
|
1367
|
+
displayOptions: { show: { resource: ['products'], operation: ['findPricingByProductId'] } },
|
|
1368
|
+
description: 'The product id',
|
|
1369
|
+
},
|
|
1370
|
+
{
|
|
1371
|
+
displayName: 'companyId',
|
|
1372
|
+
name: 'companyId',
|
|
1373
|
+
type: 'options',
|
|
1374
|
+
typeOptions: { loadOptionsMethod: 'getCompanies' },
|
|
1375
|
+
default: '',
|
|
1376
|
+
required: false,
|
|
1377
|
+
displayOptions: { show: { resource: ['products'], operation: ['findPricingByProductId'] } },
|
|
1378
|
+
description: 'Use the companyId in the query to see company-specific pricing',
|
|
1379
|
+
},
|
|
1380
|
+
{
|
|
1381
|
+
displayName: 'productId',
|
|
1382
|
+
name: 'productId',
|
|
1383
|
+
type: 'options',
|
|
1384
|
+
typeOptions: { loadOptionsMethod: 'getProducts' },
|
|
1385
|
+
default: '',
|
|
1386
|
+
required: true,
|
|
1387
|
+
displayOptions: { show: { resource: ['products'], operation: ['findProductByProductId'] } },
|
|
1388
|
+
description: 'path parameter',
|
|
1389
|
+
},
|
|
1390
|
+
{
|
|
1391
|
+
displayName: 'productId',
|
|
1392
|
+
name: 'productId',
|
|
1393
|
+
type: 'options',
|
|
1394
|
+
typeOptions: { loadOptionsMethod: 'getProducts' },
|
|
1395
|
+
default: '',
|
|
1396
|
+
required: true,
|
|
1397
|
+
displayOptions: { show: { resource: ['products'], operation: ['findProductDependenciesByProductId'] } },
|
|
1398
|
+
description: 'path parameter',
|
|
1399
|
+
},
|
|
1400
|
+
{
|
|
1401
|
+
displayName: 'productId',
|
|
1402
|
+
name: 'productId',
|
|
1403
|
+
type: 'options',
|
|
1404
|
+
typeOptions: { loadOptionsMethod: 'getProducts' },
|
|
1405
|
+
default: '',
|
|
1406
|
+
required: true,
|
|
1407
|
+
displayOptions: { show: { resource: ['products'], operation: ['findProvisionDetailsByProductId'] } },
|
|
1408
|
+
description: 'path parameter',
|
|
1409
|
+
},
|
|
1410
|
+
{
|
|
1411
|
+
displayName: 'page',
|
|
1412
|
+
name: 'page',
|
|
1413
|
+
type: 'number',
|
|
1414
|
+
default: 0,
|
|
1415
|
+
required: false,
|
|
1416
|
+
displayOptions: { show: { resource: ['products'], operation: ['findAllProducts'], returnAll: [false] } },
|
|
1417
|
+
description: 'The page number to request for in the products list',
|
|
1418
|
+
},
|
|
1419
|
+
{
|
|
1420
|
+
displayName: 'size',
|
|
1421
|
+
name: 'size',
|
|
1422
|
+
type: 'number',
|
|
1423
|
+
default: 0,
|
|
1424
|
+
required: false,
|
|
1425
|
+
displayOptions: { show: { resource: ['products'], operation: ['findAllProducts'], returnAll: [false] } },
|
|
1426
|
+
description: 'Return this number of products per page',
|
|
1427
|
+
},
|
|
1428
|
+
{
|
|
1429
|
+
displayName: 'sort',
|
|
1430
|
+
name: 'sort',
|
|
1431
|
+
type: 'options',
|
|
1432
|
+
default: 'name',
|
|
1433
|
+
required: false,
|
|
1434
|
+
displayOptions: { show: { resource: ['products'], operation: ['findAllProducts'] } },
|
|
1435
|
+
description: 'Return products sorted by the field and direction specified. Formatted as fieldName, direction - ex. sort=name,desc',
|
|
1436
|
+
options: [{ name: 'name', value: 'name' }, { name: 'vendor', value: 'vendor' }],
|
|
1437
|
+
},
|
|
1438
|
+
{
|
|
1439
|
+
displayName: 'search',
|
|
1440
|
+
name: 'search',
|
|
1441
|
+
type: 'string',
|
|
1442
|
+
default: '',
|
|
1443
|
+
required: false,
|
|
1444
|
+
displayOptions: { show: { resource: ['products'], operation: ['findAllProducts'] } },
|
|
1445
|
+
description: 'Search on fields like name, vendor, SKU and ID.',
|
|
1446
|
+
},
|
|
1447
|
+
{
|
|
1448
|
+
displayName: 'vendorName',
|
|
1449
|
+
name: 'vendorName',
|
|
1450
|
+
type: 'string',
|
|
1451
|
+
default: '',
|
|
1452
|
+
required: false,
|
|
1453
|
+
displayOptions: { show: { resource: ['products'], operation: ['findAllProducts'] } },
|
|
1454
|
+
description: 'Return only products matching the specified vendor name',
|
|
1455
|
+
},
|
|
1456
|
+
{
|
|
1457
|
+
displayName: 'provisionRequestId',
|
|
1458
|
+
name: 'provisionRequestId',
|
|
1459
|
+
type: 'string',
|
|
1460
|
+
default: '',
|
|
1461
|
+
required: true,
|
|
1462
|
+
displayOptions: { show: { resource: ['provisionAttempts'], operation: ['createAttemptForRequest'] } },
|
|
1463
|
+
description: 'path parameter',
|
|
1464
|
+
},
|
|
1465
|
+
{
|
|
1466
|
+
displayName: 'provisionRequestId',
|
|
1467
|
+
name: 'provisionRequestId',
|
|
1468
|
+
type: 'string',
|
|
1469
|
+
default: '',
|
|
1470
|
+
required: true,
|
|
1471
|
+
displayOptions: { show: { resource: ['provisionAttempts'], operation: ['getAllProvisionAttempts'] } },
|
|
1472
|
+
description: 'path parameter',
|
|
1473
|
+
},
|
|
1474
|
+
{
|
|
1475
|
+
displayName: 'provisionDetailId',
|
|
1476
|
+
name: 'provisionDetailId',
|
|
1477
|
+
type: 'string',
|
|
1478
|
+
default: '',
|
|
1479
|
+
required: false,
|
|
1480
|
+
displayOptions: { show: { resource: ['provisionAttempts'], operation: ['getAllProvisionAttempts'] } },
|
|
1481
|
+
description: 'query parameter',
|
|
1482
|
+
},
|
|
1483
|
+
{
|
|
1484
|
+
displayName: 'provisionRequestId',
|
|
1485
|
+
name: 'provisionRequestId',
|
|
1486
|
+
type: 'string',
|
|
1487
|
+
default: '',
|
|
1488
|
+
required: true,
|
|
1489
|
+
displayOptions: { show: { resource: ['provisionAttempts'], operation: ['getLatestProvisionAttempt'] } },
|
|
1490
|
+
description: 'path parameter',
|
|
1491
|
+
},
|
|
1492
|
+
{
|
|
1493
|
+
displayName: 'provisionRequestId',
|
|
1494
|
+
name: 'provisionRequestId',
|
|
1495
|
+
type: 'string',
|
|
1496
|
+
default: '',
|
|
1497
|
+
required: true,
|
|
1498
|
+
displayOptions: { show: { resource: ['provisionAttempts'], operation: ['getOneProvisionAttempt'] } },
|
|
1499
|
+
description: 'path parameter',
|
|
1500
|
+
},
|
|
1501
|
+
{
|
|
1502
|
+
displayName: 'provisionAttemptId',
|
|
1503
|
+
name: 'provisionAttemptId',
|
|
1504
|
+
type: 'string',
|
|
1505
|
+
default: '',
|
|
1506
|
+
required: true,
|
|
1507
|
+
displayOptions: { show: { resource: ['provisionAttempts'], operation: ['getOneProvisionAttempt'] } },
|
|
1508
|
+
description: 'path parameter',
|
|
1509
|
+
},
|
|
1510
|
+
{
|
|
1511
|
+
displayName: 'provisionRequestId',
|
|
1512
|
+
name: 'provisionRequestId',
|
|
1513
|
+
type: 'string',
|
|
1514
|
+
default: '',
|
|
1515
|
+
required: true,
|
|
1516
|
+
displayOptions: { show: { resource: ['provisionDetails'], operation: ['getAllProvisionDetails'] } },
|
|
1517
|
+
description: 'path parameter',
|
|
1518
|
+
},
|
|
1519
|
+
{
|
|
1520
|
+
displayName: 'provisionRequestId',
|
|
1521
|
+
name: 'provisionRequestId',
|
|
1522
|
+
type: 'string',
|
|
1523
|
+
default: '',
|
|
1524
|
+
required: true,
|
|
1525
|
+
displayOptions: { show: { resource: ['provisionDetails'], operation: ['getLatestProvisionDetail'] } },
|
|
1526
|
+
description: 'path parameter',
|
|
1527
|
+
},
|
|
1528
|
+
{
|
|
1529
|
+
displayName: 'provisionRequestId',
|
|
1530
|
+
name: 'provisionRequestId',
|
|
1531
|
+
type: 'string',
|
|
1532
|
+
default: '',
|
|
1533
|
+
required: true,
|
|
1534
|
+
displayOptions: { show: { resource: ['provisionDetails'], operation: ['getOneProvisionDetail'] } },
|
|
1535
|
+
description: 'path parameter',
|
|
1536
|
+
},
|
|
1537
|
+
{
|
|
1538
|
+
displayName: 'provisionDetailId',
|
|
1539
|
+
name: 'provisionDetailId',
|
|
1540
|
+
type: 'string',
|
|
1541
|
+
default: '',
|
|
1542
|
+
required: true,
|
|
1543
|
+
displayOptions: { show: { resource: ['provisionDetails'], operation: ['getOneProvisionDetail'] } },
|
|
1544
|
+
description: 'path parameter',
|
|
1545
|
+
},
|
|
1546
|
+
{
|
|
1547
|
+
displayName: 'provisionRequestId',
|
|
1548
|
+
name: 'provisionRequestId',
|
|
1549
|
+
type: 'string',
|
|
1550
|
+
default: '',
|
|
1551
|
+
required: true,
|
|
1552
|
+
displayOptions: { show: { resource: ['provisionRequests'], operation: ['getOneProvisionRequest'] } },
|
|
1553
|
+
description: 'path parameter',
|
|
1554
|
+
},
|
|
1555
|
+
{
|
|
1556
|
+
displayName: 'provisionRequestId',
|
|
1557
|
+
name: 'provisionRequestId',
|
|
1558
|
+
type: 'string',
|
|
1559
|
+
default: '',
|
|
1560
|
+
required: true,
|
|
1561
|
+
displayOptions: { show: { resource: ['provisionResults'], operation: ['createProvisionResult'] } },
|
|
1562
|
+
description: 'path parameter',
|
|
1563
|
+
},
|
|
1564
|
+
{
|
|
1565
|
+
displayName: 'Body',
|
|
1566
|
+
name: 'body',
|
|
1567
|
+
type: 'json',
|
|
1568
|
+
default: '{}',
|
|
1569
|
+
required: true,
|
|
1570
|
+
displayOptions: { show: { resource: ['provisionResults'], operation: ['createProvisionResult'] } },
|
|
1571
|
+
description: 'Request body as JSON.',
|
|
1572
|
+
},
|
|
1573
|
+
{
|
|
1574
|
+
displayName: 'provisionRequestId',
|
|
1575
|
+
name: 'provisionRequestId',
|
|
1576
|
+
type: 'string',
|
|
1577
|
+
default: '',
|
|
1578
|
+
required: true,
|
|
1579
|
+
displayOptions: { show: { resource: ['provisionResults'], operation: ['getAllProvisionResults'] } },
|
|
1580
|
+
description: 'path parameter',
|
|
1581
|
+
},
|
|
1582
|
+
{
|
|
1583
|
+
displayName: 'provisionAttemptId',
|
|
1584
|
+
name: 'provisionAttemptId',
|
|
1585
|
+
type: 'string',
|
|
1586
|
+
default: '',
|
|
1587
|
+
required: false,
|
|
1588
|
+
displayOptions: { show: { resource: ['provisionResults'], operation: ['getAllProvisionResults'] } },
|
|
1589
|
+
description: 'query parameter',
|
|
1590
|
+
},
|
|
1591
|
+
{
|
|
1592
|
+
displayName: 'provisionRequestId',
|
|
1593
|
+
name: 'provisionRequestId',
|
|
1594
|
+
type: 'string',
|
|
1595
|
+
default: '',
|
|
1596
|
+
required: true,
|
|
1597
|
+
displayOptions: { show: { resource: ['provisionResults'], operation: ['getLatestProvisionResult'] } },
|
|
1598
|
+
description: 'path parameter',
|
|
1599
|
+
},
|
|
1600
|
+
{
|
|
1601
|
+
displayName: 'provisionRequestId',
|
|
1602
|
+
name: 'provisionRequestId',
|
|
1603
|
+
type: 'string',
|
|
1604
|
+
default: '',
|
|
1605
|
+
required: true,
|
|
1606
|
+
displayOptions: { show: { resource: ['provisionResults'], operation: ['getOneProvisionResult'] } },
|
|
1607
|
+
description: 'path parameter',
|
|
1608
|
+
},
|
|
1609
|
+
{
|
|
1610
|
+
displayName: 'provisionResultId',
|
|
1611
|
+
name: 'provisionResultId',
|
|
1612
|
+
type: 'string',
|
|
1613
|
+
default: '',
|
|
1614
|
+
required: true,
|
|
1615
|
+
displayOptions: { show: { resource: ['provisionResults'], operation: ['getOneProvisionResult'] } },
|
|
1616
|
+
description: 'path parameter',
|
|
1617
|
+
},
|
|
1618
|
+
{
|
|
1619
|
+
displayName: 'provisionerId',
|
|
1620
|
+
name: 'provisionerId',
|
|
1621
|
+
type: 'string',
|
|
1622
|
+
default: '',
|
|
1623
|
+
required: true,
|
|
1624
|
+
displayOptions: { show: { resource: ['provisioners'], operation: ['createWebhookForProvisioner'] } },
|
|
1625
|
+
description: 'path parameter',
|
|
1626
|
+
},
|
|
1627
|
+
{
|
|
1628
|
+
displayName: 'Body',
|
|
1629
|
+
name: 'body',
|
|
1630
|
+
type: 'json',
|
|
1631
|
+
default: '{}',
|
|
1632
|
+
required: true,
|
|
1633
|
+
displayOptions: { show: { resource: ['provisioners'], operation: ['createWebhookForProvisioner'] } },
|
|
1634
|
+
description: 'Request body as JSON.',
|
|
1635
|
+
},
|
|
1636
|
+
{
|
|
1637
|
+
displayName: 'provisionerId',
|
|
1638
|
+
name: 'provisionerId',
|
|
1639
|
+
type: 'string',
|
|
1640
|
+
default: '',
|
|
1641
|
+
required: true,
|
|
1642
|
+
displayOptions: { show: { resource: ['provisioners'], operation: ['getAllWebhooksForProvisioner'] } },
|
|
1643
|
+
description: 'path parameter',
|
|
1644
|
+
},
|
|
1645
|
+
{
|
|
1646
|
+
displayName: 'provisionerId',
|
|
1647
|
+
name: 'provisionerId',
|
|
1648
|
+
type: 'string',
|
|
1649
|
+
default: '',
|
|
1650
|
+
required: true,
|
|
1651
|
+
displayOptions: { show: { resource: ['provisioners'], operation: ['getLatestWebhookForProvisioner'] } },
|
|
1652
|
+
description: 'path parameter',
|
|
1653
|
+
},
|
|
1654
|
+
{
|
|
1655
|
+
displayName: 'provisionerId',
|
|
1656
|
+
name: 'provisionerId',
|
|
1657
|
+
type: 'string',
|
|
1658
|
+
default: '',
|
|
1659
|
+
required: true,
|
|
1660
|
+
displayOptions: { show: { resource: ['provisioners'], operation: ['getOneProvisioner'] } },
|
|
1661
|
+
description: 'path parameter',
|
|
1662
|
+
},
|
|
1663
|
+
{
|
|
1664
|
+
displayName: 'provisionerId',
|
|
1665
|
+
name: 'provisionerId',
|
|
1666
|
+
type: 'string',
|
|
1667
|
+
default: '',
|
|
1668
|
+
required: true,
|
|
1669
|
+
displayOptions: { show: { resource: ['provisioners'], operation: ['getOneWebhookForProvisioner'] } },
|
|
1670
|
+
description: 'path parameter',
|
|
1671
|
+
},
|
|
1672
|
+
{
|
|
1673
|
+
displayName: 'webhookId',
|
|
1674
|
+
name: 'webhookId',
|
|
1675
|
+
type: 'options',
|
|
1676
|
+
typeOptions: { loadOptionsMethod: 'getWebhooks' },
|
|
1677
|
+
default: '',
|
|
1678
|
+
required: true,
|
|
1679
|
+
displayOptions: { show: { resource: ['provisioners'], operation: ['getOneWebhookForProvisioner'] } },
|
|
1680
|
+
description: 'path parameter',
|
|
1681
|
+
},
|
|
1682
|
+
{
|
|
1683
|
+
displayName: 'Body',
|
|
1684
|
+
name: 'body',
|
|
1685
|
+
type: 'json',
|
|
1686
|
+
default: '{}',
|
|
1687
|
+
required: false,
|
|
1688
|
+
displayOptions: { show: { resource: ['provisioningSimulations'], operation: ['createOrderEvent'] } },
|
|
1689
|
+
description: 'Request body as JSON.',
|
|
1690
|
+
},
|
|
1691
|
+
{
|
|
1692
|
+
displayName: 'quoteId',
|
|
1693
|
+
name: 'quoteId',
|
|
1694
|
+
type: 'options',
|
|
1695
|
+
typeOptions: { loadOptionsMethod: 'getQuotes' },
|
|
1696
|
+
default: '',
|
|
1697
|
+
required: true,
|
|
1698
|
+
displayOptions: { show: { resource: ['quoteAccessList'], operation: ['addQuoteAccessListEntry'] } },
|
|
1699
|
+
description: 'path parameter',
|
|
1700
|
+
},
|
|
1701
|
+
{
|
|
1702
|
+
displayName: 'Body',
|
|
1703
|
+
name: 'body',
|
|
1704
|
+
type: 'json',
|
|
1705
|
+
default: '{}',
|
|
1706
|
+
required: true,
|
|
1707
|
+
displayOptions: { show: { resource: ['quoteAccessList'], operation: ['addQuoteAccessListEntry'] } },
|
|
1708
|
+
description: 'Request body as JSON.',
|
|
1709
|
+
},
|
|
1710
|
+
{
|
|
1711
|
+
displayName: 'quoteId',
|
|
1712
|
+
name: 'quoteId',
|
|
1713
|
+
type: 'options',
|
|
1714
|
+
typeOptions: { loadOptionsMethod: 'getQuotes' },
|
|
1715
|
+
default: '',
|
|
1716
|
+
required: true,
|
|
1717
|
+
displayOptions: { show: { resource: ['quoteAccessList'], operation: ['deleteQuoteShareEntry'] } },
|
|
1718
|
+
description: 'path parameter',
|
|
1719
|
+
},
|
|
1720
|
+
{
|
|
1721
|
+
displayName: 'accessListEntryId',
|
|
1722
|
+
name: 'accessListEntryId',
|
|
1723
|
+
type: 'string',
|
|
1724
|
+
default: '',
|
|
1725
|
+
required: true,
|
|
1726
|
+
displayOptions: { show: { resource: ['quoteAccessList'], operation: ['deleteQuoteShareEntry'] } },
|
|
1727
|
+
description: 'path parameter',
|
|
1728
|
+
},
|
|
1729
|
+
{
|
|
1730
|
+
displayName: 'quoteId',
|
|
1731
|
+
name: 'quoteId',
|
|
1732
|
+
type: 'options',
|
|
1733
|
+
typeOptions: { loadOptionsMethod: 'getQuotes' },
|
|
1734
|
+
default: '',
|
|
1735
|
+
required: true,
|
|
1736
|
+
displayOptions: { show: { resource: ['quoteAccessList'], operation: ['getQuoteAccessList'] } },
|
|
1737
|
+
description: 'path parameter',
|
|
1738
|
+
},
|
|
1739
|
+
{
|
|
1740
|
+
displayName: 'quoteId',
|
|
1741
|
+
name: 'quoteId',
|
|
1742
|
+
type: 'options',
|
|
1743
|
+
typeOptions: { loadOptionsMethod: 'getQuotes' },
|
|
1744
|
+
default: '',
|
|
1745
|
+
required: true,
|
|
1746
|
+
displayOptions: { show: { resource: ['quoteAttachments'], operation: ['copyAttachmentsToQuoteFromLibrary'] } },
|
|
1747
|
+
description: 'path parameter',
|
|
1748
|
+
},
|
|
1749
|
+
{
|
|
1750
|
+
displayName: 'Body',
|
|
1751
|
+
name: 'body',
|
|
1752
|
+
type: 'json',
|
|
1753
|
+
default: '{}',
|
|
1754
|
+
required: true,
|
|
1755
|
+
displayOptions: { show: { resource: ['quoteAttachments'], operation: ['copyAttachmentsToQuoteFromLibrary'] } },
|
|
1756
|
+
description: 'Request body as JSON.',
|
|
1757
|
+
},
|
|
1758
|
+
{
|
|
1759
|
+
displayName: 'quoteId',
|
|
1760
|
+
name: 'quoteId',
|
|
1761
|
+
type: 'options',
|
|
1762
|
+
typeOptions: { loadOptionsMethod: 'getQuotes' },
|
|
1763
|
+
default: '',
|
|
1764
|
+
required: true,
|
|
1765
|
+
displayOptions: { show: { resource: ['quoteAttachments'], operation: ['deleteAttachment'] } },
|
|
1766
|
+
description: 'path parameter',
|
|
1767
|
+
},
|
|
1768
|
+
{
|
|
1769
|
+
displayName: 'attachmentId',
|
|
1770
|
+
name: 'attachmentId',
|
|
1771
|
+
type: 'string',
|
|
1772
|
+
default: '',
|
|
1773
|
+
required: true,
|
|
1774
|
+
displayOptions: { show: { resource: ['quoteAttachments'], operation: ['deleteAttachment'] } },
|
|
1775
|
+
description: 'path parameter',
|
|
1776
|
+
},
|
|
1777
|
+
{
|
|
1778
|
+
displayName: 'downloadZip',
|
|
1779
|
+
name: 'downloadZip',
|
|
1780
|
+
type: 'options',
|
|
1781
|
+
default: 'true',
|
|
1782
|
+
required: false,
|
|
1783
|
+
displayOptions: { show: { resource: ['quoteAttachments'], operation: ['downloadAllAttachmentsAsZip'] } },
|
|
1784
|
+
description: 'Must be set to true to download the ZIP.',
|
|
1785
|
+
options: [{ name: 'true', value: 'true' }],
|
|
1786
|
+
},
|
|
1787
|
+
{
|
|
1788
|
+
displayName: 'quoteId',
|
|
1789
|
+
name: 'quoteId',
|
|
1790
|
+
type: 'options',
|
|
1791
|
+
typeOptions: { loadOptionsMethod: 'getQuotes' },
|
|
1792
|
+
default: '',
|
|
1793
|
+
required: true,
|
|
1794
|
+
displayOptions: { show: { resource: ['quoteAttachments'], operation: ['downloadAllAttachmentsAsZip'] } },
|
|
1795
|
+
description: 'path parameter',
|
|
1796
|
+
},
|
|
1797
|
+
{
|
|
1798
|
+
displayName: 'quoteId',
|
|
1799
|
+
name: 'quoteId',
|
|
1800
|
+
type: 'options',
|
|
1801
|
+
typeOptions: { loadOptionsMethod: 'getQuotes' },
|
|
1802
|
+
default: '',
|
|
1803
|
+
required: true,
|
|
1804
|
+
displayOptions: { show: { resource: ['quoteAttachments'], operation: ['getAttachmentMetadata'] } },
|
|
1805
|
+
description: 'path parameter',
|
|
1806
|
+
},
|
|
1807
|
+
{
|
|
1808
|
+
displayName: 'attachmentId',
|
|
1809
|
+
name: 'attachmentId',
|
|
1810
|
+
type: 'string',
|
|
1811
|
+
default: '',
|
|
1812
|
+
required: true,
|
|
1813
|
+
displayOptions: { show: { resource: ['quoteAttachments'], operation: ['getAttachmentMetadata'] } },
|
|
1814
|
+
description: 'path parameter',
|
|
1815
|
+
},
|
|
1816
|
+
{
|
|
1817
|
+
displayName: 'download',
|
|
1818
|
+
name: 'download',
|
|
1819
|
+
type: 'options',
|
|
1820
|
+
default: 'true',
|
|
1821
|
+
required: false,
|
|
1822
|
+
displayOptions: { show: { resource: ['quoteAttachments'], operation: ['getAttachmentMetadata'] } },
|
|
1823
|
+
description: 'Must be set to true to download the file.',
|
|
1824
|
+
options: [{ name: 'true', value: 'true' }],
|
|
1825
|
+
},
|
|
1826
|
+
{
|
|
1827
|
+
displayName: 'quoteId',
|
|
1828
|
+
name: 'quoteId',
|
|
1829
|
+
type: 'options',
|
|
1830
|
+
typeOptions: { loadOptionsMethod: 'getQuotes' },
|
|
1831
|
+
default: '',
|
|
1832
|
+
required: true,
|
|
1833
|
+
displayOptions: { show: { resource: ['quoteAttachments'], operation: ['updateAttachmentsMetadata'] } },
|
|
1834
|
+
description: 'path parameter',
|
|
1835
|
+
},
|
|
1836
|
+
{
|
|
1837
|
+
displayName: 'Body',
|
|
1838
|
+
name: 'body',
|
|
1839
|
+
type: 'json',
|
|
1840
|
+
default: '{}',
|
|
1841
|
+
required: true,
|
|
1842
|
+
displayOptions: { show: { resource: ['quoteAttachments'], operation: ['updateAttachmentsMetadata'] } },
|
|
1843
|
+
description: 'Request body as JSON.',
|
|
1844
|
+
},
|
|
1845
|
+
{
|
|
1846
|
+
displayName: 'quoteId',
|
|
1847
|
+
name: 'quoteId',
|
|
1848
|
+
type: 'options',
|
|
1849
|
+
typeOptions: { loadOptionsMethod: 'getQuotes' },
|
|
1850
|
+
default: '',
|
|
1851
|
+
required: true,
|
|
1852
|
+
displayOptions: { show: { resource: ['quoteAttachments'], operation: ['uploadAttachmentToQuote'] } },
|
|
1853
|
+
description: 'path parameter',
|
|
1854
|
+
},
|
|
1855
|
+
{
|
|
1856
|
+
displayName: 'Body',
|
|
1857
|
+
name: 'body',
|
|
1858
|
+
type: 'json',
|
|
1859
|
+
default: '{}',
|
|
1860
|
+
required: false,
|
|
1861
|
+
displayOptions: { show: { resource: ['quoteAttachments'], operation: ['uploadAttachmentToQuote'] } },
|
|
1862
|
+
description: 'Request body as JSON.',
|
|
1863
|
+
},
|
|
1864
|
+
{
|
|
1865
|
+
displayName: 'quoteId',
|
|
1866
|
+
name: 'quoteId',
|
|
1867
|
+
type: 'options',
|
|
1868
|
+
typeOptions: { loadOptionsMethod: 'getQuotes' },
|
|
1869
|
+
default: '',
|
|
1870
|
+
required: true,
|
|
1871
|
+
displayOptions: { show: { resource: ['quoteLineItems'], operation: ['addLineItems'] } },
|
|
1872
|
+
description: 'path parameter',
|
|
1873
|
+
},
|
|
1874
|
+
{
|
|
1875
|
+
displayName: 'Body',
|
|
1876
|
+
name: 'body',
|
|
1877
|
+
type: 'json',
|
|
1878
|
+
default: '{}',
|
|
1879
|
+
required: true,
|
|
1880
|
+
displayOptions: { show: { resource: ['quoteLineItems'], operation: ['addLineItems'] } },
|
|
1881
|
+
description: 'Request body as JSON.',
|
|
1882
|
+
},
|
|
1883
|
+
{
|
|
1884
|
+
displayName: 'quoteId',
|
|
1885
|
+
name: 'quoteId',
|
|
1886
|
+
type: 'options',
|
|
1887
|
+
typeOptions: { loadOptionsMethod: 'getQuotes' },
|
|
1888
|
+
default: '',
|
|
1889
|
+
required: true,
|
|
1890
|
+
displayOptions: { show: { resource: ['quoteLineItems'], operation: ['deleteLineItemById'] } },
|
|
1891
|
+
description: 'path parameter',
|
|
1892
|
+
},
|
|
1893
|
+
{
|
|
1894
|
+
displayName: 'lineItemId',
|
|
1895
|
+
name: 'lineItemId',
|
|
1896
|
+
type: 'string',
|
|
1897
|
+
default: '',
|
|
1898
|
+
required: true,
|
|
1899
|
+
displayOptions: { show: { resource: ['quoteLineItems'], operation: ['deleteLineItemById'] } },
|
|
1900
|
+
description: 'path parameter',
|
|
1901
|
+
},
|
|
1902
|
+
{
|
|
1903
|
+
displayName: 'quoteId',
|
|
1904
|
+
name: 'quoteId',
|
|
1905
|
+
type: 'options',
|
|
1906
|
+
typeOptions: { loadOptionsMethod: 'getQuotes' },
|
|
1907
|
+
default: '',
|
|
1908
|
+
required: true,
|
|
1909
|
+
displayOptions: { show: { resource: ['quoteLineItems'], operation: ['bulkDeleteLineItems'] } },
|
|
1910
|
+
description: 'path parameter',
|
|
1911
|
+
},
|
|
1912
|
+
{
|
|
1913
|
+
displayName: 'Body',
|
|
1914
|
+
name: 'body',
|
|
1915
|
+
type: 'json',
|
|
1916
|
+
default: '{}',
|
|
1917
|
+
required: true,
|
|
1918
|
+
displayOptions: { show: { resource: ['quoteLineItems'], operation: ['bulkDeleteLineItems'] } },
|
|
1919
|
+
description: 'Request body as JSON.',
|
|
1920
|
+
},
|
|
1921
|
+
{
|
|
1922
|
+
displayName: 'quoteId',
|
|
1923
|
+
name: 'quoteId',
|
|
1924
|
+
type: 'options',
|
|
1925
|
+
typeOptions: { loadOptionsMethod: 'getQuotes' },
|
|
1926
|
+
default: '',
|
|
1927
|
+
required: true,
|
|
1928
|
+
displayOptions: { show: { resource: ['quoteLineItems'], operation: ['updateLineItems'] } },
|
|
1929
|
+
description: 'path parameter',
|
|
1930
|
+
},
|
|
1931
|
+
{
|
|
1932
|
+
displayName: 'Body',
|
|
1933
|
+
name: 'body',
|
|
1934
|
+
type: 'json',
|
|
1935
|
+
default: '{}',
|
|
1936
|
+
required: true,
|
|
1937
|
+
displayOptions: { show: { resource: ['quoteLineItems'], operation: ['updateLineItems'] } },
|
|
1938
|
+
description: 'Request body as JSON.',
|
|
1939
|
+
},
|
|
1940
|
+
{
|
|
1941
|
+
displayName: 'Body',
|
|
1942
|
+
name: 'body',
|
|
1943
|
+
type: 'json',
|
|
1944
|
+
default: '{}',
|
|
1945
|
+
required: true,
|
|
1946
|
+
displayOptions: { show: { resource: ['quotePreferences'], operation: ['persistQuotePreferences'] } },
|
|
1947
|
+
description: 'Request body as JSON.',
|
|
1948
|
+
},
|
|
1949
|
+
{
|
|
1950
|
+
displayName: 'quoteId',
|
|
1951
|
+
name: 'quoteId',
|
|
1952
|
+
type: 'options',
|
|
1953
|
+
typeOptions: { loadOptionsMethod: 'getQuotes' },
|
|
1954
|
+
default: '',
|
|
1955
|
+
required: true,
|
|
1956
|
+
displayOptions: { show: { resource: ['quoteSections'], operation: ['createSection'] } },
|
|
1957
|
+
description: 'path parameter',
|
|
1958
|
+
},
|
|
1959
|
+
{
|
|
1960
|
+
displayName: 'Body',
|
|
1961
|
+
name: 'body',
|
|
1962
|
+
type: 'json',
|
|
1963
|
+
default: '{}',
|
|
1964
|
+
required: true,
|
|
1965
|
+
displayOptions: { show: { resource: ['quoteSections'], operation: ['createSection'] } },
|
|
1966
|
+
description: 'Request body as JSON.',
|
|
1967
|
+
},
|
|
1968
|
+
{
|
|
1969
|
+
displayName: 'quoteId',
|
|
1970
|
+
name: 'quoteId',
|
|
1971
|
+
type: 'options',
|
|
1972
|
+
typeOptions: { loadOptionsMethod: 'getQuotes' },
|
|
1973
|
+
default: '',
|
|
1974
|
+
required: true,
|
|
1975
|
+
displayOptions: { show: { resource: ['quoteSections'], operation: ['getSections'] } },
|
|
1976
|
+
description: 'path parameter',
|
|
1977
|
+
},
|
|
1978
|
+
{
|
|
1979
|
+
displayName: 'quoteId',
|
|
1980
|
+
name: 'quoteId',
|
|
1981
|
+
type: 'options',
|
|
1982
|
+
typeOptions: { loadOptionsMethod: 'getQuotes' },
|
|
1983
|
+
default: '',
|
|
1984
|
+
required: true,
|
|
1985
|
+
displayOptions: { show: { resource: ['quoteSections'], operation: ['updateSections'] } },
|
|
1986
|
+
description: 'path parameter',
|
|
1987
|
+
},
|
|
1988
|
+
{
|
|
1989
|
+
displayName: 'Body',
|
|
1990
|
+
name: 'body',
|
|
1991
|
+
type: 'json',
|
|
1992
|
+
default: '{}',
|
|
1993
|
+
required: true,
|
|
1994
|
+
displayOptions: { show: { resource: ['quoteSections'], operation: ['updateSections'] } },
|
|
1995
|
+
description: 'Request body as JSON.',
|
|
1996
|
+
},
|
|
1997
|
+
{
|
|
1998
|
+
displayName: 'Body',
|
|
1999
|
+
name: 'body',
|
|
2000
|
+
type: 'json',
|
|
2001
|
+
default: '{}',
|
|
2002
|
+
required: true,
|
|
2003
|
+
displayOptions: { show: { resource: ['quotes'], operation: ['createQuote'] } },
|
|
2004
|
+
description: 'Request body as JSON.',
|
|
2005
|
+
},
|
|
2006
|
+
{
|
|
2007
|
+
displayName: 'quoteId',
|
|
2008
|
+
name: 'quoteId',
|
|
2009
|
+
type: 'options',
|
|
2010
|
+
typeOptions: { loadOptionsMethod: 'getQuotes' },
|
|
2011
|
+
default: '',
|
|
2012
|
+
required: true,
|
|
2013
|
+
displayOptions: { show: { resource: ['quotes'], operation: ['deleteQuoteById'] } },
|
|
2014
|
+
description: 'path parameter',
|
|
2015
|
+
},
|
|
2016
|
+
{
|
|
2017
|
+
displayName: 'quoteId',
|
|
2018
|
+
name: 'quoteId',
|
|
2019
|
+
type: 'options',
|
|
2020
|
+
typeOptions: { loadOptionsMethod: 'getQuotes' },
|
|
2021
|
+
default: '',
|
|
2022
|
+
required: true,
|
|
2023
|
+
displayOptions: { show: { resource: ['quotes'], operation: ['getQuoteById'] } },
|
|
2024
|
+
description: 'path parameter',
|
|
2025
|
+
},
|
|
2026
|
+
{
|
|
2027
|
+
displayName: 'limit',
|
|
2028
|
+
name: 'limit',
|
|
2029
|
+
type: 'number',
|
|
2030
|
+
default: 0,
|
|
2031
|
+
required: false,
|
|
2032
|
+
displayOptions: { show: { resource: ['quotes'], operation: ['getQuotesList'], returnAll: [false] } },
|
|
2033
|
+
description: 'query parameter',
|
|
2034
|
+
},
|
|
2035
|
+
{
|
|
2036
|
+
displayName: 'page',
|
|
2037
|
+
name: 'page',
|
|
2038
|
+
type: 'number',
|
|
2039
|
+
default: 0,
|
|
2040
|
+
required: false,
|
|
2041
|
+
displayOptions: { show: { resource: ['quotes'], operation: ['getQuotesList'], returnAll: [false] } },
|
|
2042
|
+
description: 'query parameter',
|
|
2043
|
+
},
|
|
2044
|
+
{
|
|
2045
|
+
displayName: 'sort',
|
|
2046
|
+
name: 'sort',
|
|
2047
|
+
type: 'options',
|
|
2048
|
+
default: 'id',
|
|
2049
|
+
required: false,
|
|
2050
|
+
displayOptions: { show: { resource: ['quotes'], operation: ['getQuotesList'], returnAll: [false] } },
|
|
2051
|
+
description: 'Return quotes sorted by fieldName,direction (e.g. sort=status,desc).',
|
|
2052
|
+
options: [{ name: 'id', value: 'id' }, { name: 'status', value: 'status' }, { name: 'client.name', value: 'client.name' }, { name: 'createdBy', value: 'createdBy' }, { name: 'createdOn', value: 'createdOn' }, { name: 'updatedOn', value: 'updatedOn' }, { name: 'totals.initialTotal', value: 'totals.initialTotal' }, { name: 'totals.recurringTotal', value: 'totals.recurringTotal' }],
|
|
2053
|
+
},
|
|
2054
|
+
{
|
|
2055
|
+
displayName: 'search',
|
|
2056
|
+
name: 'search',
|
|
2057
|
+
type: 'string',
|
|
2058
|
+
default: '',
|
|
2059
|
+
required: false,
|
|
2060
|
+
displayOptions: { show: { resource: ['quotes'], operation: ['getQuotesList'], returnAll: [false] } },
|
|
2061
|
+
description: 'Search on fields like client name, reference code, created by user name, and invoice totals.',
|
|
2062
|
+
},
|
|
2063
|
+
{
|
|
2064
|
+
displayName: 'status',
|
|
2065
|
+
name: 'status',
|
|
2066
|
+
type: 'options',
|
|
2067
|
+
default: 'draft',
|
|
2068
|
+
required: false,
|
|
2069
|
+
displayOptions: { show: { resource: ['quotes'], operation: ['getQuotesList'] } },
|
|
2070
|
+
description: 'Filter by status. Multiple values can be provided as a comma-separated list.',
|
|
2071
|
+
options: [{ name: 'draft', value: 'draft' }, { name: 'assigned', value: 'assigned' }, { name: 'sent', value: 'sent' }, { name: 'closed', value: 'closed' }, { name: 'declined', value: 'declined' }, { name: 'accepted', value: 'accepted' }, { name: 'changes_requested', value: 'changes_requested' }, { name: 'expired', value: 'expired' }, { name: 'pending', value: 'pending' }],
|
|
2072
|
+
},
|
|
2073
|
+
{
|
|
2074
|
+
displayName: 'account',
|
|
2075
|
+
name: 'account',
|
|
2076
|
+
type: 'options',
|
|
2077
|
+
default: 'user',
|
|
2078
|
+
required: false,
|
|
2079
|
+
displayOptions: { show: { resource: ['quotes'], operation: ['getQuotesList'] } },
|
|
2080
|
+
description: 'query parameter',
|
|
2081
|
+
options: [{ name: 'user', value: 'user' }, { name: 'partner', value: 'partner' }],
|
|
2082
|
+
},
|
|
2083
|
+
{
|
|
2084
|
+
displayName: 'partnerId',
|
|
2085
|
+
name: 'partnerId',
|
|
2086
|
+
type: 'string',
|
|
2087
|
+
default: '',
|
|
2088
|
+
required: false,
|
|
2089
|
+
displayOptions: { show: { resource: ['quotes'], operation: ['getQuotesList'] } },
|
|
2090
|
+
description: 'query parameter',
|
|
2091
|
+
},
|
|
2092
|
+
{
|
|
2093
|
+
displayName: 'intentType',
|
|
2094
|
+
name: 'intentType',
|
|
2095
|
+
type: 'options',
|
|
2096
|
+
default: 'PARTNER_TO_CLIENT',
|
|
2097
|
+
required: false,
|
|
2098
|
+
displayOptions: { show: { resource: ['quotes'], operation: ['getQuotesList'] } },
|
|
2099
|
+
description: 'query parameter',
|
|
2100
|
+
options: [{ name: 'PARTNER_TO_CLIENT', value: 'PARTNER_TO_CLIENT' }, { name: 'PAX8_TO_PARTNER', value: 'PAX8_TO_PARTNER' }, { name: 'PAX8_TO_PARTNER_CLIENT', value: 'PAX8_TO_PARTNER_CLIENT' }],
|
|
2101
|
+
},
|
|
2102
|
+
{
|
|
2103
|
+
displayName: 'quoteId',
|
|
2104
|
+
name: 'quoteId',
|
|
2105
|
+
type: 'options',
|
|
2106
|
+
typeOptions: { loadOptionsMethod: 'getQuotes' },
|
|
2107
|
+
default: '',
|
|
2108
|
+
required: true,
|
|
2109
|
+
displayOptions: { show: { resource: ['quotes'], operation: ['updateQuote'] } },
|
|
2110
|
+
description: 'path parameter',
|
|
2111
|
+
},
|
|
2112
|
+
{
|
|
2113
|
+
displayName: 'Body',
|
|
2114
|
+
name: 'body',
|
|
2115
|
+
type: 'json',
|
|
2116
|
+
default: '{}',
|
|
2117
|
+
required: true,
|
|
2118
|
+
displayOptions: { show: { resource: ['quotes'], operation: ['updateQuote'] } },
|
|
2119
|
+
description: 'Request body as JSON.',
|
|
2120
|
+
},
|
|
2121
|
+
{
|
|
2122
|
+
displayName: 'subscriptionId',
|
|
2123
|
+
name: 'subscriptionId',
|
|
2124
|
+
type: 'options',
|
|
2125
|
+
typeOptions: { loadOptionsMethod: 'getSubscriptions' },
|
|
2126
|
+
default: '',
|
|
2127
|
+
required: true,
|
|
2128
|
+
displayOptions: { show: { resource: ['subscriptions'], operation: ['delete_subscriptions_subscriptionId'] } },
|
|
2129
|
+
description: 'subscription to be updated',
|
|
2130
|
+
},
|
|
2131
|
+
{
|
|
2132
|
+
displayName: 'cancelDate',
|
|
2133
|
+
name: 'cancelDate',
|
|
2134
|
+
type: 'string',
|
|
2135
|
+
default: '',
|
|
2136
|
+
required: false,
|
|
2137
|
+
displayOptions: { show: { resource: ['subscriptions'], operation: ['delete_subscriptions_subscriptionId'] } },
|
|
2138
|
+
description: 'The date to cancel the subscription on',
|
|
2139
|
+
},
|
|
2140
|
+
{
|
|
2141
|
+
displayName: 'subscriptionId',
|
|
2142
|
+
name: 'subscriptionId',
|
|
2143
|
+
type: 'options',
|
|
2144
|
+
typeOptions: { loadOptionsMethod: 'getSubscriptions' },
|
|
2145
|
+
default: '',
|
|
2146
|
+
required: true,
|
|
2147
|
+
displayOptions: { show: { resource: ['subscriptions'], operation: ['findSubscriptionBySubscriptionId'] } },
|
|
2148
|
+
description: 'path parameter',
|
|
2149
|
+
},
|
|
2150
|
+
{
|
|
2151
|
+
displayName: 'subscriptionId',
|
|
2152
|
+
name: 'subscriptionId',
|
|
2153
|
+
type: 'options',
|
|
2154
|
+
typeOptions: { loadOptionsMethod: 'getSubscriptions' },
|
|
2155
|
+
default: '',
|
|
2156
|
+
required: true,
|
|
2157
|
+
displayOptions: { show: { resource: ['subscriptions'], operation: ['findSubscriptionHistoryBySubscriptionId'] } },
|
|
2158
|
+
description: 'path parameter',
|
|
2159
|
+
},
|
|
2160
|
+
{
|
|
2161
|
+
displayName: 'page',
|
|
2162
|
+
name: 'page',
|
|
2163
|
+
type: 'number',
|
|
2164
|
+
default: 0,
|
|
2165
|
+
required: false,
|
|
2166
|
+
displayOptions: { show: { resource: ['subscriptions'], operation: ['findSubscriptions'], returnAll: [false] } },
|
|
2167
|
+
description: 'The page number to request in the subscriptions list',
|
|
2168
|
+
},
|
|
2169
|
+
{
|
|
2170
|
+
displayName: 'size',
|
|
2171
|
+
name: 'size',
|
|
2172
|
+
type: 'number',
|
|
2173
|
+
default: 0,
|
|
2174
|
+
required: false,
|
|
2175
|
+
displayOptions: { show: { resource: ['subscriptions'], operation: ['findSubscriptions'], returnAll: [false] } },
|
|
2176
|
+
description: 'Returns _this_ number of subscriptions per page',
|
|
2177
|
+
},
|
|
2178
|
+
{
|
|
2179
|
+
displayName: 'sort',
|
|
2180
|
+
name: 'sort',
|
|
2181
|
+
type: 'options',
|
|
2182
|
+
default: 'quantity,asc',
|
|
2183
|
+
required: false,
|
|
2184
|
+
displayOptions: { show: { resource: ['subscriptions'], operation: ['findSubscriptions'], returnAll: [false] } },
|
|
2185
|
+
description: 'Return subscriptions sorted by this field and direction Formatted as fieldName,direction - ex. sort=createdDate,desc',
|
|
2186
|
+
options: [{ name: 'quantity,asc', value: 'quantity,asc' }, { name: 'quantity,desc', value: 'quantity,desc' }, { name: 'startDate,asc', value: 'startDate,asc' }, { name: 'startDate,desc', value: 'startDate,desc' }, { name: 'endDate,asc', value: 'endDate,asc' }, { name: 'endDate,desc', value: 'endDate,desc' }, { name: 'createdDate,asc', value: 'createdDate,asc' }, { name: 'createdDate,desc', value: 'createdDate,desc' }, { name: 'billingStart,asc', value: 'billingStart,asc' }, { name: 'billingStart,desc', value: 'billingStart,desc' }, { name: 'price,asc', value: 'price,asc' }, { name: 'price,desc', value: 'price,desc' }],
|
|
2187
|
+
},
|
|
2188
|
+
{
|
|
2189
|
+
displayName: 'status',
|
|
2190
|
+
name: 'status',
|
|
2191
|
+
type: 'options',
|
|
2192
|
+
default: 'Active',
|
|
2193
|
+
required: false,
|
|
2194
|
+
displayOptions: { show: { resource: ['subscriptions'], operation: ['findSubscriptions'] } },
|
|
2195
|
+
description: 'Return only subscriptions matching this ```status``` value',
|
|
2196
|
+
options: [{ name: 'Active', value: 'Active' }, { name: 'Cancelled', value: 'Cancelled' }, { name: 'PendingManual', value: 'PendingManual' }, { name: 'PendingAutomated', value: 'PendingAutomated' }, { name: 'PendingCancel', value: 'PendingCancel' }, { name: 'WaitingForDetails', value: 'WaitingForDetails' }, { name: 'Trial', value: 'Trial' }, { name: 'Converted', value: 'Converted' }, { name: 'PendingActivation', value: 'PendingActivation' }, { name: 'Activated', value: 'Activated' }],
|
|
2197
|
+
},
|
|
2198
|
+
{
|
|
2199
|
+
displayName: 'billingTerm',
|
|
2200
|
+
name: 'billingTerm',
|
|
2201
|
+
type: 'options',
|
|
2202
|
+
default: 'Monthly',
|
|
2203
|
+
required: false,
|
|
2204
|
+
displayOptions: { show: { resource: ['subscriptions'], operation: ['findSubscriptions'] } },
|
|
2205
|
+
description: 'Return only subscriptions matching this ```billingTerm``` value',
|
|
2206
|
+
options: [{ name: 'Monthly', value: 'Monthly' }, { name: 'Annual', value: 'Annual' }, { name: '2-Year', value: '2-Year' }, { name: '3-Year', value: '3-Year' }, { name: 'One-Time', value: 'One-Time' }, { name: 'Trial', value: 'Trial' }, { name: 'Activation', value: 'Activation' }],
|
|
2207
|
+
},
|
|
2208
|
+
{
|
|
2209
|
+
displayName: 'companyId',
|
|
2210
|
+
name: 'companyId',
|
|
2211
|
+
type: 'options',
|
|
2212
|
+
typeOptions: { loadOptionsMethod: 'getCompanies' },
|
|
2213
|
+
default: '',
|
|
2214
|
+
required: false,
|
|
2215
|
+
displayOptions: { show: { resource: ['subscriptions'], operation: ['findSubscriptions'] } },
|
|
2216
|
+
description: 'Return only subscriptions matching this ```companyId``` value',
|
|
2217
|
+
},
|
|
2218
|
+
{
|
|
2219
|
+
displayName: 'productId',
|
|
2220
|
+
name: 'productId',
|
|
2221
|
+
type: 'options',
|
|
2222
|
+
typeOptions: { loadOptionsMethod: 'getProducts' },
|
|
2223
|
+
default: '',
|
|
2224
|
+
required: false,
|
|
2225
|
+
displayOptions: { show: { resource: ['subscriptions'], operation: ['findSubscriptions'] } },
|
|
2226
|
+
description: 'Return only subscriptions matching this ```productId``` value',
|
|
2227
|
+
},
|
|
2228
|
+
{
|
|
2229
|
+
displayName: 'subscriptionId',
|
|
2230
|
+
name: 'subscriptionId',
|
|
2231
|
+
type: 'options',
|
|
2232
|
+
typeOptions: { loadOptionsMethod: 'getSubscriptions' },
|
|
2233
|
+
default: '',
|
|
2234
|
+
required: true,
|
|
2235
|
+
displayOptions: { show: { resource: ['subscriptions'], operation: ['updateSubscription'] } },
|
|
2236
|
+
description: 'subscription to be updated',
|
|
2237
|
+
},
|
|
2238
|
+
{
|
|
2239
|
+
displayName: 'Body',
|
|
2240
|
+
name: 'body',
|
|
2241
|
+
type: 'json',
|
|
2242
|
+
default: '{}',
|
|
2243
|
+
required: true,
|
|
2244
|
+
displayOptions: { show: { resource: ['subscriptions'], operation: ['updateSubscription'] } },
|
|
2245
|
+
description: 'Request body as JSON.',
|
|
2246
|
+
},
|
|
2247
|
+
{
|
|
2248
|
+
displayName: 'page',
|
|
2249
|
+
name: 'page',
|
|
2250
|
+
type: 'number',
|
|
2251
|
+
default: 0,
|
|
2252
|
+
required: false,
|
|
2253
|
+
displayOptions: { show: { resource: ['topicDefinitions'], operation: ['getTopicDefinitions'], returnAll: [false] } },
|
|
2254
|
+
description: 'query parameter',
|
|
2255
|
+
},
|
|
2256
|
+
{
|
|
2257
|
+
displayName: 'size',
|
|
2258
|
+
name: 'size',
|
|
2259
|
+
type: 'number',
|
|
2260
|
+
default: 0,
|
|
2261
|
+
required: false,
|
|
2262
|
+
displayOptions: { show: { resource: ['topicDefinitions'], operation: ['getTopicDefinitions'], returnAll: [false] } },
|
|
2263
|
+
description: 'query parameter',
|
|
2264
|
+
},
|
|
2265
|
+
{
|
|
2266
|
+
displayName: 'search',
|
|
2267
|
+
name: 'search',
|
|
2268
|
+
type: 'string',
|
|
2269
|
+
default: '',
|
|
2270
|
+
required: false,
|
|
2271
|
+
displayOptions: { show: { resource: ['topicDefinitions'], operation: ['getTopicDefinitions'], returnAll: [false] } },
|
|
2272
|
+
description: 'query parameter',
|
|
2273
|
+
},
|
|
2274
|
+
{
|
|
2275
|
+
displayName: 'sort',
|
|
2276
|
+
name: 'sort',
|
|
2277
|
+
type: 'string',
|
|
2278
|
+
default: '',
|
|
2279
|
+
required: false,
|
|
2280
|
+
displayOptions: { show: { resource: ['topicDefinitions'], operation: ['getTopicDefinitions'] } },
|
|
2281
|
+
description: 'query parameter',
|
|
2282
|
+
},
|
|
2283
|
+
{
|
|
2284
|
+
displayName: 'topic',
|
|
2285
|
+
name: 'topic',
|
|
2286
|
+
type: 'string',
|
|
2287
|
+
default: '',
|
|
2288
|
+
required: false,
|
|
2289
|
+
displayOptions: { show: { resource: ['topicDefinitions'], operation: ['getTopicDefinitions'] } },
|
|
2290
|
+
description: 'query parameter',
|
|
2291
|
+
},
|
|
2292
|
+
{
|
|
2293
|
+
displayName: 'subscriptionId',
|
|
2294
|
+
name: 'subscriptionId',
|
|
2295
|
+
type: 'options',
|
|
2296
|
+
typeOptions: { loadOptionsMethod: 'getSubscriptions' },
|
|
2297
|
+
default: '',
|
|
2298
|
+
required: false,
|
|
2299
|
+
displayOptions: { show: { resource: ['usageLines'], operation: ['getUsageLines'] } },
|
|
2300
|
+
description: 'query parameter',
|
|
2301
|
+
},
|
|
2302
|
+
{
|
|
2303
|
+
displayName: 'externalSubscriptionId',
|
|
2304
|
+
name: 'externalSubscriptionId',
|
|
2305
|
+
type: 'string',
|
|
2306
|
+
default: '',
|
|
2307
|
+
required: false,
|
|
2308
|
+
displayOptions: { show: { resource: ['usageLines'], operation: ['getUsageLines'] } },
|
|
2309
|
+
description: 'query parameter',
|
|
2310
|
+
},
|
|
2311
|
+
{
|
|
2312
|
+
displayName: 'billingPeriod',
|
|
2313
|
+
name: 'billingPeriod',
|
|
2314
|
+
type: 'string',
|
|
2315
|
+
default: '',
|
|
2316
|
+
required: true,
|
|
2317
|
+
displayOptions: { show: { resource: ['usageLines'], operation: ['getUsageLines'] } },
|
|
2318
|
+
description: 'Billing period with format yyyy-MM',
|
|
2319
|
+
},
|
|
2320
|
+
{
|
|
2321
|
+
displayName: 'summaryKey',
|
|
2322
|
+
name: 'summaryKey',
|
|
2323
|
+
type: 'string',
|
|
2324
|
+
default: '',
|
|
2325
|
+
required: true,
|
|
2326
|
+
displayOptions: { show: { resource: ['usageLines'], operation: ['getUsageLines'] } },
|
|
2327
|
+
description: 'query parameter',
|
|
2328
|
+
},
|
|
2329
|
+
{
|
|
2330
|
+
displayName: 'subscriptionId',
|
|
2331
|
+
name: 'subscriptionId',
|
|
2332
|
+
type: 'options',
|
|
2333
|
+
typeOptions: { loadOptionsMethod: 'getSubscriptions' },
|
|
2334
|
+
default: '',
|
|
2335
|
+
required: false,
|
|
2336
|
+
displayOptions: { show: { resource: ['usageLines'], operation: ['saveUsageLines'] } },
|
|
2337
|
+
description: 'query parameter',
|
|
2338
|
+
},
|
|
2339
|
+
{
|
|
2340
|
+
displayName: 'externalSubscriptionId',
|
|
2341
|
+
name: 'externalSubscriptionId',
|
|
2342
|
+
type: 'string',
|
|
2343
|
+
default: '',
|
|
2344
|
+
required: false,
|
|
2345
|
+
displayOptions: { show: { resource: ['usageLines'], operation: ['saveUsageLines'] } },
|
|
2346
|
+
description: 'query parameter',
|
|
2347
|
+
},
|
|
2348
|
+
{
|
|
2349
|
+
displayName: 'billingPeriod',
|
|
2350
|
+
name: 'billingPeriod',
|
|
2351
|
+
type: 'string',
|
|
2352
|
+
default: '',
|
|
2353
|
+
required: true,
|
|
2354
|
+
displayOptions: { show: { resource: ['usageLines'], operation: ['saveUsageLines'] } },
|
|
2355
|
+
description: 'Billing period with format yyyy-MM',
|
|
2356
|
+
},
|
|
2357
|
+
{
|
|
2358
|
+
displayName: 'overwriteSameDayUsage',
|
|
2359
|
+
name: 'overwriteSameDayUsage',
|
|
2360
|
+
type: 'boolean',
|
|
2361
|
+
default: false,
|
|
2362
|
+
required: false,
|
|
2363
|
+
displayOptions: { show: { resource: ['usageLines'], operation: ['saveUsageLines'] } },
|
|
2364
|
+
description: 'When set to false, usage lines for the same summary key will be appended instead of replacing existing same-day lines',
|
|
2365
|
+
},
|
|
2366
|
+
{
|
|
2367
|
+
displayName: 'Body',
|
|
2368
|
+
name: 'body',
|
|
2369
|
+
type: 'json',
|
|
2370
|
+
default: '{}',
|
|
2371
|
+
required: true,
|
|
2372
|
+
displayOptions: { show: { resource: ['usageLines'], operation: ['saveUsageLines'] } },
|
|
2373
|
+
description: 'Request body as JSON.',
|
|
2374
|
+
},
|
|
2375
|
+
{
|
|
2376
|
+
displayName: 'subscriptionId',
|
|
2377
|
+
name: 'subscriptionId',
|
|
2378
|
+
type: 'options',
|
|
2379
|
+
typeOptions: { loadOptionsMethod: 'getSubscriptions' },
|
|
2380
|
+
default: '',
|
|
2381
|
+
required: false,
|
|
2382
|
+
displayOptions: { show: { resource: ['usageLines'], operation: ['saveUsageLinesWithAggregate'] } },
|
|
2383
|
+
description: 'query parameter',
|
|
2384
|
+
},
|
|
2385
|
+
{
|
|
2386
|
+
displayName: 'externalSubscriptionId',
|
|
2387
|
+
name: 'externalSubscriptionId',
|
|
2388
|
+
type: 'string',
|
|
2389
|
+
default: '',
|
|
2390
|
+
required: false,
|
|
2391
|
+
displayOptions: { show: { resource: ['usageLines'], operation: ['saveUsageLinesWithAggregate'] } },
|
|
2392
|
+
description: 'query parameter',
|
|
2393
|
+
},
|
|
2394
|
+
{
|
|
2395
|
+
displayName: 'billingPeriod',
|
|
2396
|
+
name: 'billingPeriod',
|
|
2397
|
+
type: 'string',
|
|
2398
|
+
default: '',
|
|
2399
|
+
required: true,
|
|
2400
|
+
displayOptions: { show: { resource: ['usageLines'], operation: ['saveUsageLinesWithAggregate'] } },
|
|
2401
|
+
description: 'Billing period with format yyyy-MM',
|
|
2402
|
+
},
|
|
2403
|
+
{
|
|
2404
|
+
displayName: 'overwriteSameDayUsage',
|
|
2405
|
+
name: 'overwriteSameDayUsage',
|
|
2406
|
+
type: 'boolean',
|
|
2407
|
+
default: false,
|
|
2408
|
+
required: false,
|
|
2409
|
+
displayOptions: { show: { resource: ['usageLines'], operation: ['saveUsageLinesWithAggregate'] } },
|
|
2410
|
+
description: 'When set to false, usage lines for the same summary key will be appended instead of replacing existing same-day lines',
|
|
2411
|
+
},
|
|
2412
|
+
{
|
|
2413
|
+
displayName: 'Body',
|
|
2414
|
+
name: 'body',
|
|
2415
|
+
type: 'json',
|
|
2416
|
+
default: '{}',
|
|
2417
|
+
required: true,
|
|
2418
|
+
displayOptions: { show: { resource: ['usageLines'], operation: ['saveUsageLinesWithAggregate'] } },
|
|
2419
|
+
description: 'Request body as JSON.',
|
|
2420
|
+
},
|
|
2421
|
+
{
|
|
2422
|
+
displayName: 'usageSummaryId',
|
|
2423
|
+
name: 'usageSummaryId',
|
|
2424
|
+
type: 'string',
|
|
2425
|
+
default: '',
|
|
2426
|
+
required: true,
|
|
2427
|
+
displayOptions: { show: { resource: ['usageSummaries'], operation: ['findSubscriptionUsageSummary'] } },
|
|
2428
|
+
description: 'The usage summary id',
|
|
2429
|
+
},
|
|
2430
|
+
{
|
|
2431
|
+
displayName: 'subscriptionId',
|
|
2432
|
+
name: 'subscriptionId',
|
|
2433
|
+
type: 'options',
|
|
2434
|
+
typeOptions: { loadOptionsMethod: 'getSubscriptions' },
|
|
2435
|
+
default: '',
|
|
2436
|
+
required: true,
|
|
2437
|
+
displayOptions: { show: { resource: ['usageSummaries'], operation: ['findSubscriptionUsageSummaries'], returnAll: [false] } },
|
|
2438
|
+
description: 'path parameter',
|
|
2439
|
+
},
|
|
2440
|
+
{
|
|
2441
|
+
displayName: 'page',
|
|
2442
|
+
name: 'page',
|
|
2443
|
+
type: 'number',
|
|
2444
|
+
default: 0,
|
|
2445
|
+
required: false,
|
|
2446
|
+
displayOptions: { show: { resource: ['usageSummaries'], operation: ['findSubscriptionUsageSummaries'], returnAll: [false] } },
|
|
2447
|
+
description: 'The page number to request in the usage summaries list',
|
|
2448
|
+
},
|
|
2449
|
+
{
|
|
2450
|
+
displayName: 'size',
|
|
2451
|
+
name: 'size',
|
|
2452
|
+
type: 'number',
|
|
2453
|
+
default: 0,
|
|
2454
|
+
required: false,
|
|
2455
|
+
displayOptions: { show: { resource: ['usageSummaries'], operation: ['findSubscriptionUsageSummaries'], returnAll: [false] } },
|
|
2456
|
+
description: 'Returns _this_ number of usage summaries per page',
|
|
2457
|
+
},
|
|
2458
|
+
{
|
|
2459
|
+
displayName: 'sort',
|
|
2460
|
+
name: 'sort',
|
|
2461
|
+
type: 'options',
|
|
2462
|
+
default: 'resourceGroup',
|
|
2463
|
+
required: false,
|
|
2464
|
+
displayOptions: { show: { resource: ['usageSummaries'], operation: ['findSubscriptionUsageSummaries'], returnAll: [false] } },
|
|
2465
|
+
description: 'Return usage summaries sorted by this field and direction Formatted as fieldName,direction - ex. sort=resourceGroup,desc',
|
|
2466
|
+
options: [{ name: 'resourceGroup', value: 'resourceGroup' }, { name: 'currentCharges', value: 'currentCharges' }, { name: 'partnerTotal', value: 'partnerTotal' }],
|
|
2467
|
+
},
|
|
2468
|
+
{
|
|
2469
|
+
displayName: 'resourceGroup',
|
|
2470
|
+
name: 'resourceGroup',
|
|
2471
|
+
type: 'string',
|
|
2472
|
+
default: '',
|
|
2473
|
+
required: false,
|
|
2474
|
+
displayOptions: { show: { resource: ['usageSummaries'], operation: ['findSubscriptionUsageSummaries'] } },
|
|
2475
|
+
description: 'Return only usage summaries matching this ```resourceGroup``` value',
|
|
2476
|
+
},
|
|
2477
|
+
{
|
|
2478
|
+
displayName: 'companyId',
|
|
2479
|
+
name: 'companyId',
|
|
2480
|
+
type: 'options',
|
|
2481
|
+
typeOptions: { loadOptionsMethod: 'getCompanies' },
|
|
2482
|
+
default: '',
|
|
2483
|
+
required: false,
|
|
2484
|
+
displayOptions: { show: { resource: ['usageSummaries'], operation: ['findSubscriptionUsageSummaries'] } },
|
|
2485
|
+
description: 'Return only usage summaries with this ```companyId``` value',
|
|
2486
|
+
},
|
|
2487
|
+
{
|
|
2488
|
+
displayName: 'usageSummaryId',
|
|
2489
|
+
name: 'usageSummaryId',
|
|
2490
|
+
type: 'string',
|
|
2491
|
+
default: '',
|
|
2492
|
+
required: true,
|
|
2493
|
+
displayOptions: { show: { resource: ['usageSummaries'], operation: ['findUsageLines'] } },
|
|
2494
|
+
description: 'The usage summary id',
|
|
2495
|
+
},
|
|
2496
|
+
{
|
|
2497
|
+
displayName: 'usageDate',
|
|
2498
|
+
name: 'usageDate',
|
|
2499
|
+
type: 'string',
|
|
2500
|
+
default: '',
|
|
2501
|
+
required: true,
|
|
2502
|
+
displayOptions: { show: { resource: ['usageSummaries'], operation: ['findUsageLines'] } },
|
|
2503
|
+
description: 'The date usage was recorded',
|
|
2504
|
+
},
|
|
2505
|
+
{
|
|
2506
|
+
displayName: 'productId',
|
|
2507
|
+
name: 'productId',
|
|
2508
|
+
type: 'options',
|
|
2509
|
+
typeOptions: { loadOptionsMethod: 'getProducts' },
|
|
2510
|
+
default: '',
|
|
2511
|
+
required: false,
|
|
2512
|
+
displayOptions: { show: { resource: ['usageSummaries'], operation: ['findUsageLines'] } },
|
|
2513
|
+
description: 'Return only usage summaries with this ```productId``` value',
|
|
2514
|
+
},
|
|
2515
|
+
{
|
|
2516
|
+
displayName: 'webhookId',
|
|
2517
|
+
name: 'webhookId',
|
|
2518
|
+
type: 'options',
|
|
2519
|
+
typeOptions: { loadOptionsMethod: 'getWebhooks' },
|
|
2520
|
+
default: '',
|
|
2521
|
+
required: true,
|
|
2522
|
+
displayOptions: { show: { resource: ['webhookLogs'], operation: ['WebhookLogs_get'] } },
|
|
2523
|
+
description: 'path parameter',
|
|
2524
|
+
},
|
|
2525
|
+
{
|
|
2526
|
+
displayName: 'id',
|
|
2527
|
+
name: 'id',
|
|
2528
|
+
type: 'options',
|
|
2529
|
+
typeOptions: { loadOptionsMethod: 'getWebhooks' },
|
|
2530
|
+
default: '',
|
|
2531
|
+
required: true,
|
|
2532
|
+
displayOptions: { show: { resource: ['webhookLogs'], operation: ['WebhookLogs_get'] } },
|
|
2533
|
+
description: 'path parameter',
|
|
2534
|
+
},
|
|
2535
|
+
{
|
|
2536
|
+
displayName: 'webhookId',
|
|
2537
|
+
name: 'webhookId',
|
|
2538
|
+
type: 'options',
|
|
2539
|
+
typeOptions: { loadOptionsMethod: 'getWebhooks' },
|
|
2540
|
+
default: '',
|
|
2541
|
+
required: true,
|
|
2542
|
+
displayOptions: { show: { resource: ['webhookLogs'], operation: ['WebhookLogs_query'], returnAll: [false] } },
|
|
2543
|
+
description: 'path parameter',
|
|
2544
|
+
},
|
|
2545
|
+
{
|
|
2546
|
+
displayName: 'topicName',
|
|
2547
|
+
name: 'topicName',
|
|
2548
|
+
type: 'string',
|
|
2549
|
+
default: '',
|
|
2550
|
+
required: false,
|
|
2551
|
+
displayOptions: { show: { resource: ['webhookLogs'], operation: ['WebhookLogs_query'], returnAll: [false] } },
|
|
2552
|
+
description: 'Query params used to filter results',
|
|
2553
|
+
},
|
|
2554
|
+
{
|
|
2555
|
+
displayName: 'page',
|
|
2556
|
+
name: 'page',
|
|
2557
|
+
type: 'number',
|
|
2558
|
+
default: 0,
|
|
2559
|
+
required: false,
|
|
2560
|
+
displayOptions: { show: { resource: ['webhookLogs'], operation: ['WebhookLogs_query'], returnAll: [false] } },
|
|
2561
|
+
description: 'query parameter',
|
|
2562
|
+
},
|
|
2563
|
+
{
|
|
2564
|
+
displayName: 'size',
|
|
2565
|
+
name: 'size',
|
|
2566
|
+
type: 'number',
|
|
2567
|
+
default: 0,
|
|
2568
|
+
required: false,
|
|
2569
|
+
displayOptions: { show: { resource: ['webhookLogs'], operation: ['WebhookLogs_query'], returnAll: [false] } },
|
|
2570
|
+
description: 'query parameter',
|
|
2571
|
+
},
|
|
2572
|
+
{
|
|
2573
|
+
displayName: 'status',
|
|
2574
|
+
name: 'status',
|
|
2575
|
+
type: 'string',
|
|
2576
|
+
default: '',
|
|
2577
|
+
required: false,
|
|
2578
|
+
displayOptions: { show: { resource: ['webhookLogs'], operation: ['WebhookLogs_query'], returnAll: [false] } },
|
|
2579
|
+
description: 'Filter value for the last delivery status of the webhook',
|
|
2580
|
+
},
|
|
2581
|
+
{
|
|
2582
|
+
displayName: 'startDate',
|
|
2583
|
+
name: 'startDate',
|
|
2584
|
+
type: 'string',
|
|
2585
|
+
default: '',
|
|
2586
|
+
required: false,
|
|
2587
|
+
displayOptions: { show: { resource: ['webhookLogs'], operation: ['WebhookLogs_query'] } },
|
|
2588
|
+
description: 'query parameter',
|
|
2589
|
+
},
|
|
2590
|
+
{
|
|
2591
|
+
displayName: 'endDate',
|
|
2592
|
+
name: 'endDate',
|
|
2593
|
+
type: 'string',
|
|
2594
|
+
default: '',
|
|
2595
|
+
required: false,
|
|
2596
|
+
displayOptions: { show: { resource: ['webhookLogs'], operation: ['WebhookLogs_query'] } },
|
|
2597
|
+
description: 'query parameter',
|
|
2598
|
+
},
|
|
2599
|
+
{
|
|
2600
|
+
displayName: 'sort',
|
|
2601
|
+
name: 'sort',
|
|
2602
|
+
type: 'string',
|
|
2603
|
+
default: '',
|
|
2604
|
+
required: false,
|
|
2605
|
+
displayOptions: { show: { resource: ['webhookLogs'], operation: ['WebhookLogs_query'] } },
|
|
2606
|
+
description: 'Sort field and order, format: field:asc/desc',
|
|
2607
|
+
},
|
|
2608
|
+
{
|
|
2609
|
+
displayName: 'query',
|
|
2610
|
+
name: 'query',
|
|
2611
|
+
type: 'json',
|
|
2612
|
+
default: '{}',
|
|
2613
|
+
required: true,
|
|
2614
|
+
displayOptions: { show: { resource: ['webhookLogs'], operation: ['WebhookLogs_query'] } },
|
|
2615
|
+
description: 'query parameter',
|
|
2616
|
+
},
|
|
2617
|
+
{
|
|
2618
|
+
displayName: 'webhookId',
|
|
2619
|
+
name: 'webhookId',
|
|
2620
|
+
type: 'options',
|
|
2621
|
+
typeOptions: { loadOptionsMethod: 'getWebhooks' },
|
|
2622
|
+
default: '',
|
|
2623
|
+
required: true,
|
|
2624
|
+
displayOptions: { show: { resource: ['webhookLogs'], operation: ['retryWebhookDelivery'] } },
|
|
2625
|
+
description: 'path parameter',
|
|
2626
|
+
},
|
|
2627
|
+
{
|
|
2628
|
+
displayName: 'logId',
|
|
2629
|
+
name: 'logId',
|
|
2630
|
+
type: 'string',
|
|
2631
|
+
default: '',
|
|
2632
|
+
required: true,
|
|
2633
|
+
displayOptions: { show: { resource: ['webhookLogs'], operation: ['retryWebhookDelivery'] } },
|
|
2634
|
+
description: 'path parameter',
|
|
2635
|
+
},
|
|
2636
|
+
{
|
|
2637
|
+
displayName: 'id',
|
|
2638
|
+
name: 'id',
|
|
2639
|
+
type: 'string',
|
|
2640
|
+
default: '',
|
|
2641
|
+
required: true,
|
|
2642
|
+
displayOptions: { show: { resource: ['webhooks'], operation: ['addWebhookTopic'] } },
|
|
2643
|
+
description: 'path parameter',
|
|
2644
|
+
},
|
|
2645
|
+
{
|
|
2646
|
+
displayName: 'Body',
|
|
2647
|
+
name: 'body',
|
|
2648
|
+
type: 'json',
|
|
2649
|
+
default: '{}',
|
|
2650
|
+
required: true,
|
|
2651
|
+
displayOptions: { show: { resource: ['webhooks'], operation: ['addWebhookTopic'] } },
|
|
2652
|
+
description: 'Request body as JSON.',
|
|
2653
|
+
},
|
|
2654
|
+
{
|
|
2655
|
+
displayName: 'Body',
|
|
2656
|
+
name: 'body',
|
|
2657
|
+
type: 'json',
|
|
2658
|
+
default: '{}',
|
|
2659
|
+
required: true,
|
|
2660
|
+
displayOptions: { show: { resource: ['webhooks'], operation: ['Webhooks_create'] } },
|
|
2661
|
+
description: 'Request body as JSON.',
|
|
2662
|
+
},
|
|
2663
|
+
{
|
|
2664
|
+
displayName: 'id',
|
|
2665
|
+
name: 'id',
|
|
2666
|
+
type: 'options',
|
|
2667
|
+
typeOptions: { loadOptionsMethod: 'getWebhooks' },
|
|
2668
|
+
default: '',
|
|
2669
|
+
required: true,
|
|
2670
|
+
displayOptions: { show: { resource: ['webhooks'], operation: ['Webhooks_delete'] } },
|
|
2671
|
+
description: 'path parameter',
|
|
2672
|
+
},
|
|
2673
|
+
{
|
|
2674
|
+
displayName: 'id',
|
|
2675
|
+
name: 'id',
|
|
2676
|
+
type: 'options',
|
|
2677
|
+
typeOptions: { loadOptionsMethod: 'getWebhooks' },
|
|
2678
|
+
default: '',
|
|
2679
|
+
required: true,
|
|
2680
|
+
displayOptions: { show: { resource: ['webhooks'], operation: ['Webhooks_get'] } },
|
|
2681
|
+
description: 'path parameter',
|
|
2682
|
+
},
|
|
2683
|
+
{
|
|
2684
|
+
displayName: 'query',
|
|
2685
|
+
name: 'query',
|
|
2686
|
+
type: 'string',
|
|
2687
|
+
default: '',
|
|
2688
|
+
required: false,
|
|
2689
|
+
displayOptions: { show: { resource: ['webhooks'], operation: ['Webhooks_query'], returnAll: [false] } },
|
|
2690
|
+
description: 'String value to query webhooks.',
|
|
2691
|
+
},
|
|
2692
|
+
{
|
|
2693
|
+
displayName: 'page',
|
|
2694
|
+
name: 'page',
|
|
2695
|
+
type: 'number',
|
|
2696
|
+
default: 0,
|
|
2697
|
+
required: false,
|
|
2698
|
+
displayOptions: { show: { resource: ['webhooks'], operation: ['Webhooks_query'], returnAll: [false] } },
|
|
2699
|
+
description: 'query parameter',
|
|
2700
|
+
},
|
|
2701
|
+
{
|
|
2702
|
+
displayName: 'size',
|
|
2703
|
+
name: 'size',
|
|
2704
|
+
type: 'number',
|
|
2705
|
+
default: 0,
|
|
2706
|
+
required: false,
|
|
2707
|
+
displayOptions: { show: { resource: ['webhooks'], operation: ['Webhooks_query'], returnAll: [false] } },
|
|
2708
|
+
description: 'query parameter',
|
|
2709
|
+
},
|
|
2710
|
+
{
|
|
2711
|
+
displayName: 'active',
|
|
2712
|
+
name: 'active',
|
|
2713
|
+
type: 'boolean',
|
|
2714
|
+
default: false,
|
|
2715
|
+
required: false,
|
|
2716
|
+
displayOptions: { show: { resource: ['webhooks'], operation: ['Webhooks_query'], returnAll: [false] } },
|
|
2717
|
+
description: 'query parameter',
|
|
2718
|
+
},
|
|
2719
|
+
{
|
|
2720
|
+
displayName: 'topic',
|
|
2721
|
+
name: 'topic',
|
|
2722
|
+
type: 'string',
|
|
2723
|
+
default: '',
|
|
2724
|
+
required: false,
|
|
2725
|
+
displayOptions: { show: { resource: ['webhooks'], operation: ['Webhooks_query'] } },
|
|
2726
|
+
description: 'query parameter',
|
|
2727
|
+
},
|
|
2728
|
+
{
|
|
2729
|
+
displayName: 'sort',
|
|
2730
|
+
name: 'sort',
|
|
2731
|
+
type: 'string',
|
|
2732
|
+
default: '',
|
|
2733
|
+
required: false,
|
|
2734
|
+
displayOptions: { show: { resource: ['webhooks'], operation: ['Webhooks_query'] } },
|
|
2735
|
+
description: 'Sort field and order, format: field:asc/desc',
|
|
2736
|
+
},
|
|
2737
|
+
{
|
|
2738
|
+
displayName: 'status',
|
|
2739
|
+
name: 'status',
|
|
2740
|
+
type: 'string',
|
|
2741
|
+
default: '',
|
|
2742
|
+
required: false,
|
|
2743
|
+
displayOptions: { show: { resource: ['webhooks'], operation: ['Webhooks_query'] } },
|
|
2744
|
+
description: 'Filter value for the last delivery status of the webhook',
|
|
2745
|
+
},
|
|
2746
|
+
{
|
|
2747
|
+
displayName: 'accountId',
|
|
2748
|
+
name: 'accountId',
|
|
2749
|
+
type: 'string',
|
|
2750
|
+
default: '',
|
|
2751
|
+
required: false,
|
|
2752
|
+
displayOptions: { show: { resource: ['webhooks'], operation: ['Webhooks_query'] } },
|
|
2753
|
+
description: 'query parameter',
|
|
2754
|
+
},
|
|
2755
|
+
{
|
|
2756
|
+
displayName: 'id',
|
|
2757
|
+
name: 'id',
|
|
2758
|
+
type: 'options',
|
|
2759
|
+
typeOptions: { loadOptionsMethod: 'getWebhooks' },
|
|
2760
|
+
default: '',
|
|
2761
|
+
required: true,
|
|
2762
|
+
displayOptions: { show: { resource: ['webhooks'], operation: ['removeWebhookTopic'] } },
|
|
2763
|
+
description: 'path parameter',
|
|
2764
|
+
},
|
|
2765
|
+
{
|
|
2766
|
+
displayName: 'topicId',
|
|
2767
|
+
name: 'topicId',
|
|
2768
|
+
type: 'string',
|
|
2769
|
+
default: '',
|
|
2770
|
+
required: true,
|
|
2771
|
+
displayOptions: { show: { resource: ['webhooks'], operation: ['removeWebhookTopic'] } },
|
|
2772
|
+
description: 'path parameter',
|
|
2773
|
+
},
|
|
2774
|
+
{
|
|
2775
|
+
displayName: 'id',
|
|
2776
|
+
name: 'id',
|
|
2777
|
+
type: 'options',
|
|
2778
|
+
typeOptions: { loadOptionsMethod: 'getWebhooks' },
|
|
2779
|
+
default: '',
|
|
2780
|
+
required: true,
|
|
2781
|
+
displayOptions: { show: { resource: ['webhooks'], operation: ['replaceWebhookTopics'] } },
|
|
2782
|
+
description: 'path parameter',
|
|
2783
|
+
},
|
|
2784
|
+
{
|
|
2785
|
+
displayName: 'Body',
|
|
2786
|
+
name: 'body',
|
|
2787
|
+
type: 'json',
|
|
2788
|
+
default: '{}',
|
|
2789
|
+
required: true,
|
|
2790
|
+
displayOptions: { show: { resource: ['webhooks'], operation: ['replaceWebhookTopics'] } },
|
|
2791
|
+
description: 'Request body as JSON.',
|
|
2792
|
+
},
|
|
2793
|
+
{
|
|
2794
|
+
displayName: 'id',
|
|
2795
|
+
name: 'id',
|
|
2796
|
+
type: 'options',
|
|
2797
|
+
typeOptions: { loadOptionsMethod: 'getWebhooks' },
|
|
2798
|
+
default: '',
|
|
2799
|
+
required: true,
|
|
2800
|
+
displayOptions: { show: { resource: ['webhooks'], operation: ['testWebhookTopic'] } },
|
|
2801
|
+
description: 'path parameter',
|
|
2802
|
+
},
|
|
2803
|
+
{
|
|
2804
|
+
displayName: 'topic',
|
|
2805
|
+
name: 'topic',
|
|
2806
|
+
type: 'string',
|
|
2807
|
+
default: '',
|
|
2808
|
+
required: true,
|
|
2809
|
+
displayOptions: { show: { resource: ['webhooks'], operation: ['testWebhookTopic'] } },
|
|
2810
|
+
description: 'path parameter',
|
|
2811
|
+
},
|
|
2812
|
+
{
|
|
2813
|
+
displayName: 'id',
|
|
2814
|
+
name: 'id',
|
|
2815
|
+
type: 'options',
|
|
2816
|
+
typeOptions: { loadOptionsMethod: 'getWebhooks' },
|
|
2817
|
+
default: '',
|
|
2818
|
+
required: true,
|
|
2819
|
+
displayOptions: { show: { resource: ['webhooks'], operation: ['updateWebhookTopicConfiguration'] } },
|
|
2820
|
+
description: 'path parameter',
|
|
2821
|
+
},
|
|
2822
|
+
{
|
|
2823
|
+
displayName: 'topicId',
|
|
2824
|
+
name: 'topicId',
|
|
2825
|
+
type: 'string',
|
|
2826
|
+
default: '',
|
|
2827
|
+
required: true,
|
|
2828
|
+
displayOptions: { show: { resource: ['webhooks'], operation: ['updateWebhookTopicConfiguration'] } },
|
|
2829
|
+
description: 'path parameter',
|
|
2830
|
+
},
|
|
2831
|
+
{
|
|
2832
|
+
displayName: 'Body',
|
|
2833
|
+
name: 'body',
|
|
2834
|
+
type: 'json',
|
|
2835
|
+
default: '{}',
|
|
2836
|
+
required: true,
|
|
2837
|
+
displayOptions: { show: { resource: ['webhooks'], operation: ['updateWebhookTopicConfiguration'] } },
|
|
2838
|
+
description: 'Request body as JSON.',
|
|
2839
|
+
},
|
|
2840
|
+
{
|
|
2841
|
+
displayName: 'id',
|
|
2842
|
+
name: 'id',
|
|
2843
|
+
type: 'options',
|
|
2844
|
+
typeOptions: { loadOptionsMethod: 'getWebhooks' },
|
|
2845
|
+
default: '',
|
|
2846
|
+
required: true,
|
|
2847
|
+
displayOptions: { show: { resource: ['webhooks'], operation: ['updateConfiguration'] } },
|
|
2848
|
+
description: 'path parameter',
|
|
2849
|
+
},
|
|
2850
|
+
{
|
|
2851
|
+
displayName: 'Body',
|
|
2852
|
+
name: 'body',
|
|
2853
|
+
type: 'json',
|
|
2854
|
+
default: '{}',
|
|
2855
|
+
required: true,
|
|
2856
|
+
displayOptions: { show: { resource: ['webhooks'], operation: ['updateConfiguration'] } },
|
|
2857
|
+
description: 'Request body as JSON.',
|
|
2858
|
+
},
|
|
2859
|
+
{
|
|
2860
|
+
displayName: 'id',
|
|
2861
|
+
name: 'id',
|
|
2862
|
+
type: 'options',
|
|
2863
|
+
typeOptions: { loadOptionsMethod: 'getWebhooks' },
|
|
2864
|
+
default: '',
|
|
2865
|
+
required: true,
|
|
2866
|
+
displayOptions: { show: { resource: ['webhooks'], operation: ['updateStatus'] } },
|
|
2867
|
+
description: 'path parameter',
|
|
2868
|
+
},
|
|
2869
|
+
{
|
|
2870
|
+
displayName: 'Body',
|
|
2871
|
+
name: 'body',
|
|
2872
|
+
type: 'json',
|
|
2873
|
+
default: '{}',
|
|
2874
|
+
required: true,
|
|
2875
|
+
displayOptions: { show: { resource: ['webhooks'], operation: ['updateStatus'] } },
|
|
2876
|
+
description: 'Request body as JSON.',
|
|
2877
|
+
},
|
|
2878
|
+
],
|
|
2879
|
+
};
|
|
2880
|
+
this.methods = {
|
|
2881
|
+
loadOptions: {
|
|
2882
|
+
async getCompanies() {
|
|
2883
|
+
const authMode = this.getCurrentNodeParameter('authMode') || 'oauth2';
|
|
2884
|
+
const baseUrl = String(this.getCurrentNodeParameter('baseUrl') || 'https://api.pax8.com').replace(/\/$/, '');
|
|
2885
|
+
const items = [];
|
|
2886
|
+
let page = 0;
|
|
2887
|
+
const size = 200;
|
|
2888
|
+
for (let guard = 0; guard < 20; guard++) {
|
|
2889
|
+
const url = `${baseUrl}/companies`;
|
|
2890
|
+
const options = { method: 'GET', url, json: true, qs: { page, size } };
|
|
2891
|
+
const res = authMode === 'oauth2'
|
|
2892
|
+
? await this.helpers.httpRequestWithAuthentication.call(this, 'pax8OAuth2Api', options)
|
|
2893
|
+
: await (async () => {
|
|
2894
|
+
const creds = await this.getCredentials('pax8ApiToken');
|
|
2895
|
+
const token = creds.accessToken;
|
|
2896
|
+
options.headers = { ...(options.headers || {}), Authorization: `Bearer ${token}` };
|
|
2897
|
+
return this.helpers.httpRequest(options);
|
|
2898
|
+
})();
|
|
2899
|
+
const batch = extractListItems(res) || [];
|
|
2900
|
+
items.push(...batch);
|
|
2901
|
+
if (batch.length < size)
|
|
2902
|
+
break;
|
|
2903
|
+
page++;
|
|
2904
|
+
}
|
|
2905
|
+
return items.map((c) => ({
|
|
2906
|
+
name: c.name ? `${c.name} (${c.id || c.companyId || ''})` : String(c.id || c.companyId || ''),
|
|
2907
|
+
value: c.id || c.companyId,
|
|
2908
|
+
})).filter((o) => o.value);
|
|
2909
|
+
},
|
|
2910
|
+
async getProducts() {
|
|
2911
|
+
const authMode = this.getCurrentNodeParameter('authMode') || 'oauth2';
|
|
2912
|
+
const baseUrl = String(this.getCurrentNodeParameter('baseUrl') || 'https://api.pax8.com').replace(/\/$/, '');
|
|
2913
|
+
const items = [];
|
|
2914
|
+
let page = 0;
|
|
2915
|
+
const size = 200;
|
|
2916
|
+
for (let guard = 0; guard < 20; guard++) {
|
|
2917
|
+
const url = `${baseUrl}/products`;
|
|
2918
|
+
const options = { method: 'GET', url, json: true, qs: { page, size } };
|
|
2919
|
+
const res = authMode === 'oauth2'
|
|
2920
|
+
? await this.helpers.httpRequestWithAuthentication.call(this, 'pax8OAuth2Api', options)
|
|
2921
|
+
: await (async () => {
|
|
2922
|
+
const creds = await this.getCredentials('pax8ApiToken');
|
|
2923
|
+
const token = creds.accessToken;
|
|
2924
|
+
options.headers = { ...(options.headers || {}), Authorization: `Bearer ${token}` };
|
|
2925
|
+
return this.helpers.httpRequest(options);
|
|
2926
|
+
})();
|
|
2927
|
+
const batch = extractListItems(res) || [];
|
|
2928
|
+
items.push(...batch);
|
|
2929
|
+
if (batch.length < size)
|
|
2930
|
+
break;
|
|
2931
|
+
page++;
|
|
2932
|
+
}
|
|
2933
|
+
return items.map((p) => ({
|
|
2934
|
+
name: p.name ? `${p.vendorName ? p.vendorName + ' - ' : ''}${p.name} (${p.id || p.productId || ''})` : String(p.id || p.productId || ''),
|
|
2935
|
+
value: p.id || p.productId,
|
|
2936
|
+
})).filter((o) => o.value);
|
|
2937
|
+
},
|
|
2938
|
+
async getSubscriptions() {
|
|
2939
|
+
const authMode = this.getCurrentNodeParameter('authMode') || 'oauth2';
|
|
2940
|
+
const baseUrl = String(this.getCurrentNodeParameter('baseUrl') || 'https://api.pax8.com').replace(/\/$/, '');
|
|
2941
|
+
const companyId = this.getCurrentNodeParameter('companyId');
|
|
2942
|
+
const items = [];
|
|
2943
|
+
let page = 0;
|
|
2944
|
+
const size = 200;
|
|
2945
|
+
for (let guard = 0; guard < 20; guard++) {
|
|
2946
|
+
const url = `${baseUrl}/subscriptions`;
|
|
2947
|
+
const qs = { page, size };
|
|
2948
|
+
if (companyId)
|
|
2949
|
+
qs.companyId = companyId;
|
|
2950
|
+
const options = { method: 'GET', url, json: true, qs };
|
|
2951
|
+
const res = authMode === 'oauth2'
|
|
2952
|
+
? await this.helpers.httpRequestWithAuthentication.call(this, 'pax8OAuth2Api', options)
|
|
2953
|
+
: await (async () => {
|
|
2954
|
+
const creds = await this.getCredentials('pax8ApiToken');
|
|
2955
|
+
const token = creds.accessToken;
|
|
2956
|
+
options.headers = { ...(options.headers || {}), Authorization: `Bearer ${token}` };
|
|
2957
|
+
return this.helpers.httpRequest(options);
|
|
2958
|
+
})();
|
|
2959
|
+
const batch = extractListItems(res) || [];
|
|
2960
|
+
items.push(...batch);
|
|
2961
|
+
if (batch.length < size)
|
|
2962
|
+
break;
|
|
2963
|
+
page++;
|
|
2964
|
+
}
|
|
2965
|
+
return items.map((s) => ({
|
|
2966
|
+
name: s.friendlyName || s.name || s.productName ? `${s.friendlyName || s.name || s.productName} (${s.id || s.subscriptionId || ''})` : String(s.id || s.subscriptionId || ''),
|
|
2967
|
+
value: s.id || s.subscriptionId,
|
|
2968
|
+
})).filter((o) => o.value);
|
|
2969
|
+
},
|
|
2970
|
+
async getInvoices() {
|
|
2971
|
+
const authMode = this.getCurrentNodeParameter('authMode') || 'oauth2';
|
|
2972
|
+
const baseUrl = String(this.getCurrentNodeParameter('baseUrl') || 'https://api.pax8.com').replace(/\/$/, '');
|
|
2973
|
+
const companyId = this.getCurrentNodeParameter('companyId');
|
|
2974
|
+
const items = [];
|
|
2975
|
+
let page = 0;
|
|
2976
|
+
const size = 200;
|
|
2977
|
+
for (let guard = 0; guard < 20; guard++) {
|
|
2978
|
+
const url = `${baseUrl}/invoices`;
|
|
2979
|
+
const qs = { page, size };
|
|
2980
|
+
if (companyId)
|
|
2981
|
+
qs.companyId = companyId;
|
|
2982
|
+
const options = { method: 'GET', url, json: true, qs };
|
|
2983
|
+
const res = authMode === 'oauth2'
|
|
2984
|
+
? await this.helpers.httpRequestWithAuthentication.call(this, 'pax8OAuth2Api', options)
|
|
2985
|
+
: await (async () => {
|
|
2986
|
+
const creds = await this.getCredentials('pax8ApiToken');
|
|
2987
|
+
const token = creds.accessToken;
|
|
2988
|
+
options.headers = { ...(options.headers || {}), Authorization: `Bearer ${token}` };
|
|
2989
|
+
return this.helpers.httpRequest(options);
|
|
2990
|
+
})();
|
|
2991
|
+
const batch = extractListItems(res) || [];
|
|
2992
|
+
items.push(...batch);
|
|
2993
|
+
if (batch.length < size)
|
|
2994
|
+
break;
|
|
2995
|
+
page++;
|
|
2996
|
+
}
|
|
2997
|
+
return items.map((inv) => ({
|
|
2998
|
+
name: inv.invoiceNumber ? `${inv.invoiceNumber} (${inv.id || inv.invoiceId || ''})` : String(inv.id || inv.invoiceId || ''),
|
|
2999
|
+
value: inv.id || inv.invoiceId,
|
|
3000
|
+
})).filter((o) => o.value);
|
|
3001
|
+
},
|
|
3002
|
+
async getQuotes() {
|
|
3003
|
+
const authMode = this.getCurrentNodeParameter('authMode') || 'oauth2';
|
|
3004
|
+
const baseUrl = String(this.getCurrentNodeParameter('baseUrl') || 'https://api.pax8.com').replace(/\/$/, '');
|
|
3005
|
+
const items = [];
|
|
3006
|
+
let page = 0;
|
|
3007
|
+
const limit = 200;
|
|
3008
|
+
for (let guard = 0; guard < 20; guard++) {
|
|
3009
|
+
const url = `${baseUrl}/v2/quotes`;
|
|
3010
|
+
const options = { method: 'GET', url, json: true, qs: { page, limit } };
|
|
3011
|
+
const res = authMode === 'oauth2'
|
|
3012
|
+
? await this.helpers.httpRequestWithAuthentication.call(this, 'pax8OAuth2Api', options)
|
|
3013
|
+
: await (async () => {
|
|
3014
|
+
const creds = await this.getCredentials('pax8ApiToken');
|
|
3015
|
+
const token = creds.accessToken;
|
|
3016
|
+
options.headers = { ...(options.headers || {}), Authorization: `Bearer ${token}` };
|
|
3017
|
+
return this.helpers.httpRequest(options);
|
|
3018
|
+
})();
|
|
3019
|
+
const batch = extractListItems(res) || [];
|
|
3020
|
+
items.push(...batch);
|
|
3021
|
+
if (batch.length < limit)
|
|
3022
|
+
break;
|
|
3023
|
+
page++;
|
|
3024
|
+
}
|
|
3025
|
+
return items.map((q) => ({
|
|
3026
|
+
name: q.name ? `${q.name} (${q.id || q.quoteId || ''})` : String(q.id || q.quoteId || ''),
|
|
3027
|
+
value: q.id || q.quoteId,
|
|
3028
|
+
})).filter((o) => o.value);
|
|
3029
|
+
},
|
|
3030
|
+
async getWebhooks() {
|
|
3031
|
+
const authMode = this.getCurrentNodeParameter('authMode') || 'oauth2';
|
|
3032
|
+
const baseUrl = String(this.getCurrentNodeParameter('baseUrl') || 'https://api.pax8.com').replace(/\/$/, '');
|
|
3033
|
+
const items = [];
|
|
3034
|
+
let page = 0;
|
|
3035
|
+
const size = 200;
|
|
3036
|
+
for (let guard = 0; guard < 20; guard++) {
|
|
3037
|
+
const url = `${baseUrl}/webhooks`;
|
|
3038
|
+
const options = { method: 'GET', url, json: true, qs: { page, size } };
|
|
3039
|
+
const res = authMode === 'oauth2'
|
|
3040
|
+
? await this.helpers.httpRequestWithAuthentication.call(this, 'pax8OAuth2Api', options)
|
|
3041
|
+
: await (async () => {
|
|
3042
|
+
const creds = await this.getCredentials('pax8ApiToken');
|
|
3043
|
+
const token = creds.accessToken;
|
|
3044
|
+
options.headers = { ...(options.headers || {}), Authorization: `Bearer ${token}` };
|
|
3045
|
+
return this.helpers.httpRequest(options);
|
|
3046
|
+
})();
|
|
3047
|
+
const batch = extractListItems(res) || [];
|
|
3048
|
+
items.push(...batch);
|
|
3049
|
+
if (batch.length < size)
|
|
3050
|
+
break;
|
|
3051
|
+
page++;
|
|
3052
|
+
}
|
|
3053
|
+
return items.map((w) => ({
|
|
3054
|
+
name: w.name ? `${w.name} (${w.id || ''})` : String(w.id || ''),
|
|
3055
|
+
value: w.id,
|
|
3056
|
+
})).filter((o) => o.value);
|
|
3057
|
+
},
|
|
3058
|
+
async getContacts() {
|
|
3059
|
+
const authMode = this.getCurrentNodeParameter('authMode') || 'oauth2';
|
|
3060
|
+
const baseUrl = String(this.getCurrentNodeParameter('baseUrl') || 'https://api.pax8.com').replace(/\/$/, '');
|
|
3061
|
+
const companyId = this.getCurrentNodeParameter('companyId');
|
|
3062
|
+
if (!companyId)
|
|
3063
|
+
return [];
|
|
3064
|
+
const items = [];
|
|
3065
|
+
let page = 0;
|
|
3066
|
+
const size = 200;
|
|
3067
|
+
for (let guard = 0; guard < 20; guard++) {
|
|
3068
|
+
const url = `${baseUrl}/companies/${encodeURIComponent(companyId)}/contacts`;
|
|
3069
|
+
const options = { method: 'GET', url, json: true, qs: { page, size } };
|
|
3070
|
+
const res = authMode === 'oauth2'
|
|
3071
|
+
? await this.helpers.httpRequestWithAuthentication.call(this, 'pax8OAuth2Api', options)
|
|
3072
|
+
: await (async () => {
|
|
3073
|
+
const creds = await this.getCredentials('pax8ApiToken');
|
|
3074
|
+
const token = creds.accessToken;
|
|
3075
|
+
options.headers = { ...(options.headers || {}), Authorization: `Bearer ${token}` };
|
|
3076
|
+
return this.helpers.httpRequest(options);
|
|
3077
|
+
})();
|
|
3078
|
+
const batch = extractListItems(res) || [];
|
|
3079
|
+
items.push(...batch);
|
|
3080
|
+
if (batch.length < size)
|
|
3081
|
+
break;
|
|
3082
|
+
page++;
|
|
3083
|
+
}
|
|
3084
|
+
return items.map((c) => ({
|
|
3085
|
+
name: c.email ? `${c.email} (${c.id || c.contactId || ''})` : String(c.id || c.contactId || ''),
|
|
3086
|
+
value: c.id || c.contactId,
|
|
3087
|
+
})).filter((o) => o.value);
|
|
3088
|
+
},
|
|
3089
|
+
},
|
|
3090
|
+
};
|
|
3091
|
+
}
|
|
3092
|
+
async execute() {
|
|
3093
|
+
const items = this.getInputData();
|
|
3094
|
+
const returnData = [];
|
|
3095
|
+
for (let i = 0; i < items.length; i++) {
|
|
3096
|
+
const authMode = this.getNodeParameter('authMode', i);
|
|
3097
|
+
const baseUrl = this.getNodeParameter('baseUrl', i).replace(/\/$/, '');
|
|
3098
|
+
const resource = this.getNodeParameter('resource', i);
|
|
3099
|
+
const operation = this.getNodeParameter('operation', i);
|
|
3100
|
+
const def = OP_DEFS[operation];
|
|
3101
|
+
if (!def) {
|
|
3102
|
+
throw new Error(`Unknown operation: ${operation}`);
|
|
3103
|
+
}
|
|
3104
|
+
if (def.resource !== resource) {
|
|
3105
|
+
// Should not happen due to displayOptions, but keep safe.
|
|
3106
|
+
throw new Error(`Operation/resource mismatch: ${resource} / ${operation}`);
|
|
3107
|
+
}
|
|
3108
|
+
const pathParams = {};
|
|
3109
|
+
const queryParams = {};
|
|
3110
|
+
for (const p of def.params) {
|
|
3111
|
+
const value = this.getNodeParameter(p.name, i, p.required ? undefined : '');
|
|
3112
|
+
if (p.in === 'path')
|
|
3113
|
+
pathParams[p.name] = value;
|
|
3114
|
+
if (p.in === 'query')
|
|
3115
|
+
queryParams[p.name] = value;
|
|
3116
|
+
}
|
|
3117
|
+
// Return All / pagination helpers for list endpoints
|
|
3118
|
+
const pagination = LIST_PAGINATION[operation];
|
|
3119
|
+
let returnAll = false;
|
|
3120
|
+
let maxResults = 0;
|
|
3121
|
+
if (pagination) {
|
|
3122
|
+
returnAll = this.getNodeParameter('returnAll', i, false);
|
|
3123
|
+
maxResults = this.getNodeParameter('maxResults', i, 0);
|
|
3124
|
+
}
|
|
3125
|
+
const url = `${baseUrl}${applyPathParams(def.path, pathParams)}`;
|
|
3126
|
+
const makeRequest = async (qs) => {
|
|
3127
|
+
const options = {
|
|
3128
|
+
method: def.method,
|
|
3129
|
+
url,
|
|
3130
|
+
json: true,
|
|
3131
|
+
qs: cleanQuery(qs),
|
|
3132
|
+
};
|
|
3133
|
+
if (def.hasBody) {
|
|
3134
|
+
const body = this.getNodeParameter('body', i);
|
|
3135
|
+
options.body = body;
|
|
3136
|
+
}
|
|
3137
|
+
if (authMode === 'oauth2') {
|
|
3138
|
+
return this.helpers.httpRequestWithAuthentication.call(this, 'pax8OAuth2Api', options);
|
|
3139
|
+
}
|
|
3140
|
+
else {
|
|
3141
|
+
const creds = await this.getCredentials('pax8ApiToken');
|
|
3142
|
+
const token = creds.accessToken;
|
|
3143
|
+
options.headers = { ...(options.headers || {}), Authorization: `Bearer ${token}` };
|
|
3144
|
+
return this.helpers.httpRequest(options);
|
|
3145
|
+
}
|
|
3146
|
+
};
|
|
3147
|
+
if (pagination && returnAll) {
|
|
3148
|
+
const all = [];
|
|
3149
|
+
const pageParam = pagination.pageParam;
|
|
3150
|
+
const sizeParam = pagination.sizeParam;
|
|
3151
|
+
// Start values
|
|
3152
|
+
let page = Number(queryParams[pageParam] ?? 0);
|
|
3153
|
+
let pageSize = Number(queryParams[sizeParam] ?? pagination.defaultSize);
|
|
3154
|
+
if (!Number.isFinite(pageSize) || pageSize <= 0)
|
|
3155
|
+
pageSize = pagination.defaultSize;
|
|
3156
|
+
if (pagination.maxSize)
|
|
3157
|
+
pageSize = Math.min(pageSize, pagination.maxSize);
|
|
3158
|
+
// Use a larger page size when fetching all
|
|
3159
|
+
pageSize = pagination.maxSize ? pagination.maxSize : pageSize;
|
|
3160
|
+
for (let guard = 0; guard < 1000; guard++) {
|
|
3161
|
+
const qs = { ...queryParams, [pageParam]: page, [sizeParam]: pageSize };
|
|
3162
|
+
const responseData = await makeRequest(qs);
|
|
3163
|
+
const batch = extractListItems(responseData) || [];
|
|
3164
|
+
all.push(...batch);
|
|
3165
|
+
if (maxResults > 0 && all.length >= maxResults) {
|
|
3166
|
+
all.splice(maxResults);
|
|
3167
|
+
break;
|
|
3168
|
+
}
|
|
3169
|
+
if (batch.length < pageSize)
|
|
3170
|
+
break;
|
|
3171
|
+
page++;
|
|
3172
|
+
}
|
|
3173
|
+
for (const el of all) {
|
|
3174
|
+
returnData.push({ json: el });
|
|
3175
|
+
}
|
|
3176
|
+
}
|
|
3177
|
+
else {
|
|
3178
|
+
const responseData = await makeRequest(queryParams);
|
|
3179
|
+
// For list endpoints, return the array items (content) as separate output items
|
|
3180
|
+
if (pagination) {
|
|
3181
|
+
const batch = extractListItems(responseData) || [];
|
|
3182
|
+
for (const el of batch) {
|
|
3183
|
+
returnData.push({ json: el });
|
|
3184
|
+
}
|
|
3185
|
+
// If the API returned no content, fall back to returning the raw response
|
|
3186
|
+
if (batch.length === 0) {
|
|
3187
|
+
returnData.push({ json: responseData });
|
|
3188
|
+
}
|
|
3189
|
+
}
|
|
3190
|
+
else {
|
|
3191
|
+
returnData.push({ json: responseData });
|
|
3192
|
+
}
|
|
3193
|
+
}
|
|
3194
|
+
}
|
|
3195
|
+
return [returnData];
|
|
3196
|
+
}
|
|
3197
|
+
}
|
|
3198
|
+
exports.Pax8 = Pax8;
|