@membranehq/sdk 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/LICENSE +21 -0
- package/README.md +32 -0
- package/dist/bundle.d.ts +2543 -0
- package/dist/bundle.js +26089 -0
- package/dist/bundle.js.map +1 -0
- package/dist/dts/__mocks__/axios.d.ts +4 -0
- package/dist/dts/_helper.d.ts +7 -0
- package/dist/dts/_helper.test.d.ts +1 -0
- package/dist/dts/accessors.d.ts +85 -0
- package/dist/dts/accessors.test.d.ts +1 -0
- package/dist/dts/actions/accessors.d.ts +49 -0
- package/dist/dts/actions/action-types.d.ts +26 -0
- package/dist/dts/actions/index.d.ts +3 -0
- package/dist/dts/actions/types.d.ts +95 -0
- package/dist/dts/alerts/index.d.ts +1 -0
- package/dist/dts/alerts/types.d.ts +24 -0
- package/dist/dts/api-client.d.ts +32 -0
- package/dist/dts/api-client.test.d.ts +1 -0
- package/dist/dts/app-data-schemas/accessors.d.ts +18 -0
- package/dist/dts/app-data-schemas/api.d.ts +33 -0
- package/dist/dts/app-data-schemas/index.d.ts +23 -0
- package/dist/dts/app-events/accessors.d.ts +20 -0
- package/dist/dts/app-events/api.d.ts +44 -0
- package/dist/dts/app-events/index.d.ts +42 -0
- package/dist/dts/apps/index.d.ts +1 -0
- package/dist/dts/apps/types.d.ts +18 -0
- package/dist/dts/auth/accessors.d.ts +10 -0
- package/dist/dts/auth/index.d.ts +7 -0
- package/dist/dts/client.d.ts +70 -0
- package/dist/dts/connections/accessors.d.ts +88 -0
- package/dist/dts/connections/api.d.ts +27 -0
- package/dist/dts/connections/create-or-update-connection.d.ts +14 -0
- package/dist/dts/connections/index.d.ts +3 -0
- package/dist/dts/connections/types.d.ts +52 -0
- package/dist/dts/connector-copilot/index.d.ts +1 -0
- package/dist/dts/connector-copilot/types.d.ts +160 -0
- package/dist/dts/connectors/auth.d.ts +171 -0
- package/dist/dts/connectors/constants.d.ts +5 -0
- package/dist/dts/connectors/data-locations/base.d.ts +10 -0
- package/dist/dts/connectors/data-locations/collections/events/implementation-types/connector-event.d.ts +14 -0
- package/dist/dts/connectors/data-locations/collections/events/implementation-types/custom-pull.d.ts +14 -0
- package/dist/dts/connectors/data-locations/collections/events/implementation-types/full-scan.d.ts +7 -0
- package/dist/dts/connectors/data-locations/collections/events/implementation-types/pull-latest-records.d.ts +17 -0
- package/dist/dts/connectors/data-locations/collections/events/implementation-types/webhook.d.ts +18 -0
- package/dist/dts/connectors/data-locations/collections/events/index.d.ts +50 -0
- package/dist/dts/connectors/data-locations/collections/events/methods.d.ts +15 -0
- package/dist/dts/connectors/data-locations/collections/index.d.ts +70 -0
- package/dist/dts/connectors/data-locations/collections/methods/base.d.ts +24 -0
- package/dist/dts/connectors/data-locations/collections/methods/create.d.ts +7 -0
- package/dist/dts/connectors/data-locations/collections/methods/delete.d.ts +2 -0
- package/dist/dts/connectors/data-locations/collections/methods/find-by-id.d.ts +2 -0
- package/dist/dts/connectors/data-locations/collections/methods/find.d.ts +6 -0
- package/dist/dts/connectors/data-locations/collections/methods/list.d.ts +5 -0
- package/dist/dts/connectors/data-locations/collections/methods/match.d.ts +5 -0
- package/dist/dts/connectors/data-locations/collections/methods/search.d.ts +2 -0
- package/dist/dts/connectors/data-locations/collections/methods/update.d.ts +6 -0
- package/dist/dts/connectors/data-locations/directories/index.d.ts +17 -0
- package/dist/dts/connectors/data-locations/directories/methods/base.d.ts +18 -0
- package/dist/dts/connectors/data-locations/directories/methods/list.d.ts +2 -0
- package/dist/dts/connectors/data-locations/index.d.ts +6 -0
- package/dist/dts/connectors/data-locations/methods.d.ts +6 -0
- package/dist/dts/connectors/data-locations/types.d.ts +258 -0
- package/dist/dts/connectors/data-locations/utils.d.ts +17 -0
- package/dist/dts/connectors/data-locations/utils.test.d.ts +1 -0
- package/dist/dts/connectors/data-records.d.ts +7 -0
- package/dist/dts/connectors/events/index.d.ts +1 -0
- package/dist/dts/connectors/events/types.d.ts +36 -0
- package/dist/dts/connectors/global-webhooks/index.d.ts +1 -0
- package/dist/dts/connectors/global-webhooks/types.d.ts +33 -0
- package/dist/dts/connectors/graphql-api.d.ts +17 -0
- package/dist/dts/connectors/index.d.ts +13 -0
- package/dist/dts/connectors/methods.d.ts +44 -0
- package/dist/dts/connectors/openapi.d.ts +11 -0
- package/dist/dts/connectors/operations/handlers.d.ts +9 -0
- package/dist/dts/connectors/operations/index.d.ts +2 -0
- package/dist/dts/connectors/operations/types.d.ts +26 -0
- package/dist/dts/connectors/rest-api.d.ts +67 -0
- package/dist/dts/connectors/types.d.ts +75 -0
- package/dist/dts/connectors/udm.d.ts +14 -0
- package/dist/dts/data-builder/formula-processors.d.ts +13 -0
- package/dist/dts/data-builder/formula-processors.test.d.ts +1 -0
- package/dist/dts/data-builder/formula-types.d.ts +4 -0
- package/dist/dts/data-builder/formulas/and.d.ts +9 -0
- package/dist/dts/data-builder/formulas/and.test.d.ts +1 -0
- package/dist/dts/data-builder/formulas/base.d.ts +47 -0
- package/dist/dts/data-builder/formulas/case.d.ts +18 -0
- package/dist/dts/data-builder/formulas/case.test.d.ts +1 -0
- package/dist/dts/data-builder/formulas/concat.d.ts +19 -0
- package/dist/dts/data-builder/formulas/concat.test.d.ts +1 -0
- package/dist/dts/data-builder/formulas/copy.d.ts +10 -0
- package/dist/dts/data-builder/formulas/copy.test.d.ts +1 -0
- package/dist/dts/data-builder/formulas/dataSchemaRef.d.ts +22 -0
- package/dist/dts/data-builder/formulas/dataSchemaRef.test.d.ts +1 -0
- package/dist/dts/data-builder/formulas/domainFromEmail.d.ts +10 -0
- package/dist/dts/data-builder/formulas/domainFromEmail.test.d.ts +1 -0
- package/dist/dts/data-builder/formulas/eval.d.ts +28 -0
- package/dist/dts/data-builder/formulas/eval.test.d.ts +1 -0
- package/dist/dts/data-builder/formulas/extractDate.d.ts +11 -0
- package/dist/dts/data-builder/formulas/extractDate.test.d.ts +1 -0
- package/dist/dts/data-builder/formulas/extractTime.d.ts +11 -0
- package/dist/dts/data-builder/formulas/extractTime.test.d.ts +1 -0
- package/dist/dts/data-builder/formulas/findAppRecordId.d.ts +17 -0
- package/dist/dts/data-builder/formulas/findAppRecordId.test.d.ts +1 -0
- package/dist/dts/data-builder/formulas/findExternalRecordId.d.ts +17 -0
- package/dist/dts/data-builder/formulas/findExternalRecordId.test.d.ts +1 -0
- package/dist/dts/data-builder/formulas/first-name.d.ts +10 -0
- package/dist/dts/data-builder/formulas/first-name.test.d.ts +1 -0
- package/dist/dts/data-builder/formulas/firstNotEmpty.d.ts +7 -0
- package/dist/dts/data-builder/formulas/firstNotEmpty.test.d.ts +1 -0
- package/dist/dts/data-builder/formulas/formula.d.ts +8 -0
- package/dist/dts/data-builder/formulas/formula.test.d.ts +1 -0
- package/dist/dts/data-builder/formulas/index.d.ts +26 -0
- package/dist/dts/data-builder/formulas/index.test.d.ts +1 -0
- package/dist/dts/data-builder/formulas/iterate.d.ts +19 -0
- package/dist/dts/data-builder/formulas/iterate.test.d.ts +1 -0
- package/dist/dts/data-builder/formulas/jsonata.d.ts +8 -0
- package/dist/dts/data-builder/formulas/jsonata.test.d.ts +1 -0
- package/dist/dts/data-builder/formulas/last-name.d.ts +11 -0
- package/dist/dts/data-builder/formulas/last-name.test.d.ts +1 -0
- package/dist/dts/data-builder/formulas/lookup.d.ts +12 -0
- package/dist/dts/data-builder/formulas/lookup.test.d.ts +1 -0
- package/dist/dts/data-builder/formulas/map.d.ts +17 -0
- package/dist/dts/data-builder/formulas/map.test.d.ts +1 -0
- package/dist/dts/data-builder/formulas/mergeObjects.d.ts +12 -0
- package/dist/dts/data-builder/formulas/mergeObjects.test.d.ts +1 -0
- package/dist/dts/data-builder/formulas/or.d.ts +9 -0
- package/dist/dts/data-builder/formulas/or.test.d.ts +1 -0
- package/dist/dts/data-builder/formulas/plain.d.ts +8 -0
- package/dist/dts/data-builder/formulas/plain.test.d.ts +1 -0
- package/dist/dts/data-builder/formulas/record.d.ts +11 -0
- package/dist/dts/data-builder/formulas/record.test.d.ts +1 -0
- package/dist/dts/data-builder/formulas/tpl.d.ts +15 -0
- package/dist/dts/data-builder/formulas/tpl.test.d.ts +1 -0
- package/dist/dts/data-builder/formulas/types.d.ts +27 -0
- package/dist/dts/data-builder/formulas/var.d.ts +11 -0
- package/dist/dts/data-builder/formulas/var.test.d.ts +1 -0
- package/dist/dts/data-builder/index.d.ts +9 -0
- package/dist/dts/data-builder/index.test.d.ts +1 -0
- package/dist/dts/data-builder/locators.d.ts +44 -0
- package/dist/dts/data-builder/locators.test.d.ts +1 -0
- package/dist/dts/data-collections/index.d.ts +1 -0
- package/dist/dts/data-collections/types.d.ts +24 -0
- package/dist/dts/data-filter/index.d.ts +13 -0
- package/dist/dts/data-filter/index.test.d.ts +1 -0
- package/dist/dts/data-filter/operators.d.ts +13 -0
- package/dist/dts/data-filter/operators.test.d.ts +1 -0
- package/dist/dts/data-form/data-field.d.ts +7 -0
- package/dist/dts/data-form/index.d.ts +21 -0
- package/dist/dts/data-links/accessors.d.ts +20 -0
- package/dist/dts/data-links/api.d.ts +56 -0
- package/dist/dts/data-links/index.d.ts +36 -0
- package/dist/dts/data-schema/create.d.ts +2 -0
- package/dist/dts/data-schema/create.test.d.ts +1 -0
- package/dist/dts/data-schema/data-field.d.ts +14 -0
- package/dist/dts/data-schema/index.d.ts +5 -0
- package/dist/dts/data-schema/merge.d.ts +10 -0
- package/dist/dts/data-schema/merge.test.d.ts +1 -0
- package/dist/dts/data-schema/types.d.ts +35 -0
- package/dist/dts/data-schema/utils.d.ts +47 -0
- package/dist/dts/data-schema/utils.test.d.ts +1 -0
- package/dist/dts/data-sources/accessors.d.ts +64 -0
- package/dist/dts/data-sources/api.d.ts +90 -0
- package/dist/dts/data-sources/constants.d.ts +4 -0
- package/dist/dts/data-sources/index.d.ts +4 -0
- package/dist/dts/data-sources/types.d.ts +63 -0
- package/dist/dts/date-time/index.d.ts +1 -0
- package/dist/dts/date-time/parse.d.ts +1 -0
- package/dist/dts/date-time/parse.test.d.ts +1 -0
- package/dist/dts/datetime.d.ts +1 -0
- package/dist/dts/entity-repository.d.ts +24 -0
- package/dist/dts/errors/error-doc-enum.d.ts +7 -0
- package/dist/dts/errors/index.d.ts +105 -0
- package/dist/dts/external-events/accessors.d.ts +19 -0
- package/dist/dts/external-events/api.d.ts +22 -0
- package/dist/dts/external-events/index.d.ts +8 -0
- package/dist/dts/external-events/types.d.ts +157 -0
- package/dist/dts/field-mappings/accessors.d.ts +54 -0
- package/dist/dts/field-mappings/api.d.ts +58 -0
- package/dist/dts/field-mappings/index.d.ts +66 -0
- package/dist/dts/field-mappings/merge/is-object.test.d.ts +1 -0
- package/dist/dts/field-mappings/merge/merge-with-formulas.d.ts +2 -0
- package/dist/dts/field-mappings/merge/merge-with-formulas.test.d.ts +1 -0
- package/dist/dts/field-mappings/types.d.ts +12 -0
- package/dist/dts/flow-runs/accessors.d.ts +33 -0
- package/dist/dts/flow-runs/flow-node-runs.d.ts +42 -0
- package/dist/dts/flow-runs/index.d.ts +78 -0
- package/dist/dts/flows/accessors.d.ts +75 -0
- package/dist/dts/flows/api.d.ts +54 -0
- package/dist/dts/flows/index.d.ts +6 -0
- package/dist/dts/flows/nodes/api-request-to-external-app.d.ts +3 -0
- package/dist/dts/flows/nodes/api-request-to-your-app.d.ts +3 -0
- package/dist/dts/flows/nodes/api-trigger.d.ts +3 -0
- package/dist/dts/flows/nodes/app-event-trigger.d.ts +3 -0
- package/dist/dts/flows/nodes/base.d.ts +17 -0
- package/dist/dts/flows/nodes/connector-event-trigger.d.ts +3 -0
- package/dist/dts/flows/nodes/create-data-link.d.ts +3 -0
- package/dist/dts/flows/nodes/create-data-record.d.ts +3 -0
- package/dist/dts/flows/nodes/custom-http-request.d.ts +3 -0
- package/dist/dts/flows/nodes/data-record-created-trigger.d.ts +3 -0
- package/dist/dts/flows/nodes/data-record-deleted-trigger.d.ts +3 -0
- package/dist/dts/flows/nodes/data-record-updated-trigger.d.ts +3 -0
- package/dist/dts/flows/nodes/delete-data-link.d.ts +3 -0
- package/dist/dts/flows/nodes/delete-data-record.d.ts +3 -0
- package/dist/dts/flows/nodes/filter.d.ts +3 -0
- package/dist/dts/flows/nodes/find-data-link.d.ts +3 -0
- package/dist/dts/flows/nodes/find-data-record-by-id.d.ts +3 -0
- package/dist/dts/flows/nodes/find-data-records.d.ts +3 -0
- package/dist/dts/flows/nodes/find-or-create-data-record.d.ts +3 -0
- package/dist/dts/flows/nodes/for-each-v2.d.ts +3 -0
- package/dist/dts/flows/nodes/for-each.d.ts +3 -0
- package/dist/dts/flows/nodes/index.d.ts +37 -0
- package/dist/dts/flows/nodes/integration-specific-operation.d.ts +3 -0
- package/dist/dts/flows/nodes/list-data-records.d.ts +3 -0
- package/dist/dts/flows/nodes/lookup-data-record.d.ts +3 -0
- package/dist/dts/flows/nodes/run-action.d.ts +3 -0
- package/dist/dts/flows/nodes/run-javascript.d.ts +3 -0
- package/dist/dts/flows/nodes/schedule-trigger.d.ts +3 -0
- package/dist/dts/flows/nodes/search-data-records.d.ts +3 -0
- package/dist/dts/flows/nodes/transform-data.d.ts +3 -0
- package/dist/dts/flows/nodes/update-data-record.d.ts +3 -0
- package/dist/dts/flows/schemas.d.ts +240 -0
- package/dist/dts/flows/types.d.ts +77 -0
- package/dist/dts/flows/utils.d.ts +16 -0
- package/dist/dts/flows/utils.test.d.ts +1 -0
- package/dist/dts/http-requests.d.ts +37 -0
- package/dist/dts/iframe.d.ts +11 -0
- package/dist/dts/index.d.ts +41 -0
- package/dist/dts/index.umd.d.ts +2 -0
- package/dist/dts/integration-elements/common.d.ts +3 -0
- package/dist/dts/integration-elements/connection-level-element.accessor.d.ts +29 -0
- package/dist/dts/integration-elements/index.d.ts +74 -0
- package/dist/dts/integration-elements/integration-level-element.accessor.d.ts +25 -0
- package/dist/dts/integrations/accessors.d.ts +58 -0
- package/dist/dts/integrations/api.d.ts +23 -0
- package/dist/dts/integrations/index.d.ts +3 -0
- package/dist/dts/integrations/types.d.ts +38 -0
- package/dist/dts/jwt.d.ts +1 -0
- package/dist/dts/jwt.test.d.ts +1 -0
- package/dist/dts/logging/index.d.ts +8 -0
- package/dist/dts/logging/index.test.d.ts +1 -0
- package/dist/dts/logging/types.d.ts +13 -0
- package/dist/dts/orgs/index.d.ts +1 -0
- package/dist/dts/orgs/types.d.ts +59 -0
- package/dist/dts/scenarios/accessors.d.ts +9 -0
- package/dist/dts/scenarios/index.d.ts +2 -0
- package/dist/dts/scenarios/types.d.ts +145 -0
- package/dist/dts/screens/accessors.d.ts +9 -0
- package/dist/dts/screens/index.d.ts +2 -0
- package/dist/dts/screens/types.d.ts +37 -0
- package/dist/dts/udm/activities.d.ts +143 -0
- package/dist/dts/udm/activities.test.d.ts +1 -0
- package/dist/dts/udm/base.d.ts +62 -0
- package/dist/dts/udm/bills.d.ts +3 -0
- package/dist/dts/udm/campaign-members.d.ts +3 -0
- package/dist/dts/udm/campaigns.d.ts +3 -0
- package/dist/dts/udm/companies.d.ts +3 -0
- package/dist/dts/udm/contact-lists.d.ts +3 -0
- package/dist/dts/udm/contacts.d.ts +3 -0
- package/dist/dts/udm/credit-notes.d.ts +3 -0
- package/dist/dts/udm/customers.d.ts +3 -0
- package/dist/dts/udm/deal-products.d.ts +3 -0
- package/dist/dts/udm/deal-stages.d.ts +3 -0
- package/dist/dts/udm/deals.d.ts +3 -0
- package/dist/dts/udm/documents.d.ts +59 -0
- package/dist/dts/udm/drive-items.d.ts +78 -0
- package/dist/dts/udm/drives.d.ts +46 -0
- package/dist/dts/udm/eeocs.d.ts +3 -0
- package/dist/dts/udm/emails.d.ts +115 -0
- package/dist/dts/udm/employees.d.ts +3 -0
- package/dist/dts/udm/files.d.ts +73 -0
- package/dist/dts/udm/folders.d.ts +66 -0
- package/dist/dts/udm/index.d.ts +53 -0
- package/dist/dts/udm/invoices.d.ts +3 -0
- package/dist/dts/udm/job-applications.d.ts +3 -0
- package/dist/dts/udm/job-candidates.d.ts +3 -0
- package/dist/dts/udm/job-interviews.d.ts +3 -0
- package/dist/dts/udm/job-offers.d.ts +3 -0
- package/dist/dts/udm/jobs.d.ts +3 -0
- package/dist/dts/udm/journal-entries.d.ts +3 -0
- package/dist/dts/udm/leads.d.ts +3 -0
- package/dist/dts/udm/ledger-accounts.d.ts +3 -0
- package/dist/dts/udm/meetings.d.ts +98 -0
- package/dist/dts/udm/messages.d.ts +51 -0
- package/dist/dts/udm/notes.d.ts +61 -0
- package/dist/dts/udm/orders.d.ts +3 -0
- package/dist/dts/udm/payments.d.ts +3 -0
- package/dist/dts/udm/payrolls.d.ts +3 -0
- package/dist/dts/udm/products.d.ts +3 -0
- package/dist/dts/udm/projects.d.ts +3 -0
- package/dist/dts/udm/suppliers.d.ts +3 -0
- package/dist/dts/udm/tasks.d.ts +104 -0
- package/dist/dts/udm/tax-rates.d.ts +3 -0
- package/dist/dts/udm/timeoff-balances.d.ts +3 -0
- package/dist/dts/udm/timeoff-requests.d.ts +3 -0
- package/dist/dts/udm/users.d.ts +3 -0
- package/dist/dts/usage/index.d.ts +1 -0
- package/dist/dts/usage/types.d.ts +33 -0
- package/dist/dts/users/accessors.d.ts +10 -0
- package/dist/dts/users/api.d.ts +23 -0
- package/dist/dts/users/index.d.ts +13 -0
- package/dist/dts/variables.d.ts +27 -0
- package/dist/dts/webhooks/index.d.ts +1 -0
- package/dist/dts/webhooks/types.d.ts +11 -0
- package/dist/dts/workspace-elements/index.d.ts +1 -0
- package/dist/dts/workspace-elements/types.d.ts +77 -0
- package/dist/dts/workspace-elements-catalog/index.d.ts +27 -0
- package/dist/dts/workspace-updates/index.d.ts +1 -0
- package/dist/dts/workspace-updates/types.d.ts +6 -0
- package/dist/dts/workspaces/api.d.ts +5 -0
- package/dist/dts/workspaces/constants.d.ts +4 -0
- package/dist/dts/workspaces/index.d.ts +3 -0
- package/dist/dts/workspaces/types.d.ts +175 -0
- package/dist/index.d.ts +5022 -0
- package/dist/index.js +11815 -0
- package/dist/index.js.map +1 -0
- package/dist/index.module.d.mts +5022 -0
- package/dist/index.module.mjs +11551 -0
- package/dist/index.module.mjs.map +1 -0
- package/package.json +96 -0
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
type StructuredCloneType = <T>(value: T) => T;
|
|
2
|
+
export declare const structuredClone: StructuredCloneType;
|
|
3
|
+
export declare function isNil(value?: any): boolean;
|
|
4
|
+
export declare function omitBy(obj: Record<string, any>, check: (value: any) => boolean): Record<string, any>;
|
|
5
|
+
export declare function isEmptyValue(value?: any): boolean;
|
|
6
|
+
export declare const simpleUniqueId: () => string;
|
|
7
|
+
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1,85 @@
|
|
|
1
|
+
import { IntegrationAppApiClient } from './api-client';
|
|
2
|
+
import { PaginationResponse } from './entity-repository';
|
|
3
|
+
import { WorkspaceElementType } from './workspace-elements';
|
|
4
|
+
export interface BaseElementInstance {
|
|
5
|
+
id: string;
|
|
6
|
+
}
|
|
7
|
+
export interface ElementInstanceSelector {
|
|
8
|
+
id?: string;
|
|
9
|
+
autoCreate?: boolean;
|
|
10
|
+
instanceKey?: string;
|
|
11
|
+
userId?: string;
|
|
12
|
+
parentKey?: string;
|
|
13
|
+
parentId?: string;
|
|
14
|
+
}
|
|
15
|
+
export interface IntegrationSpecificElementSelector {
|
|
16
|
+
id?: string;
|
|
17
|
+
key?: string;
|
|
18
|
+
integrationId?: string;
|
|
19
|
+
integrationKey?: string;
|
|
20
|
+
}
|
|
21
|
+
type SelectorType = {
|
|
22
|
+
id?: string;
|
|
23
|
+
} | string;
|
|
24
|
+
export declare class ElementAccessor<Element, UpdateRequest, Selector extends SelectorType = string> {
|
|
25
|
+
protected options: {
|
|
26
|
+
client: IntegrationAppApiClient;
|
|
27
|
+
path: string;
|
|
28
|
+
selector: string | Selector;
|
|
29
|
+
};
|
|
30
|
+
constructor(options: {
|
|
31
|
+
client: IntegrationAppApiClient;
|
|
32
|
+
path: string;
|
|
33
|
+
selector: string | Selector;
|
|
34
|
+
});
|
|
35
|
+
getUniqueIdentifier(): string;
|
|
36
|
+
get(): Promise<Element>;
|
|
37
|
+
put(data: UpdateRequest): Promise<Element>;
|
|
38
|
+
patch(data: Partial<UpdateRequest>): Promise<Element>;
|
|
39
|
+
archive(): Promise<void>;
|
|
40
|
+
restore(): Promise<Element>;
|
|
41
|
+
getPath(operation?: string): string;
|
|
42
|
+
}
|
|
43
|
+
export declare class ElementListAccessor<Element, FindQuery, CreateRequest> {
|
|
44
|
+
private client;
|
|
45
|
+
private path;
|
|
46
|
+
constructor(client: IntegrationAppApiClient, path: string);
|
|
47
|
+
find(query?: FindQuery): Promise<PaginationResponse<Element>>;
|
|
48
|
+
findAll(query?: Omit<FindQuery, 'limit'>): Promise<Element[]>;
|
|
49
|
+
create(data: CreateRequest): Promise<Element>;
|
|
50
|
+
}
|
|
51
|
+
export declare class ElementInstanceListAccessor<ElementInstance extends BaseElementInstance, FindQuery> {
|
|
52
|
+
protected client: IntegrationAppApiClient;
|
|
53
|
+
private path;
|
|
54
|
+
constructor(client: IntegrationAppApiClient, path: string);
|
|
55
|
+
find(query?: FindQuery): Promise<PaginationResponse<ElementInstance>>;
|
|
56
|
+
}
|
|
57
|
+
export declare class ElementInstanceAccessor<ElementInstance extends BaseElementInstance, Selector extends {
|
|
58
|
+
id?: string;
|
|
59
|
+
}, CreateRequest, UpdateRequest> {
|
|
60
|
+
protected options: {
|
|
61
|
+
client: IntegrationAppApiClient;
|
|
62
|
+
instancePath: string;
|
|
63
|
+
selector: string | Selector;
|
|
64
|
+
type?: WorkspaceElementType;
|
|
65
|
+
};
|
|
66
|
+
private id;
|
|
67
|
+
constructor(options: {
|
|
68
|
+
client: IntegrationAppApiClient;
|
|
69
|
+
instancePath: string;
|
|
70
|
+
selector: string | Selector;
|
|
71
|
+
type?: WorkspaceElementType;
|
|
72
|
+
});
|
|
73
|
+
getUniqueIdentifier(): string;
|
|
74
|
+
get(): Promise<ElementInstance>;
|
|
75
|
+
getId(): Promise<string>;
|
|
76
|
+
create(data?: CreateRequest): Promise<ElementInstance>;
|
|
77
|
+
put(data: CreateRequest): Promise<ElementInstance>;
|
|
78
|
+
patch(data: UpdateRequest): Promise<ElementInstance>;
|
|
79
|
+
archive(): Promise<void>;
|
|
80
|
+
delete(): Promise<void>;
|
|
81
|
+
restore(): Promise<ElementInstance>;
|
|
82
|
+
protected getPath(operation?: string): string;
|
|
83
|
+
private getSelector;
|
|
84
|
+
}
|
|
85
|
+
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
import { ElementAccessor, ElementInstanceAccessor, ElementInstanceListAccessor, ElementListAccessor } from '../accessors';
|
|
2
|
+
import { IntegrationAppApiClient } from '../api-client';
|
|
3
|
+
import { Action, ActionInstance, ActionInstanceSelector, ActionRunResponse, ActionSelector, CreateActionInstanceRequest, CreateActionRequest, FindActionInstancesQuery, FindActionsQuery, ListActionInstancesForConnectionQuery, ListActionsForIntegrationQuery, OpenActionConfigurationOptions, UpdateActionInstanceRequest, UpdateActionRequest } from './types';
|
|
4
|
+
import { InstanceKeyQuery } from '../integration-elements/common';
|
|
5
|
+
import { ConnectionLevelElementAccessor, ConnectionLevelElementsListAccessor } from '../integration-elements/connection-level-element.accessor';
|
|
6
|
+
import { IntegrationLevelElementAccessor, IntegrationLevelElementsListAccessor } from '../integration-elements/integration-level-element.accessor';
|
|
7
|
+
export declare class ActionsAccessor extends ElementListAccessor<Action, FindActionsQuery, CreateActionRequest> {
|
|
8
|
+
constructor(client: IntegrationAppApiClient);
|
|
9
|
+
}
|
|
10
|
+
export declare class ActionAccessor extends ElementAccessor<Action, UpdateActionRequest, ActionSelector> {
|
|
11
|
+
constructor(client: IntegrationAppApiClient, selector: ActionSelector | string);
|
|
12
|
+
apply(integrationKeys: string[]): Promise<Action[]>;
|
|
13
|
+
reset(): Promise<any>;
|
|
14
|
+
}
|
|
15
|
+
export declare class ActionInstancesAccessor extends ElementInstanceListAccessor<ActionInstance, FindActionInstancesQuery> {
|
|
16
|
+
constructor(client: IntegrationAppApiClient);
|
|
17
|
+
}
|
|
18
|
+
export declare class ActionInstanceAccessor extends ElementInstanceAccessor<ActionInstance, ActionInstanceSelector, CreateActionInstanceRequest, UpdateActionInstanceRequest> {
|
|
19
|
+
client: IntegrationAppApiClient;
|
|
20
|
+
constructor(client: IntegrationAppApiClient, selector: string | ActionInstanceSelector);
|
|
21
|
+
setup(): Promise<void>;
|
|
22
|
+
reset(): Promise<void>;
|
|
23
|
+
run(input?: any): Promise<ActionRunResponse>;
|
|
24
|
+
open({ onClose }?: OpenActionConfigurationOptions): Promise<void>;
|
|
25
|
+
}
|
|
26
|
+
export declare class IntegrationLevelActionAccessor extends IntegrationLevelElementAccessor<Action, UpdateActionRequest> {
|
|
27
|
+
client: IntegrationAppApiClient;
|
|
28
|
+
integrationSelector: string;
|
|
29
|
+
actionSelector: string;
|
|
30
|
+
constructor(client: IntegrationAppApiClient, integrationSelector: string, actionSelector: string);
|
|
31
|
+
}
|
|
32
|
+
export declare class IntegrationLevelActionsListAccessor extends IntegrationLevelElementsListAccessor<Action, ListActionsForIntegrationQuery, Omit<CreateActionRequest, 'integrationId'>> {
|
|
33
|
+
client: IntegrationAppApiClient;
|
|
34
|
+
integrationSelector: string;
|
|
35
|
+
constructor(client: IntegrationAppApiClient, integrationSelector: string);
|
|
36
|
+
}
|
|
37
|
+
export declare class ConnectionLevelActionAccessor extends ConnectionLevelElementAccessor<ActionInstance, UpdateActionInstanceRequest> {
|
|
38
|
+
client: IntegrationAppApiClient;
|
|
39
|
+
connectionSelector: string;
|
|
40
|
+
actionSelector: string;
|
|
41
|
+
query: InstanceKeyQuery;
|
|
42
|
+
constructor(client: IntegrationAppApiClient, connectionSelector: string, actionSelector: string, query: InstanceKeyQuery);
|
|
43
|
+
run(input?: any): Promise<ActionRunResponse>;
|
|
44
|
+
}
|
|
45
|
+
export declare class ConnectionLevelActionsAccessor extends ConnectionLevelElementsListAccessor<Action, ListActionInstancesForConnectionQuery> {
|
|
46
|
+
client: IntegrationAppApiClient;
|
|
47
|
+
connectionSelector: string;
|
|
48
|
+
constructor(client: IntegrationAppApiClient, connectionSelector: string);
|
|
49
|
+
}
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
import { FieldMappingDirection } from '../field-mappings';
|
|
2
|
+
export declare enum ActionType {
|
|
3
|
+
ListDataRecords = "list-data-records",
|
|
4
|
+
FindDataRecordById = "find-data-record-by-id",
|
|
5
|
+
MatchDataRecord = "match-data-record",
|
|
6
|
+
CreateDataRecord = "create-data-record",
|
|
7
|
+
FindOrCreateDataRecord = "find-or-create-data-record",
|
|
8
|
+
UpdateDataRecord = "update-data-record",
|
|
9
|
+
DeleteDataRecord = "delete-data-record",
|
|
10
|
+
SearchDataRecords = "search-data-record",
|
|
11
|
+
ConnectorOperation = "connector-operation",
|
|
12
|
+
ApiRequestToExternalApp = "api-request-to-external-app",
|
|
13
|
+
ApiRequestToYourApp = "api-request-to-your-app",
|
|
14
|
+
HttpRequest = "http-request",
|
|
15
|
+
RunJavascript = "run-javascript",
|
|
16
|
+
ApiRequest = "api-request"
|
|
17
|
+
}
|
|
18
|
+
export interface ActionSpec {
|
|
19
|
+
name: string;
|
|
20
|
+
description: string;
|
|
21
|
+
direction?: FieldMappingDirection;
|
|
22
|
+
isDataAction?: boolean;
|
|
23
|
+
isDeprecated?: boolean;
|
|
24
|
+
}
|
|
25
|
+
export declare function isDataActionType(type: string | ActionType): any;
|
|
26
|
+
export declare const ACTIONS: Record<ActionType, ActionSpec>;
|
|
@@ -0,0 +1,95 @@
|
|
|
1
|
+
import { ElementInstanceSelector, IntegrationSpecificElementSelector } from '../accessors';
|
|
2
|
+
import { ConnectionSelector } from '../connections';
|
|
3
|
+
import { DataSchema } from '../data-schema';
|
|
4
|
+
import { PaginationQuery } from '../entity-repository';
|
|
5
|
+
import { OpenConfigurationOptions } from '../iframe';
|
|
6
|
+
import { ElementInstanceFields, ElementTemplateFields } from '../integration-elements';
|
|
7
|
+
import { AppliedToIntegrations } from '../integrations';
|
|
8
|
+
import { ActionType } from './action-types';
|
|
9
|
+
import { WorkspaceElementDependency, WorkspaceElementState } from '../workspace-elements';
|
|
10
|
+
export declare enum ActionDependencyType {
|
|
11
|
+
FieldMapping = "FieldMapping",
|
|
12
|
+
DataSource = "DataSource"
|
|
13
|
+
}
|
|
14
|
+
export interface ActionDependency {
|
|
15
|
+
type: ActionDependencyType;
|
|
16
|
+
key: string;
|
|
17
|
+
element?: any;
|
|
18
|
+
}
|
|
19
|
+
export interface Action extends ElementTemplateFields {
|
|
20
|
+
type: ActionType;
|
|
21
|
+
inputSchema?: DataSchema;
|
|
22
|
+
config?: any;
|
|
23
|
+
outputMapping?: any;
|
|
24
|
+
customOutputSchema?: DataSchema;
|
|
25
|
+
defaultOutputSchema?: DataSchema;
|
|
26
|
+
transformedOutputSchema?: DataSchema;
|
|
27
|
+
outputSchema?: DataSchema;
|
|
28
|
+
appliedToIntegrations?: AppliedToIntegrations<Action>;
|
|
29
|
+
dependencies?: WorkspaceElementDependency[];
|
|
30
|
+
isDeployed?: boolean;
|
|
31
|
+
}
|
|
32
|
+
export interface ActionInstance extends ElementInstanceFields {
|
|
33
|
+
type: ActionType;
|
|
34
|
+
parent?: Action;
|
|
35
|
+
instanceKey?: string;
|
|
36
|
+
inputSchema?: any;
|
|
37
|
+
config?: any;
|
|
38
|
+
outputSchema?: any;
|
|
39
|
+
isOutdated?: boolean;
|
|
40
|
+
state: WorkspaceElementState;
|
|
41
|
+
}
|
|
42
|
+
export interface ListActionsForIntegrationQuery extends PaginationQuery {
|
|
43
|
+
parentId?: string | 'null';
|
|
44
|
+
}
|
|
45
|
+
export interface FindActionsQuery extends ListActionsForIntegrationQuery {
|
|
46
|
+
integrationId?: string | 'null';
|
|
47
|
+
}
|
|
48
|
+
export type CreateActionRequest = {
|
|
49
|
+
key: string;
|
|
50
|
+
name: string;
|
|
51
|
+
type?: ActionType;
|
|
52
|
+
inputSchema?: any;
|
|
53
|
+
config?: any;
|
|
54
|
+
integrationId?: string;
|
|
55
|
+
};
|
|
56
|
+
export type UpdateActionRequest = {
|
|
57
|
+
key?: string;
|
|
58
|
+
type?: ActionType;
|
|
59
|
+
name?: string;
|
|
60
|
+
inputSchema?: any;
|
|
61
|
+
config?: any;
|
|
62
|
+
archivedAt?: string;
|
|
63
|
+
};
|
|
64
|
+
export interface ActionSelector extends IntegrationSpecificElementSelector {
|
|
65
|
+
}
|
|
66
|
+
export interface ActionInstanceSelector extends ConnectionSelector, ElementInstanceSelector {
|
|
67
|
+
}
|
|
68
|
+
export type ListActionInstancesForConnectionQuery = PaginationQuery & {
|
|
69
|
+
parentId?: string;
|
|
70
|
+
universalParentId?: string;
|
|
71
|
+
};
|
|
72
|
+
export interface FindActionInstancesQuery extends ListActionInstancesForConnectionQuery {
|
|
73
|
+
integrationKey?: string;
|
|
74
|
+
integrationId?: string;
|
|
75
|
+
userId?: string;
|
|
76
|
+
connectionId?: string;
|
|
77
|
+
}
|
|
78
|
+
export interface CreateActionInstanceRequest {
|
|
79
|
+
parentId: string;
|
|
80
|
+
connectionId: string;
|
|
81
|
+
config?: any;
|
|
82
|
+
}
|
|
83
|
+
export interface UpdateActionInstanceRequest {
|
|
84
|
+
config?: any;
|
|
85
|
+
}
|
|
86
|
+
export interface OpenActionConfigurationOptions extends OpenConfigurationOptions {
|
|
87
|
+
}
|
|
88
|
+
export interface ActionRunResponse {
|
|
89
|
+
output?: any;
|
|
90
|
+
logs?: any[];
|
|
91
|
+
}
|
|
92
|
+
export declare enum ActionRunLogStatus {
|
|
93
|
+
SUCCESS = "success",
|
|
94
|
+
ERROR = "error"
|
|
95
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './types';
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
export declare enum AlertStatus {
|
|
2
|
+
ONGOING = "ongoing",
|
|
3
|
+
RESOLVED = "resolved"
|
|
4
|
+
}
|
|
5
|
+
export declare enum AlertSeverity {
|
|
6
|
+
CRITICAL = "critical",
|
|
7
|
+
WARNING = "warning"
|
|
8
|
+
}
|
|
9
|
+
export declare enum AlertType {
|
|
10
|
+
externalEventsPerCustomerPerDay = "externalEventsPerCustomerPerDay"
|
|
11
|
+
}
|
|
12
|
+
export interface Alert {
|
|
13
|
+
id: string;
|
|
14
|
+
description: string;
|
|
15
|
+
status: AlertStatus;
|
|
16
|
+
type: AlertType;
|
|
17
|
+
workspaceId: string;
|
|
18
|
+
createdAt: Date;
|
|
19
|
+
updatedAt: Date;
|
|
20
|
+
lastSeenAt: Date;
|
|
21
|
+
resolvedAt?: Date;
|
|
22
|
+
customerId?: string;
|
|
23
|
+
severity: AlertSeverity;
|
|
24
|
+
}
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
import { AxiosRequestConfig } from 'axios';
|
|
2
|
+
export declare const axios: import("axios").AxiosInstance;
|
|
3
|
+
export declare const DEFAULT_API_URI = "https://api.integration.app";
|
|
4
|
+
export declare const DEFAULT_UI_URI = "https://ui.integration.app";
|
|
5
|
+
export interface IntegrationAppClientOptions {
|
|
6
|
+
token?: string;
|
|
7
|
+
fetchToken?: () => Promise<string>;
|
|
8
|
+
credentials?: any;
|
|
9
|
+
fetchCredentials?: () => Promise<any>;
|
|
10
|
+
apiUri?: string;
|
|
11
|
+
uiUri?: string;
|
|
12
|
+
accessToken?: string;
|
|
13
|
+
}
|
|
14
|
+
export declare class IntegrationAppApiClient {
|
|
15
|
+
apiUri: string;
|
|
16
|
+
uiUri: string;
|
|
17
|
+
token?: string;
|
|
18
|
+
protected fetchToken?: () => Promise<string>;
|
|
19
|
+
constructor({ uiUri, apiUri, accessToken, token, fetchToken, fetchCredentials, credentials, }?: IntegrationAppClientOptions);
|
|
20
|
+
setCredentials(credentials: any): Promise<any>;
|
|
21
|
+
getToken(): Promise<string>;
|
|
22
|
+
get(uri: string, queryParams?: Record<string, any>, options?: AxiosRequestConfig): Promise<any>;
|
|
23
|
+
post(uri: string, data?: any, options?: AxiosRequestConfig): Promise<any>;
|
|
24
|
+
put(uri: string, data?: any, options?: AxiosRequestConfig): Promise<any>;
|
|
25
|
+
patch(uri: string, data?: any, options?: AxiosRequestConfig): Promise<any>;
|
|
26
|
+
delete(uri: string, data?: any, options?: AxiosRequestConfig): Promise<any>;
|
|
27
|
+
getEmbedUri(page: string, pageParams?: Record<string, any>, options?: {
|
|
28
|
+
embedMode: 'isolated-embed' | 'popup-embed';
|
|
29
|
+
}): Promise<string>;
|
|
30
|
+
private makeApiRequest;
|
|
31
|
+
private handleRequestError;
|
|
32
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import { ElementAccessor, ElementInstanceAccessor, ElementInstanceListAccessor, ElementListAccessor } from '../accessors';
|
|
2
|
+
import { IntegrationAppApiClient } from '../api-client';
|
|
3
|
+
import { AppDataSchemaInstanceSelector, CreateAppDataSchemaRequest, FindAppDataSchemaInstancesQuery, FindAppDataSchemasQuery, UpdateAppDataSchemaRequest } from './api';
|
|
4
|
+
import { AppDataSchema, AppDataSchemaInstance, CreateAppDataSchemaInstanceRequest, UpdateAppDataSchemaInstanceRequest } from '.';
|
|
5
|
+
export declare class AppDataSchemasAccessor extends ElementListAccessor<AppDataSchema, FindAppDataSchemasQuery, CreateAppDataSchemaRequest> {
|
|
6
|
+
constructor(client: IntegrationAppApiClient);
|
|
7
|
+
}
|
|
8
|
+
export declare class AppDataSchemaAccessor extends ElementAccessor<AppDataSchema, UpdateAppDataSchemaRequest> {
|
|
9
|
+
constructor(client: IntegrationAppApiClient, idOrKey: string);
|
|
10
|
+
}
|
|
11
|
+
export declare class AppDataSchemaInstancesAccessor extends ElementInstanceListAccessor<AppDataSchemaInstance, FindAppDataSchemaInstancesQuery> {
|
|
12
|
+
constructor(client: IntegrationAppApiClient);
|
|
13
|
+
}
|
|
14
|
+
export declare class AppDataSchemaInstanceAccessor extends ElementInstanceAccessor<AppDataSchemaInstance, AppDataSchemaInstanceSelector, UpdateAppDataSchemaInstanceRequest, CreateAppDataSchemaInstanceRequest> {
|
|
15
|
+
private client;
|
|
16
|
+
constructor(client: IntegrationAppApiClient, selector: string | AppDataSchemaInstanceSelector);
|
|
17
|
+
setup(): Promise<void>;
|
|
18
|
+
}
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
import { PaginationQuery } from '../entity-repository';
|
|
2
|
+
export type CreateAppDataSchemaRequest = {
|
|
3
|
+
key: string;
|
|
4
|
+
name: string;
|
|
5
|
+
schema?: any;
|
|
6
|
+
code?: string;
|
|
7
|
+
};
|
|
8
|
+
export type UpdateAppDataSchemaRequest = {
|
|
9
|
+
key?: string;
|
|
10
|
+
name?: string;
|
|
11
|
+
schema?: any;
|
|
12
|
+
code?: string;
|
|
13
|
+
archivedAt?: string;
|
|
14
|
+
};
|
|
15
|
+
export interface FindAppDataSchemasQuery extends PaginationQuery {
|
|
16
|
+
}
|
|
17
|
+
export interface AppDataSchemaInstanceSelector {
|
|
18
|
+
id?: string;
|
|
19
|
+
appDataSchemaKey?: string;
|
|
20
|
+
appDataSchemaId?: string;
|
|
21
|
+
instanceKey?: string;
|
|
22
|
+
autoCreate?: boolean;
|
|
23
|
+
}
|
|
24
|
+
export interface UpdateAppDataSchemaInstanceRequest {
|
|
25
|
+
}
|
|
26
|
+
export interface CreateAppDataSchemaInstanceRequest {
|
|
27
|
+
}
|
|
28
|
+
export interface FindAppDataSchemaInstancesQuery extends PaginationQuery {
|
|
29
|
+
id?: string;
|
|
30
|
+
userId?: string;
|
|
31
|
+
appDataSchemaId?: string;
|
|
32
|
+
instanceKey?: string;
|
|
33
|
+
}
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import { ErrorData } from '../errors';
|
|
2
|
+
import { User } from '../users';
|
|
3
|
+
import { WorkspaceElement } from '../workspace-elements';
|
|
4
|
+
export * from './accessors';
|
|
5
|
+
export * from './api';
|
|
6
|
+
export interface AppDataSchema extends WorkspaceElement {
|
|
7
|
+
schema: any;
|
|
8
|
+
code?: string;
|
|
9
|
+
archivedAt?: string;
|
|
10
|
+
revision?: string;
|
|
11
|
+
}
|
|
12
|
+
export interface AppDataSchemaInstance extends WorkspaceElement {
|
|
13
|
+
appId: string;
|
|
14
|
+
userId: string;
|
|
15
|
+
user?: User;
|
|
16
|
+
appDataSchemaId: string;
|
|
17
|
+
appDataSchemaRevision: string;
|
|
18
|
+
appDataSchema?: AppDataSchema;
|
|
19
|
+
instanceKey?: string;
|
|
20
|
+
schema?: any;
|
|
21
|
+
error?: ErrorData;
|
|
22
|
+
archivedAt?: string;
|
|
23
|
+
}
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import { ElementAccessor, ElementInstanceAccessor, ElementInstanceListAccessor, ElementListAccessor } from '../accessors';
|
|
2
|
+
import { IntegrationAppApiClient } from '../api-client';
|
|
3
|
+
import { AppEventSubscriptionSelector, CreateAppEventTypeRequest, FindAppEventSubscriptionsQuery, FindAppEventTypesQuery, AppEventSubscriptionUpdateRequest, UpdateAppEventTypeRequest } from './api';
|
|
4
|
+
import { AppEventType, AppEventSubscription, FindAppEventsQuery, AppEvent } from '.';
|
|
5
|
+
export declare class AppEventTypesAccessor extends ElementListAccessor<AppEventType, FindAppEventTypesQuery, CreateAppEventTypeRequest> {
|
|
6
|
+
constructor(client: IntegrationAppApiClient);
|
|
7
|
+
}
|
|
8
|
+
export declare class AppEventTypeAccessor extends ElementAccessor<AppEventType, UpdateAppEventTypeRequest> {
|
|
9
|
+
constructor(client: IntegrationAppApiClient, idOrKey: string);
|
|
10
|
+
}
|
|
11
|
+
export declare class AppEventSubscriptionsAccessor extends ElementInstanceListAccessor<AppEventSubscription, FindAppEventSubscriptionsQuery> {
|
|
12
|
+
constructor(client: IntegrationAppApiClient);
|
|
13
|
+
}
|
|
14
|
+
export declare class AppEventSubscriptionAccessor extends ElementInstanceAccessor<AppEventSubscription, AppEventSubscriptionSelector, AppEventSubscriptionUpdateRequest, AppEventSubscriptionUpdateRequest> {
|
|
15
|
+
constructor(client: IntegrationAppApiClient, selector: string | AppEventSubscriptionSelector);
|
|
16
|
+
subscribe(): Promise<void>;
|
|
17
|
+
}
|
|
18
|
+
export declare class AppEventsAccessor extends ElementInstanceListAccessor<AppEvent, FindAppEventsQuery> {
|
|
19
|
+
constructor(client: IntegrationAppApiClient);
|
|
20
|
+
}
|
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
import { ElementInstanceSelector } from '../accessors';
|
|
2
|
+
import { DataSchema } from '../data-schema';
|
|
3
|
+
import { PaginationQuery } from '../entity-repository';
|
|
4
|
+
import { HttpRequestSpec } from '../http-requests';
|
|
5
|
+
export interface UpdateAppEventTypeRequest {
|
|
6
|
+
key?: string;
|
|
7
|
+
name?: string;
|
|
8
|
+
subscribeRequest?: HttpRequestSpec;
|
|
9
|
+
example?: any;
|
|
10
|
+
schema?: DataSchema;
|
|
11
|
+
userIdFormula?: any;
|
|
12
|
+
}
|
|
13
|
+
export interface CreateAppEventTypeRequest extends UpdateAppEventTypeRequest {
|
|
14
|
+
key: string;
|
|
15
|
+
name: string;
|
|
16
|
+
}
|
|
17
|
+
export interface AppEventSubscriptionSelector extends Omit<ElementInstanceSelector, 'parentKey' | 'parentId'> {
|
|
18
|
+
appEventTypeKey?: string;
|
|
19
|
+
appEventTypeId?: string;
|
|
20
|
+
instanceKey?: string;
|
|
21
|
+
}
|
|
22
|
+
export interface AppEventSubscriptionCreateRequest {
|
|
23
|
+
}
|
|
24
|
+
export interface AppEventSubscriptionUpdateRequest {
|
|
25
|
+
}
|
|
26
|
+
export interface FindAppEventTypesQuery extends PaginationQuery {
|
|
27
|
+
includeArchived?: boolean;
|
|
28
|
+
}
|
|
29
|
+
export interface FindAppEventSubscriptionsQuery extends PaginationQuery {
|
|
30
|
+
id?: string;
|
|
31
|
+
userId?: string;
|
|
32
|
+
instanceKey?: string;
|
|
33
|
+
appEventTypeId?: string;
|
|
34
|
+
isSubscribed?: boolean;
|
|
35
|
+
}
|
|
36
|
+
export interface FindAppEventsQuery extends PaginationQuery {
|
|
37
|
+
id?: string;
|
|
38
|
+
userId?: string;
|
|
39
|
+
instanceKey?: string;
|
|
40
|
+
appEventTypeId?: string;
|
|
41
|
+
appEventSubscriptionId?: string;
|
|
42
|
+
startDatetime?: string;
|
|
43
|
+
endDatetime?: string;
|
|
44
|
+
}
|
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
import { DataSchema } from '../data-schema';
|
|
2
|
+
import { HttpRequestSpec } from '../http-requests';
|
|
3
|
+
import { User } from '../users';
|
|
4
|
+
import { WorkspaceElement } from '../workspace-elements';
|
|
5
|
+
export * from './api';
|
|
6
|
+
export * from './accessors';
|
|
7
|
+
export interface AppEventType extends WorkspaceElement {
|
|
8
|
+
revision: string;
|
|
9
|
+
archivedAt?: string;
|
|
10
|
+
subscribeRequest?: HttpRequestSpec;
|
|
11
|
+
example?: any;
|
|
12
|
+
schema?: DataSchema;
|
|
13
|
+
globalWebhookUri: string;
|
|
14
|
+
userIdFormula?: any;
|
|
15
|
+
}
|
|
16
|
+
export interface AppEventSubscription extends WorkspaceElement {
|
|
17
|
+
revision: string;
|
|
18
|
+
appEventTypeId: string;
|
|
19
|
+
appEventType?: AppEventType;
|
|
20
|
+
userId: string;
|
|
21
|
+
user?: User;
|
|
22
|
+
instanceKey?: string;
|
|
23
|
+
isSubscribed: boolean;
|
|
24
|
+
schema?: DataSchema;
|
|
25
|
+
webhookUri: string;
|
|
26
|
+
subscriptionRequest: HttpRequestSpec;
|
|
27
|
+
subscriptionResponse?: any;
|
|
28
|
+
archivedAt?: string;
|
|
29
|
+
}
|
|
30
|
+
export interface AppEvent {
|
|
31
|
+
id: string;
|
|
32
|
+
name?: string;
|
|
33
|
+
userId: string;
|
|
34
|
+
user?: User;
|
|
35
|
+
appEventTypeId: string;
|
|
36
|
+
appEventType?: AppEventType;
|
|
37
|
+
appEventSubscriptionId: string;
|
|
38
|
+
appEventSubscription?: AppEventSubscription;
|
|
39
|
+
event: any;
|
|
40
|
+
datetime: string;
|
|
41
|
+
launchedFlowRunIds: string[];
|
|
42
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './types';
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
export interface App {
|
|
2
|
+
id: string;
|
|
3
|
+
apiDocsUri: string;
|
|
4
|
+
appUri: string;
|
|
5
|
+
canIntegrate: boolean;
|
|
6
|
+
categories: string[];
|
|
7
|
+
defaultConnectorId: string;
|
|
8
|
+
key: string;
|
|
9
|
+
logoUri: string;
|
|
10
|
+
name: string;
|
|
11
|
+
popularity: number;
|
|
12
|
+
uuid: string;
|
|
13
|
+
knowledgeBaseUuid?: string;
|
|
14
|
+
}
|
|
15
|
+
export interface AppCategory {
|
|
16
|
+
count: number;
|
|
17
|
+
category: string;
|
|
18
|
+
}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { IntegrationAppApiClient } from '../api-client';
|
|
2
|
+
import { Customer } from '../users';
|
|
3
|
+
export declare class SelfAccessor {
|
|
4
|
+
private client;
|
|
5
|
+
constructor(client: IntegrationAppApiClient);
|
|
6
|
+
get(): Promise<Customer>;
|
|
7
|
+
patch(data: Partial<{
|
|
8
|
+
credentials: any;
|
|
9
|
+
}>): Promise<Customer>;
|
|
10
|
+
}
|
|
@@ -0,0 +1,70 @@
|
|
|
1
|
+
import { ActionAccessor, ActionInstanceAccessor, ActionInstancesAccessor, ActionInstanceSelector, ActionsAccessor, ActionSelector } from './actions';
|
|
2
|
+
import { IntegrationAppApiClient, IntegrationAppClientOptions } from './api-client';
|
|
3
|
+
import { AppDataSchemaAccessor, AppDataSchemaInstanceAccessor, AppDataSchemaInstanceSelector, AppDataSchemaInstancesAccessor, AppDataSchemasAccessor } from './app-data-schemas';
|
|
4
|
+
import { AppEventSubscriptionAccessor, AppEventSubscriptionSelector, AppEventSubscriptionsAccessor, AppEventTypeAccessor, AppEventTypesAccessor, AppEventsAccessor } from './app-events';
|
|
5
|
+
import { SelfAccessor } from './auth';
|
|
6
|
+
import { ConnectionAccessor, ConnectionsAccessor } from './connections';
|
|
7
|
+
import { DataLinkTableAccessor, DataLinkTableInstanceAccessor, DataLinkTableInstanceSelector, DataLinkTableInstancesAccessor, DataLinkTablesAccessor } from './data-links';
|
|
8
|
+
import { DataSourceAccessor, DataSourceInstanceAccessor, DataSourceInstanceSelector, DataSourceInstancesAccessor, DataSourceSelector, DataSourcesAccessor } from './data-sources';
|
|
9
|
+
import { ExternalEventSubscriptionAccessor, ExternalEventSubscriptionsAccessor } from './external-events';
|
|
10
|
+
import { FieldMappingAccessor, FieldMappingInstanceAccessor, FieldMappingInstanceSelector, FieldMappingInstancesAccessor, FieldMappingSelector, FieldMappingsAccessor } from './field-mappings';
|
|
11
|
+
import { FlowRunAccessor, FlowRunsAccessor } from './flow-runs';
|
|
12
|
+
import { FlowAccessor, FlowInstanceAccessor, FlowInstanceSelector, FlowInstancesAccessor, FlowSelector, FlowsAccessor } from './flows';
|
|
13
|
+
import { OpenConfigurationOptions } from './iframe';
|
|
14
|
+
import { IntegrationAccessor, IntegrationsAccessor } from './integrations';
|
|
15
|
+
import { ScenarioAccessor, ScenariosAccessor } from './scenarios';
|
|
16
|
+
import { ScreenSelector } from './screens';
|
|
17
|
+
import { ScreenAccessor, ScreensAccessor } from './screens/accessors';
|
|
18
|
+
import { CustomerAccessor, CustomersAccessor, CustomerSelector } from './users';
|
|
19
|
+
interface OpenIntegrationAppConfigurationOptions extends OpenConfigurationOptions {
|
|
20
|
+
}
|
|
21
|
+
export declare class IntegrationAppClient extends IntegrationAppApiClient {
|
|
22
|
+
constructor(options: IntegrationAppClientOptions);
|
|
23
|
+
get self(): SelfAccessor;
|
|
24
|
+
get flows(): FlowsAccessor;
|
|
25
|
+
open({ onClose }?: OpenIntegrationAppConfigurationOptions): Promise<void>;
|
|
26
|
+
action(selector: string | ActionSelector): ActionAccessor;
|
|
27
|
+
get actions(): ActionsAccessor;
|
|
28
|
+
screen(selector: string | ScreenSelector): ScreenAccessor;
|
|
29
|
+
get screens(): ScreensAccessor;
|
|
30
|
+
actionInstance(selector: string | ActionInstanceSelector): ActionInstanceAccessor;
|
|
31
|
+
get actionInstances(): ActionInstancesAccessor;
|
|
32
|
+
flow(selector: string | FlowSelector): FlowAccessor;
|
|
33
|
+
get flowInstances(): FlowInstancesAccessor;
|
|
34
|
+
flowInstance(selector: string | FlowInstanceSelector): FlowInstanceAccessor;
|
|
35
|
+
get dataSourceInstances(): DataSourceInstancesAccessor;
|
|
36
|
+
get dataSources(): DataSourcesAccessor;
|
|
37
|
+
dataSource(selector: string | DataSourceSelector): DataSourceAccessor;
|
|
38
|
+
dataSourceInstance(selector: string | DataSourceInstanceSelector): DataSourceInstanceAccessor;
|
|
39
|
+
get fieldMappings(): FieldMappingsAccessor;
|
|
40
|
+
fieldMapping(selector: string | FieldMappingSelector): FieldMappingAccessor;
|
|
41
|
+
get fieldMappingInstances(): FieldMappingInstancesAccessor;
|
|
42
|
+
fieldMappingInstance(selector: string | FieldMappingInstanceSelector): FieldMappingInstanceAccessor;
|
|
43
|
+
get dataLinkTables(): DataLinkTablesAccessor;
|
|
44
|
+
dataLinkTable(idOrKey: string): DataLinkTableAccessor;
|
|
45
|
+
get dataLinkTableInstances(): DataLinkTableInstancesAccessor;
|
|
46
|
+
dataLinkTableInstance(selector: string | DataLinkTableInstanceSelector): DataLinkTableInstanceAccessor;
|
|
47
|
+
get integrations(): IntegrationsAccessor;
|
|
48
|
+
externalEventSubscriptions(): ExternalEventSubscriptionsAccessor;
|
|
49
|
+
externalEventSubscription(id: string): ExternalEventSubscriptionAccessor;
|
|
50
|
+
integration(identifier: string): IntegrationAccessor;
|
|
51
|
+
get connections(): ConnectionsAccessor;
|
|
52
|
+
connection(connectionSelector: string): ConnectionAccessor;
|
|
53
|
+
get appEventTypes(): AppEventTypesAccessor;
|
|
54
|
+
appEventType(id: string): AppEventTypeAccessor;
|
|
55
|
+
get appEventSubscriptions(): AppEventSubscriptionsAccessor;
|
|
56
|
+
appEventSubscription(selector: string | AppEventSubscriptionSelector): AppEventSubscriptionAccessor;
|
|
57
|
+
get appEvents(): AppEventsAccessor;
|
|
58
|
+
get flowRuns(): FlowRunsAccessor;
|
|
59
|
+
flowRun(id: string): FlowRunAccessor;
|
|
60
|
+
get appDataSchemas(): AppDataSchemasAccessor;
|
|
61
|
+
appDataSchema(id: string): AppDataSchemaAccessor;
|
|
62
|
+
get appDataSchemaInstances(): AppDataSchemaInstancesAccessor;
|
|
63
|
+
appDataSchemaInstance(selector: string | AppDataSchemaInstanceSelector): AppDataSchemaInstanceAccessor;
|
|
64
|
+
customer(selector: string | CustomerSelector): CustomerAccessor;
|
|
65
|
+
get customers(): CustomersAccessor;
|
|
66
|
+
scenario(selector: string): ScenarioAccessor;
|
|
67
|
+
get scenarios(): ScenariosAccessor;
|
|
68
|
+
connectionRequest(connectionId: string, uri: string, data?: any): Promise<any>;
|
|
69
|
+
}
|
|
70
|
+
export {};
|