@integration-app/react 0.1.3 → 0.1.5
Sign up to get free protection for your applications and to get access to all the features.
- package/contexts/integration-app-context.d.ts +2 -4
- package/integrations/index.d.ts +3 -4
- package/package.json +17 -4
- package/node_modules/@compwright/namecase/LICENSE +0 -26
- package/node_modules/@compwright/namecase/README.md +0 -49
- package/node_modules/@compwright/namecase/bin/namecase +0 -28
- package/node_modules/@compwright/namecase/dist/namecase.min.js +0 -4
- package/node_modules/@compwright/namecase/dist/namecase.min.js.map +0 -1
- package/node_modules/@compwright/namecase/package.json +0 -46
- package/node_modules/@compwright/namecase/src/index.js +0 -146
- package/node_modules/@integration-app/sdk/accessors.d.ts +0 -56
- package/node_modules/@integration-app/sdk/accessors.js +0 -104
- package/node_modules/@integration-app/sdk/accessors.js.map +0 -1
- package/node_modules/@integration-app/sdk/app-data-collections/accessors.d.ts +0 -16
- package/node_modules/@integration-app/sdk/app-data-collections/accessors.js +0 -38
- package/node_modules/@integration-app/sdk/app-data-collections/accessors.js.map +0 -1
- package/node_modules/@integration-app/sdk/app-data-collections/api.d.ts +0 -18
- package/node_modules/@integration-app/sdk/app-data-collections/api.js +0 -3
- package/node_modules/@integration-app/sdk/app-data-collections/api.js.map +0 -1
- package/node_modules/@integration-app/sdk/app-data-collections/index.d.ts +0 -26
- package/node_modules/@integration-app/sdk/app-data-collections/index.js +0 -3
- package/node_modules/@integration-app/sdk/app-data-collections/index.js.map +0 -1
- package/node_modules/@integration-app/sdk/app-data-schemas/accessors.d.ts +0 -16
- package/node_modules/@integration-app/sdk/app-data-schemas/accessors.js +0 -38
- package/node_modules/@integration-app/sdk/app-data-schemas/accessors.js.map +0 -1
- package/node_modules/@integration-app/sdk/app-data-schemas/api.d.ts +0 -18
- package/node_modules/@integration-app/sdk/app-data-schemas/api.js +0 -3
- package/node_modules/@integration-app/sdk/app-data-schemas/api.js.map +0 -1
- package/node_modules/@integration-app/sdk/app-data-schemas/index.d.ts +0 -21
- package/node_modules/@integration-app/sdk/app-data-schemas/index.js +0 -3
- package/node_modules/@integration-app/sdk/app-data-schemas/index.js.map +0 -1
- package/node_modules/@integration-app/sdk/app-events/accessors.d.ts +0 -16
- package/node_modules/@integration-app/sdk/app-events/accessors.js +0 -38
- package/node_modules/@integration-app/sdk/app-events/accessors.js.map +0 -1
- package/node_modules/@integration-app/sdk/app-events/api.d.ts +0 -18
- package/node_modules/@integration-app/sdk/app-events/api.js +0 -3
- package/node_modules/@integration-app/sdk/app-events/api.js.map +0 -1
- package/node_modules/@integration-app/sdk/app-events/index.d.ts +0 -46
- package/node_modules/@integration-app/sdk/app-events/index.js +0 -3
- package/node_modules/@integration-app/sdk/app-events/index.js.map +0 -1
- package/node_modules/@integration-app/sdk/auth/accessors.d.ts +0 -7
- package/node_modules/@integration-app/sdk/auth/accessors.js +0 -13
- package/node_modules/@integration-app/sdk/auth/accessors.js.map +0 -1
- package/node_modules/@integration-app/sdk/auth/index.d.ts +0 -6
- package/node_modules/@integration-app/sdk/auth/index.js +0 -3
- package/node_modules/@integration-app/sdk/auth/index.js.map +0 -1
- package/node_modules/@integration-app/sdk/bundle-index.d.ts +0 -1
- package/node_modules/@integration-app/sdk/bundle-index.js +0 -5
- package/node_modules/@integration-app/sdk/bundle-index.js.map +0 -1
- package/node_modules/@integration-app/sdk/bundle.js +0 -30163
- package/node_modules/@integration-app/sdk/bundle.js.map +0 -1
- package/node_modules/@integration-app/sdk/client.d.ts +0 -108
- package/node_modules/@integration-app/sdk/client.js +0 -248
- package/node_modules/@integration-app/sdk/client.js.map +0 -1
- package/node_modules/@integration-app/sdk/connections/accessors.d.ts +0 -13
- package/node_modules/@integration-app/sdk/connections/accessors.js +0 -39
- package/node_modules/@integration-app/sdk/connections/accessors.js.map +0 -1
- package/node_modules/@integration-app/sdk/connections/api.d.ts +0 -20
- package/node_modules/@integration-app/sdk/connections/api.js +0 -17
- package/node_modules/@integration-app/sdk/connections/api.js.map +0 -1
- package/node_modules/@integration-app/sdk/connections/index.d.ts +0 -39
- package/node_modules/@integration-app/sdk/connections/index.js +0 -13
- package/node_modules/@integration-app/sdk/connections/index.js.map +0 -1
- package/node_modules/@integration-app/sdk/connector-api/index.d.ts +0 -2
- package/node_modules/@integration-app/sdk/connector-api/index.js +0 -9
- package/node_modules/@integration-app/sdk/connector-api/index.js.map +0 -1
- package/node_modules/@integration-app/sdk/data-builder/context.d.ts +0 -9
- package/node_modules/@integration-app/sdk/data-builder/context.js +0 -32
- package/node_modules/@integration-app/sdk/data-builder/context.js.map +0 -1
- package/node_modules/@integration-app/sdk/data-builder/formulas/base.d.ts +0 -9
- package/node_modules/@integration-app/sdk/data-builder/formulas/base.js +0 -59
- package/node_modules/@integration-app/sdk/data-builder/formulas/base.js.map +0 -1
- package/node_modules/@integration-app/sdk/data-builder/formulas/case.d.ts +0 -14
- package/node_modules/@integration-app/sdk/data-builder/formulas/case.js +0 -45
- package/node_modules/@integration-app/sdk/data-builder/formulas/case.js.map +0 -1
- package/node_modules/@integration-app/sdk/data-builder/formulas/concat.d.ts +0 -18
- package/node_modules/@integration-app/sdk/data-builder/formulas/concat.js +0 -36
- package/node_modules/@integration-app/sdk/data-builder/formulas/concat.js.map +0 -1
- package/node_modules/@integration-app/sdk/data-builder/formulas/copy.d.ts +0 -10
- package/node_modules/@integration-app/sdk/data-builder/formulas/copy.js +0 -22
- package/node_modules/@integration-app/sdk/data-builder/formulas/copy.js.map +0 -1
- package/node_modules/@integration-app/sdk/data-builder/formulas/extractDate.d.ts +0 -11
- package/node_modules/@integration-app/sdk/data-builder/formulas/extractDate.js +0 -31
- package/node_modules/@integration-app/sdk/data-builder/formulas/extractDate.js.map +0 -1
- package/node_modules/@integration-app/sdk/data-builder/formulas/extractTime.d.ts +0 -11
- package/node_modules/@integration-app/sdk/data-builder/formulas/extractTime.js +0 -31
- package/node_modules/@integration-app/sdk/data-builder/formulas/extractTime.js.map +0 -1
- package/node_modules/@integration-app/sdk/data-builder/formulas/findAppRecordId.d.ts +0 -17
- package/node_modules/@integration-app/sdk/data-builder/formulas/findAppRecordId.js +0 -24
- package/node_modules/@integration-app/sdk/data-builder/formulas/findAppRecordId.js.map +0 -1
- package/node_modules/@integration-app/sdk/data-builder/formulas/findExternalRecordId.d.ts +0 -17
- package/node_modules/@integration-app/sdk/data-builder/formulas/findExternalRecordId.js +0 -24
- package/node_modules/@integration-app/sdk/data-builder/formulas/findExternalRecordId.js.map +0 -1
- package/node_modules/@integration-app/sdk/data-builder/formulas/first-name.d.ts +0 -10
- package/node_modules/@integration-app/sdk/data-builder/formulas/first-name.js +0 -25
- package/node_modules/@integration-app/sdk/data-builder/formulas/first-name.js.map +0 -1
- package/node_modules/@integration-app/sdk/data-builder/formulas/index.d.ts +0 -28
- package/node_modules/@integration-app/sdk/data-builder/formulas/index.js +0 -177
- package/node_modules/@integration-app/sdk/data-builder/formulas/index.js.map +0 -1
- package/node_modules/@integration-app/sdk/data-builder/formulas/iterate.d.ts +0 -15
- package/node_modules/@integration-app/sdk/data-builder/formulas/iterate.js +0 -41
- package/node_modules/@integration-app/sdk/data-builder/formulas/iterate.js.map +0 -1
- package/node_modules/@integration-app/sdk/data-builder/formulas/last-name.d.ts +0 -10
- package/node_modules/@integration-app/sdk/data-builder/formulas/last-name.js +0 -25
- package/node_modules/@integration-app/sdk/data-builder/formulas/last-name.js.map +0 -1
- package/node_modules/@integration-app/sdk/data-builder/formulas/lookup.d.ts +0 -20
- package/node_modules/@integration-app/sdk/data-builder/formulas/lookup.js +0 -24
- package/node_modules/@integration-app/sdk/data-builder/formulas/lookup.js.map +0 -1
- package/node_modules/@integration-app/sdk/data-builder/formulas/map.d.ts +0 -17
- package/node_modules/@integration-app/sdk/data-builder/formulas/map.js +0 -34
- package/node_modules/@integration-app/sdk/data-builder/formulas/map.js.map +0 -1
- package/node_modules/@integration-app/sdk/data-builder/formulas/plain.d.ts +0 -7
- package/node_modules/@integration-app/sdk/data-builder/formulas/plain.js +0 -20
- package/node_modules/@integration-app/sdk/data-builder/formulas/plain.js.map +0 -1
- package/node_modules/@integration-app/sdk/data-builder/formulas/record.d.ts +0 -10
- package/node_modules/@integration-app/sdk/data-builder/formulas/record.js +0 -23
- package/node_modules/@integration-app/sdk/data-builder/formulas/record.js.map +0 -1
- package/node_modules/@integration-app/sdk/data-builder/formulas/schemaOption.d.ts +0 -12
- package/node_modules/@integration-app/sdk/data-builder/formulas/schemaOption.js +0 -22
- package/node_modules/@integration-app/sdk/data-builder/formulas/schemaOption.js.map +0 -1
- package/node_modules/@integration-app/sdk/data-builder/formulas/tpl.d.ts +0 -15
- package/node_modules/@integration-app/sdk/data-builder/formulas/tpl.js +0 -31
- package/node_modules/@integration-app/sdk/data-builder/formulas/tpl.js.map +0 -1
- package/node_modules/@integration-app/sdk/data-builder/formulas/var.d.ts +0 -8
- package/node_modules/@integration-app/sdk/data-builder/formulas/var.js +0 -21
- package/node_modules/@integration-app/sdk/data-builder/formulas/var.js.map +0 -1
- package/node_modules/@integration-app/sdk/data-builder/index.d.ts +0 -2
- package/node_modules/@integration-app/sdk/data-builder/index.js +0 -17
- package/node_modules/@integration-app/sdk/data-builder/index.js.map +0 -1
- package/node_modules/@integration-app/sdk/data-builder/locators.d.ts +0 -56
- package/node_modules/@integration-app/sdk/data-builder/locators.js +0 -560
- package/node_modules/@integration-app/sdk/data-builder/locators.js.map +0 -1
- package/node_modules/@integration-app/sdk/data-collections.d.ts +0 -36
- package/node_modules/@integration-app/sdk/data-collections.js +0 -16
- package/node_modules/@integration-app/sdk/data-collections.js.map +0 -1
- package/node_modules/@integration-app/sdk/data-filter/index.d.ts +0 -12
- package/node_modules/@integration-app/sdk/data-filter/index.js +0 -104
- package/node_modules/@integration-app/sdk/data-filter/index.js.map +0 -1
- package/node_modules/@integration-app/sdk/data-filter/operators.d.ts +0 -13
- package/node_modules/@integration-app/sdk/data-filter/operators.js +0 -140
- package/node_modules/@integration-app/sdk/data-filter/operators.js.map +0 -1
- package/node_modules/@integration-app/sdk/data-links/accessors.d.ts +0 -20
- package/node_modules/@integration-app/sdk/data-links/accessors.js +0 -65
- package/node_modules/@integration-app/sdk/data-links/accessors.js.map +0 -1
- package/node_modules/@integration-app/sdk/data-links/api.d.ts +0 -49
- package/node_modules/@integration-app/sdk/data-links/api.js +0 -3
- package/node_modules/@integration-app/sdk/data-links/api.js.map +0 -1
- package/node_modules/@integration-app/sdk/data-links/index.d.ts +0 -35
- package/node_modules/@integration-app/sdk/data-links/index.js +0 -10
- package/node_modules/@integration-app/sdk/data-links/index.js.map +0 -1
- package/node_modules/@integration-app/sdk/data-locations/accessors.d.ts +0 -10
- package/node_modules/@integration-app/sdk/data-locations/accessors.js +0 -22
- package/node_modules/@integration-app/sdk/data-locations/accessors.js.map +0 -1
- package/node_modules/@integration-app/sdk/data-locations/api.d.ts +0 -4
- package/node_modules/@integration-app/sdk/data-locations/api.js +0 -3
- package/node_modules/@integration-app/sdk/data-locations/api.js.map +0 -1
- package/node_modules/@integration-app/sdk/data-locations/index.d.ts +0 -138
- package/node_modules/@integration-app/sdk/data-locations/index.js +0 -17
- package/node_modules/@integration-app/sdk/data-locations/index.js.map +0 -1
- package/node_modules/@integration-app/sdk/data-schema/index.d.ts +0 -49
- package/node_modules/@integration-app/sdk/data-schema/index.js +0 -88
- package/node_modules/@integration-app/sdk/data-schema/index.js.map +0 -1
- package/node_modules/@integration-app/sdk/data-sources/accessors.d.ts +0 -29
- package/node_modules/@integration-app/sdk/data-sources/accessors.js +0 -71
- package/node_modules/@integration-app/sdk/data-sources/accessors.js.map +0 -1
- package/node_modules/@integration-app/sdk/data-sources/api.d.ts +0 -37
- package/node_modules/@integration-app/sdk/data-sources/api.js +0 -3
- package/node_modules/@integration-app/sdk/data-sources/api.js.map +0 -1
- package/node_modules/@integration-app/sdk/data-sources/index.d.ts +0 -55
- package/node_modules/@integration-app/sdk/data-sources/index.js +0 -3
- package/node_modules/@integration-app/sdk/data-sources/index.js.map +0 -1
- package/node_modules/@integration-app/sdk/datetime.d.ts +0 -1
- package/node_modules/@integration-app/sdk/datetime.js +0 -15
- package/node_modules/@integration-app/sdk/datetime.js.map +0 -1
- package/node_modules/@integration-app/sdk/entity-repository.d.ts +0 -11
- package/node_modules/@integration-app/sdk/entity-repository.js +0 -10
- package/node_modules/@integration-app/sdk/entity-repository.js.map +0 -1
- package/node_modules/@integration-app/sdk/errors.d.ts +0 -64
- package/node_modules/@integration-app/sdk/errors.js +0 -141
- package/node_modules/@integration-app/sdk/errors.js.map +0 -1
- package/node_modules/@integration-app/sdk/field-mappings/accessors.d.ts +0 -25
- package/node_modules/@integration-app/sdk/field-mappings/accessors.js +0 -60
- package/node_modules/@integration-app/sdk/field-mappings/accessors.js.map +0 -1
- package/node_modules/@integration-app/sdk/field-mappings/api.d.ts +0 -34
- package/node_modules/@integration-app/sdk/field-mappings/api.js +0 -3
- package/node_modules/@integration-app/sdk/field-mappings/api.js.map +0 -1
- package/node_modules/@integration-app/sdk/field-mappings/index.d.ts +0 -90
- package/node_modules/@integration-app/sdk/field-mappings/index.js +0 -195
- package/node_modules/@integration-app/sdk/field-mappings/index.js.map +0 -1
- package/node_modules/@integration-app/sdk/flow-runs/flow-node-runs.d.ts +0 -30
- package/node_modules/@integration-app/sdk/flow-runs/flow-node-runs.js +0 -11
- package/node_modules/@integration-app/sdk/flow-runs/flow-node-runs.js.map +0 -1
- package/node_modules/@integration-app/sdk/flow-runs/index.d.ts +0 -59
- package/node_modules/@integration-app/sdk/flow-runs/index.js +0 -44
- package/node_modules/@integration-app/sdk/flow-runs/index.js.map +0 -1
- package/node_modules/@integration-app/sdk/flows/accessors.d.ts +0 -37
- package/node_modules/@integration-app/sdk/flows/accessors.js +0 -167
- package/node_modules/@integration-app/sdk/flows/accessors.js.map +0 -1
- package/node_modules/@integration-app/sdk/flows/api.d.ts +0 -55
- package/node_modules/@integration-app/sdk/flows/api.js +0 -8
- package/node_modules/@integration-app/sdk/flows/api.js.map +0 -1
- package/node_modules/@integration-app/sdk/flows/index.d.ts +0 -84
- package/node_modules/@integration-app/sdk/flows/index.js +0 -26
- package/node_modules/@integration-app/sdk/flows/index.js.map +0 -1
- package/node_modules/@integration-app/sdk/flows/nodes/api-trigger.d.ts +0 -3
- package/node_modules/@integration-app/sdk/flows/nodes/api-trigger.js +0 -9
- package/node_modules/@integration-app/sdk/flows/nodes/api-trigger.js.map +0 -1
- package/node_modules/@integration-app/sdk/flows/nodes/app-event-trigger.d.ts +0 -3
- package/node_modules/@integration-app/sdk/flows/nodes/app-event-trigger.js +0 -9
- package/node_modules/@integration-app/sdk/flows/nodes/app-event-trigger.js.map +0 -1
- package/node_modules/@integration-app/sdk/flows/nodes/create-data-link.d.ts +0 -3
- package/node_modules/@integration-app/sdk/flows/nodes/create-data-link.js +0 -8
- package/node_modules/@integration-app/sdk/flows/nodes/create-data-link.js.map +0 -1
- package/node_modules/@integration-app/sdk/flows/nodes/create-data-record.d.ts +0 -3
- package/node_modules/@integration-app/sdk/flows/nodes/create-data-record.js +0 -8
- package/node_modules/@integration-app/sdk/flows/nodes/create-data-record.js.map +0 -1
- package/node_modules/@integration-app/sdk/flows/nodes/data-record-created-trigger.d.ts +0 -3
- package/node_modules/@integration-app/sdk/flows/nodes/data-record-created-trigger.js +0 -9
- package/node_modules/@integration-app/sdk/flows/nodes/data-record-created-trigger.js.map +0 -1
- package/node_modules/@integration-app/sdk/flows/nodes/data-record-deleted-trigger.d.ts +0 -3
- package/node_modules/@integration-app/sdk/flows/nodes/data-record-deleted-trigger.js +0 -9
- package/node_modules/@integration-app/sdk/flows/nodes/data-record-deleted-trigger.js.map +0 -1
- package/node_modules/@integration-app/sdk/flows/nodes/data-record-updated-trigger.d.ts +0 -3
- package/node_modules/@integration-app/sdk/flows/nodes/data-record-updated-trigger.js +0 -9
- package/node_modules/@integration-app/sdk/flows/nodes/data-record-updated-trigger.js.map +0 -1
- package/node_modules/@integration-app/sdk/flows/nodes/delete-data-record.d.ts +0 -3
- package/node_modules/@integration-app/sdk/flows/nodes/delete-data-record.js +0 -8
- package/node_modules/@integration-app/sdk/flows/nodes/delete-data-record.js.map +0 -1
- package/node_modules/@integration-app/sdk/flows/nodes/filter.d.ts +0 -3
- package/node_modules/@integration-app/sdk/flows/nodes/filter.js +0 -8
- package/node_modules/@integration-app/sdk/flows/nodes/filter.js.map +0 -1
- package/node_modules/@integration-app/sdk/flows/nodes/find-data-link.d.ts +0 -3
- package/node_modules/@integration-app/sdk/flows/nodes/find-data-link.js +0 -8
- package/node_modules/@integration-app/sdk/flows/nodes/find-data-link.js.map +0 -1
- package/node_modules/@integration-app/sdk/flows/nodes/find-data-record-by-id.d.ts +0 -3
- package/node_modules/@integration-app/sdk/flows/nodes/find-data-record-by-id.js +0 -8
- package/node_modules/@integration-app/sdk/flows/nodes/find-data-record-by-id.js.map +0 -1
- package/node_modules/@integration-app/sdk/flows/nodes/find-data-records.d.ts +0 -3
- package/node_modules/@integration-app/sdk/flows/nodes/find-data-records.js +0 -8
- package/node_modules/@integration-app/sdk/flows/nodes/find-data-records.js.map +0 -1
- package/node_modules/@integration-app/sdk/flows/nodes/http-request.d.ts +0 -3
- package/node_modules/@integration-app/sdk/flows/nodes/http-request.js +0 -8
- package/node_modules/@integration-app/sdk/flows/nodes/http-request.js.map +0 -1
- package/node_modules/@integration-app/sdk/flows/nodes/index.d.ts +0 -28
- package/node_modules/@integration-app/sdk/flows/nodes/index.js +0 -50
- package/node_modules/@integration-app/sdk/flows/nodes/index.js.map +0 -1
- package/node_modules/@integration-app/sdk/flows/nodes/list-data-records.d.ts +0 -3
- package/node_modules/@integration-app/sdk/flows/nodes/list-data-records.js +0 -8
- package/node_modules/@integration-app/sdk/flows/nodes/list-data-records.js.map +0 -1
- package/node_modules/@integration-app/sdk/flows/nodes/schedule-trigger.d.ts +0 -3
- package/node_modules/@integration-app/sdk/flows/nodes/schedule-trigger.js +0 -9
- package/node_modules/@integration-app/sdk/flows/nodes/schedule-trigger.js.map +0 -1
- package/node_modules/@integration-app/sdk/flows/nodes/transform-data.d.ts +0 -3
- package/node_modules/@integration-app/sdk/flows/nodes/transform-data.js +0 -8
- package/node_modules/@integration-app/sdk/flows/nodes/transform-data.js.map +0 -1
- package/node_modules/@integration-app/sdk/flows/nodes/update-data-record.d.ts +0 -3
- package/node_modules/@integration-app/sdk/flows/nodes/update-data-record.js +0 -8
- package/node_modules/@integration-app/sdk/flows/nodes/update-data-record.js.map +0 -1
- package/node_modules/@integration-app/sdk/flows/utils.d.ts +0 -10
- package/node_modules/@integration-app/sdk/flows/utils.js +0 -72
- package/node_modules/@integration-app/sdk/flows/utils.js.map +0 -1
- package/node_modules/@integration-app/sdk/http-requests.d.ts +0 -37
- package/node_modules/@integration-app/sdk/http-requests.js +0 -33
- package/node_modules/@integration-app/sdk/http-requests.js.map +0 -1
- package/node_modules/@integration-app/sdk/iframe.d.ts +0 -9
- package/node_modules/@integration-app/sdk/iframe.js +0 -112
- package/node_modules/@integration-app/sdk/iframe.js.map +0 -1
- package/node_modules/@integration-app/sdk/index.d.ts +0 -4
- package/node_modules/@integration-app/sdk/index.js +0 -8
- package/node_modules/@integration-app/sdk/index.js.map +0 -1
- package/node_modules/@integration-app/sdk/integration-elements/index.d.ts +0 -22
- package/node_modules/@integration-app/sdk/integration-elements/index.js +0 -15
- package/node_modules/@integration-app/sdk/integration-elements/index.js.map +0 -1
- package/node_modules/@integration-app/sdk/integrations/accessors.d.ts +0 -17
- package/node_modules/@integration-app/sdk/integrations/accessors.js +0 -36
- package/node_modules/@integration-app/sdk/integrations/accessors.js.map +0 -1
- package/node_modules/@integration-app/sdk/integrations/api.d.ts +0 -10
- package/node_modules/@integration-app/sdk/integrations/api.js +0 -3
- package/node_modules/@integration-app/sdk/integrations/api.js.map +0 -1
- package/node_modules/@integration-app/sdk/integrations/index.d.ts +0 -27
- package/node_modules/@integration-app/sdk/integrations/index.js +0 -16
- package/node_modules/@integration-app/sdk/integrations/index.js.map +0 -1
- package/node_modules/@integration-app/sdk/json-schema/index.d.ts +0 -32
- package/node_modules/@integration-app/sdk/json-schema/index.js +0 -207
- package/node_modules/@integration-app/sdk/json-schema/index.js.map +0 -1
- package/node_modules/@integration-app/sdk/json-schema/schema-builder.d.ts +0 -7
- package/node_modules/@integration-app/sdk/json-schema/schema-builder.js +0 -232
- package/node_modules/@integration-app/sdk/json-schema/schema-builder.js.map +0 -1
- package/node_modules/@integration-app/sdk/jwt.d.ts +0 -1
- package/node_modules/@integration-app/sdk/jwt.js +0 -37
- package/node_modules/@integration-app/sdk/jwt.js.map +0 -1
- package/node_modules/@integration-app/sdk/package.json +0 -63
- package/node_modules/@integration-app/sdk/rollup.config.js +0 -23
- package/node_modules/@integration-app/sdk/src/accessors.ts +0 -150
- package/node_modules/@integration-app/sdk/src/app-data-collections/accessors.ts +0 -69
- package/node_modules/@integration-app/sdk/src/app-data-collections/api.ts +0 -31
- package/node_modules/@integration-app/sdk/src/app-data-collections/index.ts +0 -46
- package/node_modules/@integration-app/sdk/src/app-data-schemas/accessors.ts +0 -69
- package/node_modules/@integration-app/sdk/src/app-data-schemas/api.ts +0 -28
- package/node_modules/@integration-app/sdk/src/app-data-schemas/index.ts +0 -35
- package/node_modules/@integration-app/sdk/src/app-events/accessors.ts +0 -69
- package/node_modules/@integration-app/sdk/src/app-events/api.ts +0 -28
- package/node_modules/@integration-app/sdk/src/app-events/index.ts +0 -75
- package/node_modules/@integration-app/sdk/src/auth/accessors.ts +0 -10
- package/node_modules/@integration-app/sdk/src/auth/index.ts +0 -7
- package/node_modules/@integration-app/sdk/src/bundle-index.ts +0 -6
- package/node_modules/@integration-app/sdk/src/client.ts +0 -417
- package/node_modules/@integration-app/sdk/src/connections/accessors.ts +0 -58
- package/node_modules/@integration-app/sdk/src/connections/api.ts +0 -28
- package/node_modules/@integration-app/sdk/src/connections/index.ts +0 -70
- package/node_modules/@integration-app/sdk/src/connector-api/index.ts +0 -44
- package/node_modules/@integration-app/sdk/src/data-builder/context.ts +0 -40
- package/node_modules/@integration-app/sdk/src/data-builder/formulas/base.test.ts +0 -26
- package/node_modules/@integration-app/sdk/src/data-builder/formulas/base.ts +0 -95
- package/node_modules/@integration-app/sdk/src/data-builder/formulas/case.test.ts +0 -158
- package/node_modules/@integration-app/sdk/src/data-builder/formulas/case.ts +0 -53
- package/node_modules/@integration-app/sdk/src/data-builder/formulas/concat.test.ts +0 -117
- package/node_modules/@integration-app/sdk/src/data-builder/formulas/concat.ts +0 -49
- package/node_modules/@integration-app/sdk/src/data-builder/formulas/copy.test.ts +0 -70
- package/node_modules/@integration-app/sdk/src/data-builder/formulas/copy.ts +0 -20
- package/node_modules/@integration-app/sdk/src/data-builder/formulas/extractDate.test.ts +0 -49
- package/node_modules/@integration-app/sdk/src/data-builder/formulas/extractDate.ts +0 -28
- package/node_modules/@integration-app/sdk/src/data-builder/formulas/extractTime.test.ts +0 -49
- package/node_modules/@integration-app/sdk/src/data-builder/formulas/extractTime.ts +0 -28
- package/node_modules/@integration-app/sdk/src/data-builder/formulas/findAppRecordId.test.ts +0 -30
- package/node_modules/@integration-app/sdk/src/data-builder/formulas/findAppRecordId.ts +0 -30
- package/node_modules/@integration-app/sdk/src/data-builder/formulas/findExternalRecordId.test.ts +0 -30
- package/node_modules/@integration-app/sdk/src/data-builder/formulas/findExternalRecordId.ts +0 -30
- package/node_modules/@integration-app/sdk/src/data-builder/formulas/first-name.ts +0 -21
- package/node_modules/@integration-app/sdk/src/data-builder/formulas/index.test.ts +0 -83
- package/node_modules/@integration-app/sdk/src/data-builder/formulas/index.ts +0 -190
- package/node_modules/@integration-app/sdk/src/data-builder/formulas/iterate.test.ts +0 -154
- package/node_modules/@integration-app/sdk/src/data-builder/formulas/iterate.ts +0 -46
- package/node_modules/@integration-app/sdk/src/data-builder/formulas/last-name.ts +0 -21
- package/node_modules/@integration-app/sdk/src/data-builder/formulas/lookup.test.ts +0 -20
- package/node_modules/@integration-app/sdk/src/data-builder/formulas/lookup.ts +0 -33
- package/node_modules/@integration-app/sdk/src/data-builder/formulas/map.test.ts +0 -125
- package/node_modules/@integration-app/sdk/src/data-builder/formulas/map.ts +0 -42
- package/node_modules/@integration-app/sdk/src/data-builder/formulas/plain.ts +0 -17
- package/node_modules/@integration-app/sdk/src/data-builder/formulas/record.ts +0 -20
- package/node_modules/@integration-app/sdk/src/data-builder/formulas/schemaOption.ts +0 -26
- package/node_modules/@integration-app/sdk/src/data-builder/formulas/tpl.test.ts +0 -51
- package/node_modules/@integration-app/sdk/src/data-builder/formulas/tpl.ts +0 -33
- package/node_modules/@integration-app/sdk/src/data-builder/formulas/var.ts +0 -19
- package/node_modules/@integration-app/sdk/src/data-builder/index.test.ts +0 -372
- package/node_modules/@integration-app/sdk/src/data-builder/index.ts +0 -16
- package/node_modules/@integration-app/sdk/src/data-builder/locators.test.ts +0 -1045
- package/node_modules/@integration-app/sdk/src/data-builder/locators.ts +0 -702
- package/node_modules/@integration-app/sdk/src/data-collections.ts +0 -74
- package/node_modules/@integration-app/sdk/src/data-filter/index.test.ts +0 -48
- package/node_modules/@integration-app/sdk/src/data-filter/index.ts +0 -127
- package/node_modules/@integration-app/sdk/src/data-filter/operators.test.ts +0 -694
- package/node_modules/@integration-app/sdk/src/data-filter/operators.ts +0 -163
- package/node_modules/@integration-app/sdk/src/data-links/accessors.ts +0 -108
- package/node_modules/@integration-app/sdk/src/data-links/api.ts +0 -75
- package/node_modules/@integration-app/sdk/src/data-links/index.ts +0 -55
- package/node_modules/@integration-app/sdk/src/data-locations/accessors.ts +0 -24
- package/node_modules/@integration-app/sdk/src/data-locations/api.ts +0 -5
- package/node_modules/@integration-app/sdk/src/data-locations/index.ts +0 -209
- package/node_modules/@integration-app/sdk/src/data-schema/index.test.ts +0 -90
- package/node_modules/@integration-app/sdk/src/data-schema/index.ts +0 -185
- package/node_modules/@integration-app/sdk/src/data-sources/accessors.ts +0 -133
- package/node_modules/@integration-app/sdk/src/data-sources/api.ts +0 -59
- package/node_modules/@integration-app/sdk/src/data-sources/index.ts +0 -103
- package/node_modules/@integration-app/sdk/src/datetime.ts +0 -16
- package/node_modules/@integration-app/sdk/src/entity-repository.ts +0 -12
- package/node_modules/@integration-app/sdk/src/errors.ts +0 -154
- package/node_modules/@integration-app/sdk/src/field-mappings/accessors.ts +0 -100
- package/node_modules/@integration-app/sdk/src/field-mappings/api.ts +0 -61
- package/node_modules/@integration-app/sdk/src/field-mappings/index.ts +0 -341
- package/node_modules/@integration-app/sdk/src/flow-runs/flow-node-runs.ts +0 -53
- package/node_modules/@integration-app/sdk/src/flow-runs/index.ts +0 -102
- package/node_modules/@integration-app/sdk/src/flows/accessors.ts +0 -246
- package/node_modules/@integration-app/sdk/src/flows/api.ts +0 -71
- package/node_modules/@integration-app/sdk/src/flows/index.ts +0 -233
- package/node_modules/@integration-app/sdk/src/flows/nodes/api-trigger.ts +0 -7
- package/node_modules/@integration-app/sdk/src/flows/nodes/app-event-trigger.ts +0 -7
- package/node_modules/@integration-app/sdk/src/flows/nodes/create-data-link.ts +0 -6
- package/node_modules/@integration-app/sdk/src/flows/nodes/create-data-record.ts +0 -6
- package/node_modules/@integration-app/sdk/src/flows/nodes/data-record-created-trigger.ts +0 -8
- package/node_modules/@integration-app/sdk/src/flows/nodes/data-record-deleted-trigger.ts +0 -8
- package/node_modules/@integration-app/sdk/src/flows/nodes/data-record-updated-trigger.ts +0 -8
- package/node_modules/@integration-app/sdk/src/flows/nodes/delete-data-record.ts +0 -6
- package/node_modules/@integration-app/sdk/src/flows/nodes/filter.ts +0 -6
- package/node_modules/@integration-app/sdk/src/flows/nodes/find-data-link.ts +0 -6
- package/node_modules/@integration-app/sdk/src/flows/nodes/find-data-record-by-id.ts +0 -6
- package/node_modules/@integration-app/sdk/src/flows/nodes/find-data-records.ts +0 -6
- package/node_modules/@integration-app/sdk/src/flows/nodes/http-request.ts +0 -6
- package/node_modules/@integration-app/sdk/src/flows/nodes/index.ts +0 -60
- package/node_modules/@integration-app/sdk/src/flows/nodes/list-data-records.ts +0 -7
- package/node_modules/@integration-app/sdk/src/flows/nodes/schedule-trigger.ts +0 -7
- package/node_modules/@integration-app/sdk/src/flows/nodes/transform-data.ts +0 -7
- package/node_modules/@integration-app/sdk/src/flows/nodes/update-data-record.ts +0 -6
- package/node_modules/@integration-app/sdk/src/flows/utils.test.ts +0 -63
- package/node_modules/@integration-app/sdk/src/flows/utils.ts +0 -110
- package/node_modules/@integration-app/sdk/src/http-requests.ts +0 -41
- package/node_modules/@integration-app/sdk/src/iframe.ts +0 -142
- package/node_modules/@integration-app/sdk/src/index.ts +0 -5
- package/node_modules/@integration-app/sdk/src/integration-elements/index.ts +0 -24
- package/node_modules/@integration-app/sdk/src/integrations/accessors.ts +0 -42
- package/node_modules/@integration-app/sdk/src/integrations/api.ts +0 -13
- package/node_modules/@integration-app/sdk/src/integrations/index.ts +0 -50
- package/node_modules/@integration-app/sdk/src/json-schema/__snapshots__/schema-builder.test.ts.snap +0 -167
- package/node_modules/@integration-app/sdk/src/json-schema/index.ts +0 -251
- package/node_modules/@integration-app/sdk/src/json-schema/json-schema.test.ts +0 -246
- package/node_modules/@integration-app/sdk/src/json-schema/schema-builder.test.ts +0 -396
- package/node_modules/@integration-app/sdk/src/json-schema/schema-builder.ts +0 -258
- package/node_modules/@integration-app/sdk/src/jwt.test.ts +0 -11
- package/node_modules/@integration-app/sdk/src/jwt.ts +0 -40
- package/node_modules/@integration-app/sdk/src/udm/activities.test.ts +0 -43
- package/node_modules/@integration-app/sdk/src/udm/activities.ts +0 -83
- package/node_modules/@integration-app/sdk/src/udm/base.ts +0 -88
- package/node_modules/@integration-app/sdk/src/udm/campaigns.ts +0 -72
- package/node_modules/@integration-app/sdk/src/udm/companies.ts +0 -80
- package/node_modules/@integration-app/sdk/src/udm/contacts.test.ts +0 -147
- package/node_modules/@integration-app/sdk/src/udm/contacts.ts +0 -106
- package/node_modules/@integration-app/sdk/src/udm/deals.ts +0 -90
- package/node_modules/@integration-app/sdk/src/udm/index.ts +0 -28
- package/node_modules/@integration-app/sdk/src/udm/leads.ts +0 -113
- package/node_modules/@integration-app/sdk/src/udm/users.ts +0 -92
- package/node_modules/@integration-app/sdk/src/users/accessors.ts +0 -28
- package/node_modules/@integration-app/sdk/src/users/api.ts +0 -8
- package/node_modules/@integration-app/sdk/src/users/index.ts +0 -5
- package/node_modules/@integration-app/sdk/src/variables.ts +0 -33
- package/node_modules/@integration-app/sdk/src/workspaces/index.ts +0 -5
- package/node_modules/@integration-app/sdk/tsconfig.build.json +0 -10
- package/node_modules/@integration-app/sdk/tsconfig.json +0 -19
- package/node_modules/@integration-app/sdk/udm/activities.d.ts +0 -30
- package/node_modules/@integration-app/sdk/udm/activities.js +0 -70
- package/node_modules/@integration-app/sdk/udm/activities.js.map +0 -1
- package/node_modules/@integration-app/sdk/udm/base.d.ts +0 -27
- package/node_modules/@integration-app/sdk/udm/base.js +0 -62
- package/node_modules/@integration-app/sdk/udm/base.js.map +0 -1
- package/node_modules/@integration-app/sdk/udm/campaigns.d.ts +0 -25
- package/node_modules/@integration-app/sdk/udm/campaigns.js +0 -66
- package/node_modules/@integration-app/sdk/udm/campaigns.js.map +0 -1
- package/node_modules/@integration-app/sdk/udm/companies.d.ts +0 -42
- package/node_modules/@integration-app/sdk/udm/companies.js +0 -69
- package/node_modules/@integration-app/sdk/udm/companies.js.map +0 -1
- package/node_modules/@integration-app/sdk/udm/contacts.d.ts +0 -49
- package/node_modules/@integration-app/sdk/udm/contacts.js +0 -94
- package/node_modules/@integration-app/sdk/udm/contacts.js.map +0 -1
- package/node_modules/@integration-app/sdk/udm/deals.d.ts +0 -26
- package/node_modules/@integration-app/sdk/udm/deals.js +0 -84
- package/node_modules/@integration-app/sdk/udm/deals.js.map +0 -1
- package/node_modules/@integration-app/sdk/udm/index.d.ts +0 -11
- package/node_modules/@integration-app/sdk/udm/index.js +0 -31
- package/node_modules/@integration-app/sdk/udm/index.js.map +0 -1
- package/node_modules/@integration-app/sdk/udm/leads.d.ts +0 -52
- package/node_modules/@integration-app/sdk/udm/leads.js +0 -101
- package/node_modules/@integration-app/sdk/udm/leads.js.map +0 -1
- package/node_modules/@integration-app/sdk/udm/users.d.ts +0 -31
- package/node_modules/@integration-app/sdk/udm/users.js +0 -81
- package/node_modules/@integration-app/sdk/udm/users.js.map +0 -1
- package/node_modules/@integration-app/sdk/users/accessors.d.ts +0 -10
- package/node_modules/@integration-app/sdk/users/accessors.js +0 -21
- package/node_modules/@integration-app/sdk/users/accessors.js.map +0 -1
- package/node_modules/@integration-app/sdk/users/api.d.ts +0 -6
- package/node_modules/@integration-app/sdk/users/api.js +0 -3
- package/node_modules/@integration-app/sdk/users/api.js.map +0 -1
- package/node_modules/@integration-app/sdk/users/index.d.ts +0 -5
- package/node_modules/@integration-app/sdk/users/index.js +0 -3
- package/node_modules/@integration-app/sdk/users/index.js.map +0 -1
- package/node_modules/@integration-app/sdk/variables.d.ts +0 -3
- package/node_modules/@integration-app/sdk/variables.js +0 -30
- package/node_modules/@integration-app/sdk/variables.js.map +0 -1
- package/node_modules/@integration-app/sdk/workspaces/index.d.ts +0 -5
- package/node_modules/@integration-app/sdk/workspaces/index.js +0 -3
- package/node_modules/@integration-app/sdk/workspaces/index.js.map +0 -1
- package/node_modules/@sinclair/typebox/package.json +0 -40
- package/node_modules/@sinclair/typebox/readme.md +0 -740
- package/node_modules/@sinclair/typebox/typebox.d.ts +0 -351
- package/node_modules/@sinclair/typebox/typebox.js +0 -345
- package/node_modules/@types/node/README.md +0 -16
- package/node_modules/@types/node/assert.d.ts +0 -128
- package/node_modules/@types/node/async_hooks.d.ts +0 -229
- package/node_modules/@types/node/buffer.d.ts +0 -89
- package/node_modules/@types/node/child_process.d.ts +0 -514
- package/node_modules/@types/node/cluster.d.ts +0 -265
- package/node_modules/@types/node/console.d.ts +0 -142
- package/node_modules/@types/node/constants.d.ts +0 -18
- package/node_modules/@types/node/crypto.d.ts +0 -1283
- package/node_modules/@types/node/dgram.d.ts +0 -144
- package/node_modules/@types/node/dns.d.ts +0 -387
- package/node_modules/@types/node/domain.d.ts +0 -27
- package/node_modules/@types/node/events.d.ts +0 -82
- package/node_modules/@types/node/fs/promises.d.ts +0 -572
- package/node_modules/@types/node/fs.d.ts +0 -2281
- package/node_modules/@types/node/globals.d.ts +0 -747
- package/node_modules/@types/node/globals.global.d.ts +0 -1
- package/node_modules/@types/node/http.d.ts +0 -580
- package/node_modules/@types/node/http2.d.ts +0 -962
- package/node_modules/@types/node/https.d.ts +0 -271
- package/node_modules/@types/node/index.d.ts +0 -98
- package/node_modules/@types/node/inspector.d.ts +0 -3051
- package/node_modules/@types/node/module.d.ts +0 -56
- package/node_modules/@types/node/net.d.ts +0 -308
- package/node_modules/@types/node/os.d.ts +0 -243
- package/node_modules/@types/node/package.json +0 -232
- package/node_modules/@types/node/path.d.ts +0 -168
- package/node_modules/@types/node/perf_hooks.d.ts +0 -274
- package/node_modules/@types/node/process.d.ts +0 -413
- package/node_modules/@types/node/punycode.d.ts +0 -78
- package/node_modules/@types/node/querystring.d.ts +0 -31
- package/node_modules/@types/node/readline.d.ts +0 -174
- package/node_modules/@types/node/repl.d.ts +0 -398
- package/node_modules/@types/node/stream.d.ts +0 -359
- package/node_modules/@types/node/string_decoder.d.ts +0 -10
- package/node_modules/@types/node/timers.d.ts +0 -19
- package/node_modules/@types/node/tls.d.ts +0 -784
- package/node_modules/@types/node/trace_events.d.ts +0 -64
- package/node_modules/@types/node/ts4.8/assert.d.ts +0 -128
- package/node_modules/@types/node/ts4.8/async_hooks.d.ts +0 -229
- package/node_modules/@types/node/ts4.8/buffer.d.ts +0 -89
- package/node_modules/@types/node/ts4.8/child_process.d.ts +0 -514
- package/node_modules/@types/node/ts4.8/cluster.d.ts +0 -265
- package/node_modules/@types/node/ts4.8/console.d.ts +0 -142
- package/node_modules/@types/node/ts4.8/constants.d.ts +0 -18
- package/node_modules/@types/node/ts4.8/crypto.d.ts +0 -1283
- package/node_modules/@types/node/ts4.8/dgram.d.ts +0 -144
- package/node_modules/@types/node/ts4.8/dns.d.ts +0 -387
- package/node_modules/@types/node/ts4.8/domain.d.ts +0 -27
- package/node_modules/@types/node/ts4.8/events.d.ts +0 -82
- package/node_modules/@types/node/ts4.8/fs/promises.d.ts +0 -572
- package/node_modules/@types/node/ts4.8/fs.d.ts +0 -2281
- package/node_modules/@types/node/ts4.8/globals.d.ts +0 -746
- package/node_modules/@types/node/ts4.8/globals.global.d.ts +0 -1
- package/node_modules/@types/node/ts4.8/http.d.ts +0 -580
- package/node_modules/@types/node/ts4.8/http2.d.ts +0 -962
- package/node_modules/@types/node/ts4.8/https.d.ts +0 -271
- package/node_modules/@types/node/ts4.8/index.d.ts +0 -53
- package/node_modules/@types/node/ts4.8/inspector.d.ts +0 -3051
- package/node_modules/@types/node/ts4.8/module.d.ts +0 -56
- package/node_modules/@types/node/ts4.8/net.d.ts +0 -308
- package/node_modules/@types/node/ts4.8/os.d.ts +0 -243
- package/node_modules/@types/node/ts4.8/path.d.ts +0 -168
- package/node_modules/@types/node/ts4.8/perf_hooks.d.ts +0 -274
- package/node_modules/@types/node/ts4.8/process.d.ts +0 -413
- package/node_modules/@types/node/ts4.8/punycode.d.ts +0 -78
- package/node_modules/@types/node/ts4.8/querystring.d.ts +0 -31
- package/node_modules/@types/node/ts4.8/readline.d.ts +0 -174
- package/node_modules/@types/node/ts4.8/repl.d.ts +0 -398
- package/node_modules/@types/node/ts4.8/stream.d.ts +0 -359
- package/node_modules/@types/node/ts4.8/string_decoder.d.ts +0 -10
- package/node_modules/@types/node/ts4.8/timers.d.ts +0 -19
- package/node_modules/@types/node/ts4.8/tls.d.ts +0 -784
- package/node_modules/@types/node/ts4.8/trace_events.d.ts +0 -64
- package/node_modules/@types/node/ts4.8/tty.d.ts +0 -69
- package/node_modules/@types/node/ts4.8/url.d.ts +0 -149
- package/node_modules/@types/node/ts4.8/util.d.ts +0 -216
- package/node_modules/@types/node/ts4.8/v8.d.ts +0 -190
- package/node_modules/@types/node/ts4.8/vm.d.ts +0 -155
- package/node_modules/@types/node/ts4.8/wasi.d.ts +0 -89
- package/node_modules/@types/node/ts4.8/worker_threads.d.ts +0 -241
- package/node_modules/@types/node/ts4.8/zlib.d.ts +0 -364
- package/node_modules/@types/node/tty.d.ts +0 -69
- package/node_modules/@types/node/url.d.ts +0 -149
- package/node_modules/@types/node/util.d.ts +0 -216
- package/node_modules/@types/node/v8.d.ts +0 -190
- package/node_modules/@types/node/vm.d.ts +0 -155
- package/node_modules/@types/node/wasi.d.ts +0 -89
- package/node_modules/@types/node/worker_threads.d.ts +0 -241
- package/node_modules/@types/node/zlib.d.ts +0 -364
@@ -1,43 +0,0 @@
|
|
1
|
-
import activitySpec from './activities'
|
2
|
-
|
3
|
-
describe('udm/activities', () => {
|
4
|
-
it('should populate empty dates', () => {
|
5
|
-
expect(
|
6
|
-
activitySpec.populateFields({
|
7
|
-
dueTime: null,
|
8
|
-
startTime: '2020-01-01T00:00:00.000Z',
|
9
|
-
endTime: null,
|
10
|
-
}),
|
11
|
-
).toEqual({
|
12
|
-
dueTime: '2020-01-01T00:00:00.000Z',
|
13
|
-
startTime: '2020-01-01T00:00:00.000Z',
|
14
|
-
endTime: '2020-01-01T00:00:00.000Z',
|
15
|
-
})
|
16
|
-
}),
|
17
|
-
it('should not populate empty dates if there is nothing to be populated', () => {
|
18
|
-
expect(
|
19
|
-
activitySpec.populateFields({
|
20
|
-
dueTime: null,
|
21
|
-
startTime: null,
|
22
|
-
endTime: null,
|
23
|
-
}),
|
24
|
-
).toEqual({
|
25
|
-
dueTime: null,
|
26
|
-
startTime: null,
|
27
|
-
endTime: null,
|
28
|
-
})
|
29
|
-
}),
|
30
|
-
it('should not mess up w/ existing values', () => {
|
31
|
-
expect(
|
32
|
-
activitySpec.populateFields({
|
33
|
-
dueTime: '2022-01-01T00:00:00.000Z',
|
34
|
-
startTime: '2020-01-01T00:00:00.000Z',
|
35
|
-
endTime: '2021-01-01T00:00:00.000Z',
|
36
|
-
}),
|
37
|
-
).toEqual({
|
38
|
-
dueTime: '2022-01-01T00:00:00.000Z',
|
39
|
-
startTime: '2020-01-01T00:00:00.000Z',
|
40
|
-
endTime: '2021-01-01T00:00:00.000Z',
|
41
|
-
})
|
42
|
-
})
|
43
|
-
})
|
@@ -1,83 +0,0 @@
|
|
1
|
-
import { Static, Type } from '@sinclair/typebox'
|
2
|
-
import { UnifiedDataModel } from './base'
|
3
|
-
|
4
|
-
export const FIELDS_SCHEMA = Type.Partial(
|
5
|
-
Type.Object({
|
6
|
-
title: Type.String(),
|
7
|
-
description: Type.String(),
|
8
|
-
type: Type.String(),
|
9
|
-
durationSeconds: Type.Number(),
|
10
|
-
location: Type.String(),
|
11
|
-
isRecurrent: Type.Boolean(),
|
12
|
-
participants: Type.Array(
|
13
|
-
Type.Object({
|
14
|
-
userId: Type.String(),
|
15
|
-
contactId: Type.String(),
|
16
|
-
}),
|
17
|
-
),
|
18
|
-
status: Type.String(),
|
19
|
-
contactId: Type.String({
|
20
|
-
referenceUdm: 'contacts',
|
21
|
-
}),
|
22
|
-
companyId: Type.String({
|
23
|
-
referenceUdm: 'companies',
|
24
|
-
}),
|
25
|
-
dealId: Type.String({
|
26
|
-
referenceUdm: 'deals',
|
27
|
-
}),
|
28
|
-
leadId: Type.String({
|
29
|
-
referenceUdm: 'leads',
|
30
|
-
}),
|
31
|
-
ownerId: Type.String({
|
32
|
-
referenceUdm: 'users',
|
33
|
-
}),
|
34
|
-
startTime: Type.String({ format: 'date-time' }),
|
35
|
-
endTime: Type.String({ format: 'date-time' }),
|
36
|
-
dueTime: Type.String({ format: 'date-time' }),
|
37
|
-
createdTime: Type.String({ format: 'date-time' }),
|
38
|
-
createdBy: Type.String({
|
39
|
-
referenceUdm: 'users',
|
40
|
-
}),
|
41
|
-
updatedTime: Type.String({ format: 'date-time' }),
|
42
|
-
updatedBy: Type.String({
|
43
|
-
referenceUdm: 'users',
|
44
|
-
}),
|
45
|
-
}),
|
46
|
-
)
|
47
|
-
|
48
|
-
export type UnifiedActivityFields = Static<typeof FIELDS_SCHEMA>
|
49
|
-
|
50
|
-
const udm: UnifiedDataModel = {
|
51
|
-
singularName: 'activity',
|
52
|
-
pluralName: 'activities',
|
53
|
-
fieldsSchema: FIELDS_SCHEMA,
|
54
|
-
create: {
|
55
|
-
excludedFields: ['createdTime', 'createdBy', 'updatedTime', 'updatedBy'],
|
56
|
-
},
|
57
|
-
update: {
|
58
|
-
excludedFields: ['createdTime', 'createdBy', 'updatedTime', 'updatedBy'],
|
59
|
-
},
|
60
|
-
populateFields,
|
61
|
-
}
|
62
|
-
|
63
|
-
export default udm
|
64
|
-
|
65
|
-
function populateFields(fields: UnifiedActivityFields): UnifiedActivityFields {
|
66
|
-
const result = JSON.parse(JSON.stringify(fields))
|
67
|
-
/*
|
68
|
-
* If Due Date is empty, set it into End Date (if set) or Start Date
|
69
|
-
* If Start Date is empty, set it into Due Date or End Date
|
70
|
-
* If End Date is empty, set it into Due Date or Start Date
|
71
|
-
*/
|
72
|
-
if (!result.dueTime) {
|
73
|
-
result.dueTime = result.endTime || result.startTime
|
74
|
-
}
|
75
|
-
if (!result.startTime) {
|
76
|
-
result.startTime = result.dueTime || result.endTime
|
77
|
-
}
|
78
|
-
if (!result.endTime) {
|
79
|
-
result.endTime = result.dueTime || result.startTime
|
80
|
-
}
|
81
|
-
|
82
|
-
return result
|
83
|
-
}
|
@@ -1,88 +0,0 @@
|
|
1
|
-
import { Type } from '@sinclair/typebox'
|
2
|
-
import phone from 'phone'
|
3
|
-
import {
|
4
|
-
DataCollectionCreateSpec,
|
5
|
-
DataCollectionDeleteSpec,
|
6
|
-
DataCollectionFindSpec,
|
7
|
-
DataCollectionUpdateSpec,
|
8
|
-
} from '../connector-api'
|
9
|
-
|
10
|
-
export interface UnifiedDataModel {
|
11
|
-
singularName: string
|
12
|
-
pluralName: string
|
13
|
-
fieldsSchema: any
|
14
|
-
/**
|
15
|
-
* Normalize field values. For example, normalize phone numbers to E.164 format.
|
16
|
-
*/
|
17
|
-
normalizeFields?: (fields: Record<string, any>) => Record<string, any>
|
18
|
-
/**
|
19
|
-
* Using dependencies between fields, populates missing fields.
|
20
|
-
* For example, if primaryEmail is missing, it will be populated from emails.
|
21
|
-
*/
|
22
|
-
populateFields?: (fields: Record<string, any>) => Record<string, any>
|
23
|
-
find?: DataCollectionFindSpec
|
24
|
-
create?: DataCollectionCreateSpec
|
25
|
-
update?: DataCollectionUpdateSpec
|
26
|
-
delete?: DataCollectionDeleteSpec
|
27
|
-
}
|
28
|
-
|
29
|
-
export const AddressSchema = Type.Object({
|
30
|
-
type: Type.String(),
|
31
|
-
full: Type.String(),
|
32
|
-
street: Type.String(),
|
33
|
-
city: Type.String(),
|
34
|
-
state: Type.String(),
|
35
|
-
country: Type.String(),
|
36
|
-
zip: Type.String(),
|
37
|
-
})
|
38
|
-
|
39
|
-
export const PhoneEmailSchema = Type.Object({
|
40
|
-
value: Type.String(),
|
41
|
-
type: Type.String(),
|
42
|
-
})
|
43
|
-
|
44
|
-
export function normalizePhone(value: string): string {
|
45
|
-
if (typeof value !== 'string') {
|
46
|
-
return value
|
47
|
-
}
|
48
|
-
const validationResult = phone(value)
|
49
|
-
if (validationResult.isValid) {
|
50
|
-
return validationResult.phoneNumber
|
51
|
-
} else {
|
52
|
-
// By default, just remove all the non-phone-number symbols from the value
|
53
|
-
const hasPlus = value.trim().startsWith('+')
|
54
|
-
let result = value.replace(/[^\d]/g, '')
|
55
|
-
if (hasPlus) {
|
56
|
-
result = `+${result}`
|
57
|
-
}
|
58
|
-
return result
|
59
|
-
}
|
60
|
-
}
|
61
|
-
|
62
|
-
export function populateContactInfo(
|
63
|
-
fields: Record<string, any>,
|
64
|
-
): Record<string, any> {
|
65
|
-
const result = JSON.parse(JSON.stringify(fields))
|
66
|
-
if (!result.fullName && result.firstName && result.lastName) {
|
67
|
-
result.fullName = {
|
68
|
-
$concat: {
|
69
|
-
values: [result.firstName, result.lastName],
|
70
|
-
delimiter: ' ',
|
71
|
-
},
|
72
|
-
}
|
73
|
-
}
|
74
|
-
if (!result.primaryEmail && result.emails && result.emails.length > 0) {
|
75
|
-
result.primaryEmail = result.emails[0].value
|
76
|
-
}
|
77
|
-
if (!result.primaryPhone && result.phones && result.phones.length > 0) {
|
78
|
-
result.primaryPhone = result.phones[0].value
|
79
|
-
}
|
80
|
-
if (
|
81
|
-
!result.primaryAddress &&
|
82
|
-
result.addresses &&
|
83
|
-
result.addresses.length > 0
|
84
|
-
) {
|
85
|
-
result.primaryAddress = result.addresses[0]
|
86
|
-
}
|
87
|
-
return result
|
88
|
-
}
|
@@ -1,72 +0,0 @@
|
|
1
|
-
import { Static, Type } from '@sinclair/typebox'
|
2
|
-
import { UnifiedDataModel } from './base'
|
3
|
-
|
4
|
-
const FIELDS_SCHEMA = Type.Partial(
|
5
|
-
Type.Object({
|
6
|
-
name: Type.String(),
|
7
|
-
cost: Type.Number(),
|
8
|
-
description: Type.String(),
|
9
|
-
source: Type.String(),
|
10
|
-
stage: Type.String(),
|
11
|
-
type: Type.String(),
|
12
|
-
ownerId: Type.String({
|
13
|
-
referenceUdm: 'users',
|
14
|
-
}),
|
15
|
-
sentCount: Type.Number(),
|
16
|
-
replyCount: Type.Number(),
|
17
|
-
openCount: Type.Number(),
|
18
|
-
clickCount: Type.Number(),
|
19
|
-
startTime: Type.String({
|
20
|
-
format: 'date-time',
|
21
|
-
}),
|
22
|
-
endTime: Type.String({
|
23
|
-
format: 'date-time',
|
24
|
-
}),
|
25
|
-
createdTime: Type.String({
|
26
|
-
format: 'date-time',
|
27
|
-
}),
|
28
|
-
createdBy: Type.String({
|
29
|
-
referenceUdm: 'users',
|
30
|
-
}),
|
31
|
-
updatedTime: Type.String({
|
32
|
-
format: 'date-time',
|
33
|
-
}),
|
34
|
-
updatedBy: Type.String({
|
35
|
-
referenceUdm: 'users',
|
36
|
-
}),
|
37
|
-
lastActivityTime: Type.String({
|
38
|
-
format: 'date-time',
|
39
|
-
}),
|
40
|
-
}),
|
41
|
-
)
|
42
|
-
|
43
|
-
export type UnifiedCampaignFields = Static<typeof FIELDS_SCHEMA>
|
44
|
-
|
45
|
-
const MODIFIABLE_FIELDS = [
|
46
|
-
'name',
|
47
|
-
'description',
|
48
|
-
'ownerId',
|
49
|
-
'startTime',
|
50
|
-
'endTime',
|
51
|
-
'cost',
|
52
|
-
'source',
|
53
|
-
'stage',
|
54
|
-
'type',
|
55
|
-
]
|
56
|
-
|
57
|
-
const udm: UnifiedDataModel = {
|
58
|
-
singularName: 'campaign',
|
59
|
-
pluralName: 'campaigns',
|
60
|
-
fieldsSchema: FIELDS_SCHEMA,
|
61
|
-
find: {
|
62
|
-
queryFields: ['name', 'ownerId', 'source', 'stage', 'type'],
|
63
|
-
},
|
64
|
-
create: {
|
65
|
-
fields: MODIFIABLE_FIELDS,
|
66
|
-
},
|
67
|
-
update: {
|
68
|
-
fields: MODIFIABLE_FIELDS,
|
69
|
-
},
|
70
|
-
}
|
71
|
-
|
72
|
-
export default udm
|
@@ -1,80 +0,0 @@
|
|
1
|
-
import { Static, Type } from '@sinclair/typebox'
|
2
|
-
import {
|
3
|
-
AddressSchema,
|
4
|
-
normalizePhone,
|
5
|
-
PhoneEmailSchema,
|
6
|
-
UnifiedDataModel,
|
7
|
-
} from './base'
|
8
|
-
|
9
|
-
const FIELDS_SCHEMA = Type.Partial(
|
10
|
-
Type.Object({
|
11
|
-
name: Type.String(),
|
12
|
-
websiteUrl: Type.String(),
|
13
|
-
phones: Type.Array(PhoneEmailSchema),
|
14
|
-
primaryPhone: Type.String(),
|
15
|
-
description: Type.String(),
|
16
|
-
currency: Type.String(),
|
17
|
-
industry: Type.String(),
|
18
|
-
ownerId: Type.String({
|
19
|
-
referenceUdm: 'users',
|
20
|
-
}),
|
21
|
-
primaryAddress: AddressSchema,
|
22
|
-
addresses: Type.Array(AddressSchema),
|
23
|
-
numberOfEmployees: Type.Number(),
|
24
|
-
createdTime: Type.String({ format: 'date-time' }),
|
25
|
-
createdBy: Type.String({
|
26
|
-
referenceUdm: 'users',
|
27
|
-
}),
|
28
|
-
updatedTime: Type.String({ format: 'date-time' }),
|
29
|
-
updatedBy: Type.String({
|
30
|
-
referenceUdm: 'users',
|
31
|
-
}),
|
32
|
-
lastActivityTime: Type.String({ format: 'date-time' }),
|
33
|
-
}),
|
34
|
-
)
|
35
|
-
|
36
|
-
export type UnifiedCompanyFields = Static<typeof FIELDS_SCHEMA>
|
37
|
-
|
38
|
-
const MODIFIABLE_FIELDS = [
|
39
|
-
'addresses',
|
40
|
-
'currency',
|
41
|
-
'description',
|
42
|
-
'industry',
|
43
|
-
'name',
|
44
|
-
'numberOfEmployees',
|
45
|
-
'ownerId',
|
46
|
-
'primaryAddress',
|
47
|
-
'primaryPhone',
|
48
|
-
'websiteUrl',
|
49
|
-
]
|
50
|
-
|
51
|
-
const udm: UnifiedDataModel = {
|
52
|
-
singularName: 'company',
|
53
|
-
pluralName: 'companies',
|
54
|
-
fieldsSchema: FIELDS_SCHEMA,
|
55
|
-
find: {
|
56
|
-
queryFields: ['name', 'primaryAddress', 'primaryPhone'],
|
57
|
-
},
|
58
|
-
create: {
|
59
|
-
fields: MODIFIABLE_FIELDS,
|
60
|
-
},
|
61
|
-
update: {
|
62
|
-
fields: MODIFIABLE_FIELDS,
|
63
|
-
},
|
64
|
-
normalizeFields,
|
65
|
-
}
|
66
|
-
|
67
|
-
export default udm
|
68
|
-
|
69
|
-
function normalizeFields(fields: UnifiedCompanyFields): UnifiedCompanyFields {
|
70
|
-
const result = JSON.parse(JSON.stringify(fields))
|
71
|
-
if (result.primaryPhone) {
|
72
|
-
result.primaryPhone = normalizePhone(result.primaryPhone)
|
73
|
-
}
|
74
|
-
if (result.phones) {
|
75
|
-
result.phones.forEach((phone) => {
|
76
|
-
phone.value = normalizePhone(phone.value)
|
77
|
-
})
|
78
|
-
}
|
79
|
-
return result
|
80
|
-
}
|
@@ -1,147 +0,0 @@
|
|
1
|
-
import { buildData } from '../data-builder'
|
2
|
-
import contactsSpec from './contacts'
|
3
|
-
|
4
|
-
describe('udm/contacts', () => {
|
5
|
-
it('should normalize phones', () => {
|
6
|
-
expect(
|
7
|
-
contactsSpec.normalizeFields({
|
8
|
-
primaryPhone: '+1 (617) 123-45-67',
|
9
|
-
phones: [
|
10
|
-
{
|
11
|
-
value: '+1 (617) 123-45-67',
|
12
|
-
type: 'mobile',
|
13
|
-
},
|
14
|
-
{
|
15
|
-
value: '12345',
|
16
|
-
type: 'other',
|
17
|
-
},
|
18
|
-
{
|
19
|
-
value: '6134113122',
|
20
|
-
type: 'home',
|
21
|
-
},
|
22
|
-
],
|
23
|
-
}),
|
24
|
-
).toEqual({
|
25
|
-
primaryPhone: '+16171234567',
|
26
|
-
phones: [
|
27
|
-
{
|
28
|
-
value: '+16171234567',
|
29
|
-
type: 'mobile',
|
30
|
-
},
|
31
|
-
{
|
32
|
-
value: '12345',
|
33
|
-
type: 'other',
|
34
|
-
},
|
35
|
-
{
|
36
|
-
value: '+16134113122',
|
37
|
-
type: 'home',
|
38
|
-
},
|
39
|
-
],
|
40
|
-
})
|
41
|
-
}),
|
42
|
-
it('should not normalize phones if there is nothing to be normalized', () => {
|
43
|
-
expect(
|
44
|
-
contactsSpec.normalizeFields({
|
45
|
-
phones: [],
|
46
|
-
primaryPhone: null,
|
47
|
-
}),
|
48
|
-
).toEqual({
|
49
|
-
phones: [],
|
50
|
-
primaryPhone: null,
|
51
|
-
})
|
52
|
-
}),
|
53
|
-
it('should populate primary contact info', () => {
|
54
|
-
expect(
|
55
|
-
contactsSpec.populateFields({
|
56
|
-
primaryEmail: null,
|
57
|
-
primaryPhone: null,
|
58
|
-
emails: [
|
59
|
-
{
|
60
|
-
value: 'workEmail@gmail.com',
|
61
|
-
type: 'work',
|
62
|
-
},
|
63
|
-
{
|
64
|
-
value: 'otherEmail@gmail.com',
|
65
|
-
type: 'other',
|
66
|
-
},
|
67
|
-
],
|
68
|
-
phones: [
|
69
|
-
{
|
70
|
-
value: '+16171234567',
|
71
|
-
type: 'mobile',
|
72
|
-
},
|
73
|
-
{
|
74
|
-
value: '12345',
|
75
|
-
type: 'other',
|
76
|
-
},
|
77
|
-
{
|
78
|
-
value: '+16134113122',
|
79
|
-
type: 'home',
|
80
|
-
},
|
81
|
-
],
|
82
|
-
}),
|
83
|
-
).toEqual({
|
84
|
-
primaryEmail: 'workEmail@gmail.com',
|
85
|
-
primaryPhone: '+16171234567',
|
86
|
-
emails: [
|
87
|
-
{
|
88
|
-
value: 'workEmail@gmail.com',
|
89
|
-
type: 'work',
|
90
|
-
},
|
91
|
-
{
|
92
|
-
value: 'otherEmail@gmail.com',
|
93
|
-
type: 'other',
|
94
|
-
},
|
95
|
-
],
|
96
|
-
phones: [
|
97
|
-
{
|
98
|
-
value: '+16171234567',
|
99
|
-
type: 'mobile',
|
100
|
-
},
|
101
|
-
{
|
102
|
-
value: '12345',
|
103
|
-
type: 'other',
|
104
|
-
},
|
105
|
-
{
|
106
|
-
value: '+16134113122',
|
107
|
-
type: 'home',
|
108
|
-
},
|
109
|
-
],
|
110
|
-
})
|
111
|
-
}),
|
112
|
-
it('should not populate primary contact info if there is nothing to be populated', () => {
|
113
|
-
expect(
|
114
|
-
contactsSpec.populateFields({
|
115
|
-
primaryEmail: null,
|
116
|
-
emails: [],
|
117
|
-
}),
|
118
|
-
).toEqual({
|
119
|
-
primaryEmail: null,
|
120
|
-
emails: [],
|
121
|
-
})
|
122
|
-
}),
|
123
|
-
it('should populate fullName if firstName and lastName were set', async () => {
|
124
|
-
expect(
|
125
|
-
await buildData(
|
126
|
-
contactsSpec.populateFields({ firstName: 'John', lastName: 'Doe' }),
|
127
|
-
),
|
128
|
-
).toEqual({
|
129
|
-
firstName: 'John',
|
130
|
-
lastName: 'Doe',
|
131
|
-
fullName: 'John Doe',
|
132
|
-
})
|
133
|
-
}),
|
134
|
-
it('should not overwrite fullName if it has already been set', () => {
|
135
|
-
expect(
|
136
|
-
contactsSpec.populateFields({
|
137
|
-
firstName: 'John',
|
138
|
-
lastName: 'Doe',
|
139
|
-
fullName: 'Rachel Green',
|
140
|
-
}),
|
141
|
-
).toEqual({
|
142
|
-
firstName: 'John',
|
143
|
-
lastName: 'Doe',
|
144
|
-
fullName: 'Rachel Green',
|
145
|
-
})
|
146
|
-
})
|
147
|
-
})
|
@@ -1,106 +0,0 @@
|
|
1
|
-
import { Static, Type } from '@sinclair/typebox'
|
2
|
-
import {
|
3
|
-
AddressSchema,
|
4
|
-
normalizePhone,
|
5
|
-
PhoneEmailSchema,
|
6
|
-
populateContactInfo,
|
7
|
-
UnifiedDataModel,
|
8
|
-
} from './base'
|
9
|
-
|
10
|
-
const FIELDS_SCHEMA = Type.Partial(
|
11
|
-
Type.Object({
|
12
|
-
fullName: Type.String(),
|
13
|
-
firstName: Type.String(),
|
14
|
-
lastName: Type.String(),
|
15
|
-
primaryEmail: Type.String(),
|
16
|
-
emails: Type.Array(PhoneEmailSchema),
|
17
|
-
primaryPhone: Type.String(),
|
18
|
-
phones: Type.Array(PhoneEmailSchema),
|
19
|
-
primaryAddress: AddressSchema,
|
20
|
-
addresses: Type.Array(AddressSchema),
|
21
|
-
stage: Type.String(),
|
22
|
-
companyName: Type.String(),
|
23
|
-
companyId: Type.String({
|
24
|
-
referenceUdm: 'companies',
|
25
|
-
}),
|
26
|
-
ownerId: Type.String({
|
27
|
-
referenceUdm: 'users',
|
28
|
-
}),
|
29
|
-
jobTitle: Type.String(),
|
30
|
-
source: Type.String(),
|
31
|
-
createdTime: Type.String({ format: 'date-time' }),
|
32
|
-
createdBy: Type.String({
|
33
|
-
referenceUdm: 'users',
|
34
|
-
}),
|
35
|
-
updatedTime: Type.String({ format: 'date-time' }),
|
36
|
-
updatedBy: Type.String({
|
37
|
-
referenceUdm: 'users',
|
38
|
-
}),
|
39
|
-
lastActivityTime: Type.String({ format: 'date-time' }),
|
40
|
-
}),
|
41
|
-
)
|
42
|
-
|
43
|
-
const MODIFIABLE_FIELDS = [
|
44
|
-
'fullName',
|
45
|
-
'firstName',
|
46
|
-
'lastName',
|
47
|
-
'primaryEmail',
|
48
|
-
'primaryPhone',
|
49
|
-
'primaryAddress',
|
50
|
-
'companyId',
|
51
|
-
'companyName',
|
52
|
-
'jobTitle',
|
53
|
-
'source',
|
54
|
-
'stage',
|
55
|
-
'ownerId',
|
56
|
-
'emails',
|
57
|
-
'phones',
|
58
|
-
'addresses',
|
59
|
-
]
|
60
|
-
|
61
|
-
export type UnifiedContactFields = Static<typeof FIELDS_SCHEMA>
|
62
|
-
|
63
|
-
const udm: UnifiedDataModel = {
|
64
|
-
singularName: 'contact',
|
65
|
-
pluralName: 'contacts',
|
66
|
-
fieldsSchema: FIELDS_SCHEMA,
|
67
|
-
find: {
|
68
|
-
queryFields: [
|
69
|
-
'fullName',
|
70
|
-
'firstName',
|
71
|
-
'lastName',
|
72
|
-
'primaryEmail',
|
73
|
-
'primaryPhone',
|
74
|
-
'primaryAddress',
|
75
|
-
'companyId',
|
76
|
-
'companyName',
|
77
|
-
'jobTitle',
|
78
|
-
'ownerId',
|
79
|
-
],
|
80
|
-
},
|
81
|
-
create: {
|
82
|
-
fields: MODIFIABLE_FIELDS,
|
83
|
-
},
|
84
|
-
update: {
|
85
|
-
fields: MODIFIABLE_FIELDS,
|
86
|
-
},
|
87
|
-
normalizeFields,
|
88
|
-
populateFields: populateContactInfo,
|
89
|
-
}
|
90
|
-
|
91
|
-
export default udm
|
92
|
-
|
93
|
-
function normalizeFields(fields: UnifiedContactFields): UnifiedContactFields {
|
94
|
-
const result = JSON.parse(JSON.stringify(fields))
|
95
|
-
if (result.primaryPhone) {
|
96
|
-
result.primaryPhone = normalizePhone(result.primaryPhone)
|
97
|
-
}
|
98
|
-
if (result.phones) {
|
99
|
-
result.phones.forEach((phone) => {
|
100
|
-
if (phone && typeof phone === 'object') {
|
101
|
-
phone.value = normalizePhone(phone.value)
|
102
|
-
}
|
103
|
-
})
|
104
|
-
}
|
105
|
-
return result
|
106
|
-
}
|
@@ -1,90 +0,0 @@
|
|
1
|
-
import { Static, Type } from '@sinclair/typebox'
|
2
|
-
import { UnifiedDataModel } from './base'
|
3
|
-
|
4
|
-
const FIELDS_SCHEMA = Type.Partial(
|
5
|
-
Type.Object({
|
6
|
-
name: Type.String(),
|
7
|
-
amount: Type.Number(),
|
8
|
-
currency: Type.String(),
|
9
|
-
companyId: Type.String({
|
10
|
-
referenceUdm: 'companies',
|
11
|
-
}),
|
12
|
-
contactId: Type.String({
|
13
|
-
referenceUdm: 'contacts',
|
14
|
-
}),
|
15
|
-
campaignId: Type.String({
|
16
|
-
referenceUdm: 'campaigns',
|
17
|
-
}),
|
18
|
-
source: Type.String(),
|
19
|
-
description: Type.String(),
|
20
|
-
stage: Type.String(),
|
21
|
-
status: Type.String({
|
22
|
-
enum: ['open', 'won', 'lost'],
|
23
|
-
}),
|
24
|
-
type: Type.String(),
|
25
|
-
ownerId: Type.String({
|
26
|
-
referenceUdm: 'users',
|
27
|
-
}),
|
28
|
-
closeTime: Type.String({
|
29
|
-
format: 'date-time',
|
30
|
-
}),
|
31
|
-
createdTime: Type.String({
|
32
|
-
format: 'date-time',
|
33
|
-
}),
|
34
|
-
createdBy: Type.String({
|
35
|
-
referenceUdm: 'users',
|
36
|
-
}),
|
37
|
-
updatedTime: Type.String({
|
38
|
-
format: 'date-time',
|
39
|
-
}),
|
40
|
-
updatedBy: Type.String({
|
41
|
-
referenceUdm: 'users',
|
42
|
-
}),
|
43
|
-
lastActivityTime: Type.String({
|
44
|
-
format: 'date-time',
|
45
|
-
}),
|
46
|
-
probability: Type.Number(),
|
47
|
-
}),
|
48
|
-
)
|
49
|
-
|
50
|
-
export type UnifiedDealFields = Static<typeof FIELDS_SCHEMA>
|
51
|
-
|
52
|
-
const MODIFIABLE_FIELDS = [
|
53
|
-
'amount',
|
54
|
-
'currency',
|
55
|
-
'companyId',
|
56
|
-
'contactId',
|
57
|
-
'campaignId',
|
58
|
-
'source',
|
59
|
-
'description',
|
60
|
-
'stage',
|
61
|
-
'status',
|
62
|
-
'type',
|
63
|
-
'ownerId',
|
64
|
-
'closeTime',
|
65
|
-
]
|
66
|
-
|
67
|
-
const udm: UnifiedDataModel = {
|
68
|
-
singularName: 'deal',
|
69
|
-
pluralName: 'deals',
|
70
|
-
fieldsSchema: FIELDS_SCHEMA,
|
71
|
-
find: {
|
72
|
-
queryFields: [
|
73
|
-
'companyId',
|
74
|
-
'contactId',
|
75
|
-
'campaignId',
|
76
|
-
'source',
|
77
|
-
'stage',
|
78
|
-
'type',
|
79
|
-
'ownerId',
|
80
|
-
],
|
81
|
-
},
|
82
|
-
create: {
|
83
|
-
fields: MODIFIABLE_FIELDS,
|
84
|
-
},
|
85
|
-
update: {
|
86
|
-
fields: MODIFIABLE_FIELDS,
|
87
|
-
},
|
88
|
-
}
|
89
|
-
|
90
|
-
export default udm
|